Ubuntuにてrailsのコントローラーを生成することができません。
入力コマンド
rails g controller コントローラー名 アクション名
エラーは次の通りです。
/home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/railties-5.1.7/lib/rails/app_loader.rb:40: warning: Insecure world writable dir /home//.rbenv/versions in PATH, mode 040777 /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/railties-5.1.7/lib/rails/application/configuration.rb:133:in `read': Cannot load `Rails.application.database_configuration`: Permission denied @ rb_sysopen - /home////config/database.yml (Errno::EACCES) from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/railties-5.1.7/lib/rails/application/configuration.rb:133:in `read' from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/railties-5.1.7/lib/rails/application/configuration.rb:133:in `database_configuration' from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/activerecord-5.1.7/lib/active_record/railtie.rb:121:in `block (2 levels) in <class:Railtie>' from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/activesupport-5.1.7/lib/active_support/lazy_load_hooks.rb:69:in `instance_eval' from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/activesupport-5.1.7/lib/active_support/lazy_load_hooks.rb:69:in `block in execute_hook' from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/activesupport-5.1.7/lib/active_support/lazy_load_hooks.rb:60:in `with_execution_control' from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/activesupport-5.1.7/lib/active_support/lazy_load_hooks.rb:65:in `execute_hook' from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/activesupport-5.1.7/lib/active_support/lazy_load_hooks.rb:50:in `block in run_load_hooks' from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/activesupport-5.1.7/lib/active_support/lazy_load_hooks.rb:49:in `each' from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/activesupport-5.1.7/lib/active_support/lazy_load_hooks.rb:49:in `run_load_hooks' from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/activerecord-5.1.7/lib/active_record/base.rb:326:in `<module:ActiveRecord>' from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/activerecord-5.1.7/lib/active_record/base.rb:25:in `<top (required)>' from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/activesupport-5.1.7/lib/active_support/dependencies.rb:292:in `require' @DESKTOP:~//$ from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/activesupport-5.1.7/lib/active_support/dependencies.rb:292:in `block in require' from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/activesupport-5.1.7/lib/active_support/dependencies.rb:258:in `load_dependency' from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/activesupport-5.1.7/lib/active_support/dependencies.rb:292:in `require' from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/spring-2.1.0/lib/spring/application.rb:370:in `active_record_configured?' from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/spring-2.1.0/lib/spring/application.rb:287:in `disconnect_database' from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/spring-2.1.0/lib/spring/application.rb:111:in `preload' from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/spring-2.1.0/lib/spring/application.rb:157:in `serve' from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/spring-2.1.0/lib/spring/application.rb:145:in `block in run' from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/spring-2.1.0/lib/spring/application.rb:139:in `loop' from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/spring-2.1.0/lib/spring/application.rb:139:in `run' from /home//.rbenv/versions/2.5.1/lib/ruby/gems/2.5.0/gems/spring-2.1.0/lib/spring/application/boot.rb:19:in `<top (required)>' from /home//.rbenv/versions/2.5.1/lib/ruby/site_ruby/2.5.0/rubygems/core_ext/kernel_require.rb:54:in `require' from /home//.rbenv/versions/2.5.1/lib/ruby/site_ruby/2.5.0/rubygems/core_ext/kernel_require.rb:54:in `require' from -e:1:in `<main>
よろしくお願いします。
bundle installは正常にできていますか?
あなたの回答
tips
プレビュー