お世話になります
cloud9でのエラーで悩んでいます。ご指導いただけるとありがたいのですが。。。
よろしくお願いいたします
環境は
ruby=2.6.3
rails=6.0.0
postgresql=9.6.11
homeview及びwebpackerやyarnをインストールしました
ec2-user:~/environment/myapp (master) $ rails s
=> Booting Puma
=> Rails 6.0.0 application starting in development
=> Run rails server --help
for more startup options
Puma starting in single mode...
- Version 3.12.1 (ruby 2.6.3-p62), codename: Llamas in Pajamas
- Min threads: 5, max threads: 5
- Environment: development
- Listening on tcp://localhost:8080
Use Ctrl-C to stop
ここでpreview running aplicationりがたいのですが。。。
よろしくお願いいたします
環境は
ruby=2.6.3
rails=6.0.0postgresql=9.6.11
homeview及びwebpackerやyarnをインストールしました
ec2-user:~/environment/myapp (master) $ rails s
=> Booting Puma
=> Rails 6.0.0 application starting in development
=> Run rails server --help
for more startup options
Puma starting in single mode...
- Version 3.12.1 (ruby 2.6.3-p62), codename: Lamas in Pajamas
- Min threads: 5, max threads: 5
- Environment: development
- Listening on tcp://localhost:8080
Use Ctrl-C to stop
ここでpreview running aplicationとすると添付画像が出てエラーになります
Gemfile
1source 'https://rubygems.org' 2git_source(:github) { |repo| "https://github.com/#{repo}.git" } 3 4ruby '2.6.3' 5 6# Bundle edge Rails instead: gem 'rails', github: 'rails/rails' 7gem 'rails', '~> 6.0.0' 8# Use sqlite3 as the database for Active Record 9gem 'sqlite3', '~> 1.3.6' 10# Use Puma as the app server 11gem 'puma', '~> 3.11' 12# Use SCSS for stylesheets 13gem 'sass-rails', '~> 5' 14# Transpile app-like JavaScript. Read more: https://github.com/rails/webpacker 15gem 'webpacker', '~> 4.0' 16# Turbolinks makes navigating your web application faster. Read more: https://github.com/turbolinks/turbolinks 17gem 'turbolinks', '~> 5' 18# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder 19gem 'jbuilder', '~> 2.7' 20# Use Redis adapter to run Action Cable in production 21# gem 'redis', '~> 4.0' 22# Use Active Model has_secure_password 23# gem 'bcrypt', '~> 3.1.7' 24 25# Use Active Storage variant 26# gem 'image_processing', '~> 1.2' 27 28# Reduces boot times through caching; required in config/boot.rb 29gem 'bootsnap', '>= 1.4.2', require: false 30 31group :development, :test do 32 # Call 'byebug' anywhere in the code to stop execution and get a debugger console 33 gem 'byebug', platforms: [:mri, :mingw, :x64_mingw] 34end 35 36group :development do 37 # Access an interactive console on exception pages or by calling 'console' anywhere in the code. 38 gem 'web-console', '>= 3.3.0' 39 gem 'listen', '>= 3.0.5', '< 3.2' 40 # Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring 41 gem 'spring' 42 gem 'spring-watcher-listen', '~> 2.0.0' 43end 44 45group :test do 46 # Adds support for Capybara system testing and selenium driver 47 gem 'capybara', '>= 2.15' 48 gem 'selenium-webdriver' 49 # Easy installation and use of web drivers to run system tests with browsers 50 gem 'webdrivers' 51end 52 53# Windows does not include zoneinfo files, so bundle the tzinfo-data gem 54gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby] 55
rails s エラー内容です
2019-09-08 08:37:46 +0900: Rack app error handling request { GET / } #<LoadError: Error loading the 'sqlite3' Active Record adapter. Missing a gem it depends on? can't activate sqlite3 (~> 1.4), already activated sqlite3-1.3.13. Make sure all dependencies are added to Gemfile.> /home/ec2-user/.rvm/rubies/ruby-2.6.3/lib/ruby/site_ruby/2.6.0/bundler/rubygems_integration.rb:408:in `block (2 levels) in replace_gem' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activerecord-6.0.0/lib/active_record/connection_adapters/sqlite3_adapter.rb:13:in `<main>' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `block in require_with_bootsnap_lfi' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `require_with_bootsnap_lfi' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/zeitwerk-2.1.9/lib/zeitwerk/kernel.rb:23:in `require' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activerecord-6.0.0/lib/active_record/connection_adapters/connection_specification.rb:170:in `spec' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activerecord-6.0.0/lib/active_record/connection_adapters/abstract/connection_pool.rb:1044:in `establish_connection' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activerecord-6.0.0/lib/active_record/connection_handling.rb:51:in `establish_connection' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activerecord-6.0.0/lib/active_record/railtie.rb:201:in `block (2 levels) in <class:Railtie>' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/lazy_load_hooks.rb:72:in `class_eval' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/lazy_load_hooks.rb:72:in `block in execute_hook' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/lazy_load_hooks.rb:62:in `with_execution_control' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/lazy_load_hooks.rb:67:in `execute_hook' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/lazy_load_hooks.rb:52:in `block in run_load_hooks' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/lazy_load_hooks.rb:51:in `each' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/lazy_load_hooks.rb:51:in `run_load_hooks' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activerecord-6.0.0/lib/active_record/base.rb:327:in `<module:ActiveRecord>' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activerecord-6.0.0/lib/active_record/base.rb:27:in `<main>' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `block in require_with_bootsnap_lfi' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `require_with_bootsnap_lfi' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/zeitwerk-2.1.9/lib/zeitwerk/kernel.rb:23:in `require' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activerecord-6.0.0/lib/active_record/query_cache.rb:31:in `run' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/execution_wrapper.rb:28:in `before' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/callbacks.rb:429:in `block in make_lambda' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/callbacks.rb:201:in `block (2 levels) in halting' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/callbacks.rb:607:in `block (2 levels) in default_terminator' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/callbacks.rb:606:in `catch' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/callbacks.rb:606:in `block in default_terminator' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/callbacks.rb:202:in `block in halting' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/callbacks.rb:514:in `block in invoke_before' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/callbacks.rb:514:in `each' /home/ec2-user/.rvm/gems/ruby-2.6.3/gems/activesup
回答1件
あなたの回答
tips
プレビュー