使用Heroku部署Rails站点时出错

qnakjoqk  于 9个月前  发布在  其他
关注(0)|答案(1)|浏览(74)

我正在尝试使用heroku创建rails应用程序。这是我的宝石档案

source "https://rubygems.org"
git_source(:github) { |repo| "https://github.com/#{repo}.git" }

ruby "3.1.2"

gem "rails",           "7.0.4"
gem "sprockets-rails", "3.4.2"
gem "importmap-rails", "1.1.0"
gem "turbo-rails",     "1.1.1"
gem "stimulus-rails",  "1.0.4"
gem "jbuilder",        "2.11.5"
gem "puma",            "5.6.4"
gem "bootsnap",        "1.12.0", require: false

group :development, :test do
  gem "sqlite3", "1.4.2"
  gem "debug",   "1.5.0", platforms: %i[ mri mingw x64_mingw ]
end

group :development do
  gem "web-console", "4.2.0"
end

group :test do
  gem "capybara",           "3.37.1"
  gem "selenium-webdriver", "4.2.0"
  gem "webdrivers",         "5.0.0"
end

group :production do
  gem "pg", "1.3.5"
end

# Windows does not include zoneinfo files, so bundle the tzinfo-data gem.
# Uncomment the following line if you're running Rails
# on a native Windows system:
# gem "tzinfo-data", platforms: [:mingw, :mswin, :x64_mingw, :jruby]

当我访问网站时,我得到了错误,它说应用程序错误
应用程序中发生错误,您的页面无法提供。如果您是应用程序所有者,请检查日志以了解详细信息。您可以在Heroku CLI中使用命令heroku logs --tail完成此操作
然后我检查了日志文件,它在这里

heroku logs --tail
2023-08-11T12:54:41.722270+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/commands/server/server_command.rb:38:in `start'
2023-08-11T12:54:41.722270+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-
2023-08-11T12:54:41.722379+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/rack-2.2.8/lib/rack/builder.rb:116:in `new_from_string'
2023-08-11T12:54:41.722380+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/rack-2.2.8/lib/rack/builder.rb:105:in `load_file'
2023-08-11T12:54:41.722381+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/rack-2.2.8/lib/rack/builder.rb:66:in `parse_file'
2023-08-11T12:54:41.722382+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/rack-2.2.8/lib/rack/server.rb:349:in `build_app_and_options_from_config'      
2023-08-11T12:54:41.722383+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/rack-2.2.8/lib/rack/server.rb:249:in `app'
2023-08-11T12:54:41.722384+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/rack-2.2.8/lib/rack/server.rb:422:in `wrapped_app'
2023-08-11T12:54:41.722385+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/rack-2.2.8/lib/rack/server.rb:312:in `block in start'
2023-08-11T12:54:41.722386+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/rack-2.2.8/lib/rack/server.rb:379:in `handle_profiling'
2023-08-11T12:54:41.722387+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/rack-2.2.8/lib/rack/server.rb:311:in `start'
2023-08-11T12:54:41.722388+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/commands/server/server_command.rb:38:in `start'      
2023-08-11T12:54:41.722389+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/commands/server/server_command.rb:143:in `block in perform'
2023-08-11T12:54:41.722391+00:00 app[web.1]: from <internal:kernel>:90:in `tap'
2023-08-11T12:54:41.722392+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/commands/server/server_command.rb:134:in `perform'   
2023-08-11T12:54:41.722393+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/thor-1.2.2/lib/thor/command.rb:27:in `run'
2023-08-11T12:54:41.722394+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/thor-1.2.2/lib/thor/invocation.rb:127:in `invoke_command'
2023-08-11T12:54:41.722396+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/thor-1.2.2/lib/thor.rb:392:in `dispatch'
2023-08-11T12:54:41.722397+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/command/base.rb:87:in `perform'
2023-08-11T12:54:41.722398+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/command.rb:48:in `invoke'
2023-08-11T12:54:41.722399+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/commands.rb:18:in `<main>'
2023-08-11T12:54:41.722400+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/bootsnap-1.12.0/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in 
`require'
2023-08-11T12:54:41.722401+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/bootsnap-1.12.0/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in 
`require'
2023-08-11T12:54:41.722409+00:00 app[web.1]: from bin/rails:4:in `<main>'
2023-08-11T12:54:41.857968+00:00 heroku[web.1]: Process exited with status 1
2023-08-11T12:54:41.889921+00:00 heroku[web.1]: State changed from starting to crashed
2023-08-11T12:54:47.947717+00:00 app[api]: Scaled to console@0:Basic rake@0:Basic web@0:Basic by user [email protected]
2023-08-11T12:54:48.064190+00:00 heroku[web.1]: State changed from crashed to down
2023-08-11T12:58:34.278315+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=te12-6495be2.herokuapp.com request_id=93c011d5-671d-4217-9013-ba5b1013ea8c fwd="141.523.183.145" dyno= connect= service= status=503 bytes= protocol=https
2023-08-11T12:58:34.762225+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=t12-6495b8e2.herokuapp.com request_id=450be1eb-711e-4545-80cd-5c2850c560f8 fwd="111.223.183.155" dyno= connect= service= status=503 bytes= protocol=https

谁能告诉我该怎么做,Rails应用程序很简单,它只有helloworld
我正在尝试使用heroku创建rails应用程序。这是我的宝石档案

source "https://rubygems.org"
git_source(:github) { |repo| "https://github.com/#{repo}.git" }

ruby "3.1.2"

gem "rails",           "7.0.4"
gem "sprockets-rails", "3.4.2"
gem "importmap-rails", "1.1.0"
gem "turbo-rails",     "1.1.1"
gem "stimulus-rails",  "1.0.4"
gem "jbuilder",        "2.11.5"
gem "puma",            "5.6.4"
gem "bootsnap",        "1.12.0", require: false

group :development, :test do
  gem "sqlite3", "1.4.2"
  gem "debug",   "1.5.0", platforms: %i[ mri mingw x64_mingw ]
end

group :development do
  gem "web-console", "4.2.0"
end

group :test do
  gem "capybara",           "3.37.1"
  gem "selenium-webdriver", "4.2.0"
  gem "webdrivers",         "5.0.0"
end

group :production do
  gem "pg", "1.3.5"
end

# Windows does not include zoneinfo files, so bundle the tzinfo-data gem.
# Uncomment the following line if you're running Rails
# on a native Windows system:
# gem "tzinfo-data", platforms: [:mingw, :mswin, :x64_mingw, :jruby]

当我访问网站时,我得到了错误,它说应用程序错误
应用程序中发生错误,您的页面无法提供。如果您是应用程序所有者,请检查日志以了解详细信息。您可以在Heroku CLI中使用命令heroku logs --tail完成此操作
然后我检查了日志文件,它在这里

heroku logs --tail
2023-08-11T12:54:41.722270+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/commands/server/server_command.rb:38:in `start'
2023-08-11T12:54:41.722270+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/commands/server/server_command.rb:143:in `block in perform'
2023-08-11T12:54:41.722270+00:00 app[web.1]: from <internal:kernel>:90:in `tap'
2023-08-11T12:54:41.722279+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/commands/server/server_command.rb:134:in `perform'   
2023-08-11T12:54:41.722280+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/thor-1.2.2/lib/thor/command.rb:27:in `run'
2023-08-11T12:54:41.722280+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/thor-1.2.2/lib/thor/invocation.rb:127:in `invoke_command'
2023-08-11T12:54:41.722280+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/thor-1.2.2/lib/thor.rb:392:in `dispatch'
2023-08-11T12:54:41.722281+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/command/base.rb:87:in `perform'
2023-08-11T12:54:41.722281+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/command.rb:48:in `invoke'
2023-08-11T12:54:41.722282+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/commands.rb:18:in `<main>'
2023-08-11T12:54:41.722283+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/bootsnap-1.12.0/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in 
`require'
2023-08-11T12:54:41.722284+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/bootsnap-1.12.0/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in 
`require'
2023-08-11T12:54:41.722286+00:00 app[web.1]: from bin/rails:4:in `<main>'
2023-08-11T12:54:41.722300+00:00 app[web.1]: /app/vendor/bundle/ruby/3.1.0/gems/bundler-2.3.25/lib/bundler/rubygems_integration.rb:280:in `block (2 levels) in replace_gem': sqlite3 is not part of the bundle. Add it to your Gemfile. (Gem::LoadError)
2023-08-11T12:54:41.722302+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/activerecord-7.0.4/lib/active_record/connection_adapters/sqlite3_adapter.rb:13:in `<main>'
2023-08-11T12:54:41.722302+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/bootsnap-1.12.0/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in 
`require'
2023-08-11T12:54:41.722302+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/bootsnap-1.12.0/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in 
`require'
2023-08-11T12:54:41.722309+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/zeitwerk-2.6.11/lib/zeitwerk/kernel.rb:38:in `require'
2023-08-11T12:54:41.722310+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/activerecord-7.0.4/lib/active_record/connection_adapters/abstract/connection_handler.rb:268:in `resolve_pool_config'
2023-08-11T12:54:41.722310+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/activerecord-7.0.4/lib/active_record/connection_adapters/abstract/connection_handler.rb:129:in `establish_connection'
2023-08-11T12:54:41.722314+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/activerecord-7.0.4/lib/active_record/connection_handling.rb:52:in `establish_connection'
2023-08-11T12:54:41.722314+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/activerecord-7.0.4/lib/active_record/railtie.rb:268:in `block (2 levels) in <class:Railtie>'
2023-08-11T12:54:41.722314+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/activesupport-7.0.4/lib/active_support/lazy_load_hooks.rb:95:in `class_eval'  
2023-08-11T12:54:41.722314+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/activesupport-7.0.4/lib/active_support/lazy_load_hooks.rb:95:in `block in execute_hook'
2023-08-11T12:54:41.722315+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/activesupport-7.0.4/lib/active_support/lazy_load_hooks.rb:85:in `with_execution_control'
2023-08-11T12:54:41.722316+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/activesupport-7.0.4/lib/active_support/lazy_load_hooks.rb:90:in `execute_hook'2023-08-11T12:54:41.722316+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/activesupport-7.0.4/lib/active_support/lazy_load_hooks.rb:76:in `block in run_load_hooks'
2023-08-11T12:54:41.722316+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/activesupport-7.0.4/lib/active_support/lazy_load_hooks.rb:75:in `each'        
2023-08-11T12:54:41.722316+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/activesupport-7.0.4/lib/active_support/lazy_load_hooks.rb:75:in `run_load_hooks'
2023-08-11T12:54:41.722316+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/activerecord-7.0.4/lib/active_record/base.rb:333:in `<module:ActiveRecord>'
2023-08-11T12:54:41.722317+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/activerecord-7.0.4/lib/active_record/base.rb:15:in `<main>'
2023-08-11T12:54:41.722317+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/bootsnap-1.12.0/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in 
`require'
2023-08-11T12:54:41.722318+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/bootsnap-1.12.0/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in 
`require'
2023-08-11T12:54:41.722319+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/zeitwerk-2.6.11/lib/zeitwerk/kernel.rb:38:in `require'
2023-08-11T12:54:41.722320+00:00 app[web.1]: from /app/app/models/application_record.rb:1:in `<main>'
2023-08-11T12:54:41.722328+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/bootsnap-1.12.0/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in 
`require'
2023-08-11T12:54:41.722329+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/bootsnap-1.12.0/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in 
`require'
2023-08-11T12:54:41.722329+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/zeitwerk-2.6.11/lib/zeitwerk/kernel.rb:30:in `require'
2023-08-11T12:54:41.722329+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/zeitwerk-2.6.11/lib/zeitwerk/loader/helpers.rb:135:in `const_get'
2023-08-11T12:54:41.722330+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/zeitwerk-2.6.11/lib/zeitwerk/loader/helpers.rb:135:in `cget'
2023-08-11T12:54:41.722330+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/zeitwerk-2.6.11/lib/zeitwerk/loader/eager_load.rb:175:in `block in actual_eager_load_dir'
2023-08-11T12:54:41.722331+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/zeitwerk-2.6.11/lib/zeitwerk/loader/helpers.rb:40:in `block in ls'
2023-08-11T12:54:41.722332+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/zeitwerk-2.6.11/lib/zeitwerk/loader/helpers.rb:25:in `each'
2023-08-11T12:54:41.722333+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/zeitwerk-2.6.11/lib/zeitwerk/loader/helpers.rb:25:in `ls'
2023-08-11T12:54:41.722342+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/zeitwerk-2.6.11/lib/zeitwerk/loader/eager_load.rb:170:in `actual_eager_load_dir'
2023-08-11T12:54:41.722342+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/zeitwerk-2.6.11/lib/zeitwerk/loader/eager_load.rb:17:in `block (2 levels) in eager_load'
2023-08-11T12:54:41.722343+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/zeitwerk-2.6.11/lib/zeitwerk/loader/eager_load.rb:16:in `each'
2023-08-11T12:54:41.722344+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/zeitwerk-2.6.11/lib/zeitwerk/loader/eager_load.rb:16:in `block in eager_load' 
2023-08-11T12:54:41.722345+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/zeitwerk-2.6.11/lib/zeitwerk/loader/eager_load.rb:10:in `synchronize'
2023-08-11T12:54:41.722346+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/zeitwerk-2.6.11/lib/zeitwerk/loader/eager_load.rb:10:in `eager_load'
2023-08-11T12:54:41.722347+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/zeitwerk-2.6.11/lib/zeitwerk/loader.rb:379:in `block in eager_load_all'       
2023-08-11T12:54:41.722348+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/zeitwerk-2.6.11/lib/zeitwerk/loader.rb:377:in `each'
2023-08-11T12:54:41.722349+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/zeitwerk-2.6.11/lib/zeitwerk/loader.rb:377:in `eager_load_all'
2023-08-11T12:54:41.722350+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/application/finisher.rb:74:in `block in <module:Finisher>'
2023-08-11T12:54:41.722351+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/initializable.rb:32:in `instance_exec'
2023-08-11T12:54:41.722352+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/initializable.rb:32:in `run'
2023-08-11T12:54:41.722353+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/initializable.rb:61:in `block in run_initializers'   
2023-08-11T12:54:41.722362+00:00 app[web.1]: from /app/vendor/ruby-3.1.2/lib/ruby/3.1.0/tsort.rb:228:in `block in tsort_each'
2023-08-11T12:54:41.722362+00:00 app[web.1]: from /app/vendor/ruby-3.1.2/lib/ruby/3.1.0/tsort.rb:350:in `block (2 levels) in each_strongly_connected_component'    
2023-08-11T12:54:41.722362+00:00 app[web.1]: from /app/vendor/ruby-3.1.2/lib/ruby/3.1.0/tsort.rb:431:in `each_strongly_connected_component_from'
2023-08-11T12:54:41.722363+00:00 app[web.1]: from /app/vendor/ruby-3.1.2/lib/ruby/3.1.0/tsort.rb:349:in `block in each_strongly_connected_component'
2023-08-11T12:54:41.722364+00:00 app[web.1]: from /app/vendor/ruby-3.1.2/lib/ruby/3.1.0/tsort.rb:347:in `each'
2023-08-11T12:54:41.722364+00:00 app[web.1]: from /app/vendor/ruby-3.1.2/lib/ruby/3.1.0/tsort.rb:347:in `call'
2023-08-11T12:54:41.722365+00:00 app[web.1]: from /app/vendor/ruby-3.1.2/lib/ruby/3.1.0/tsort.rb:347:in `each_strongly_connected_component'
2023-08-11T12:54:41.722366+00:00 app[web.1]: from /app/vendor/ruby-3.1.2/lib/ruby/3.1.0/tsort.rb:226:in `tsort_each'
2023-08-11T12:54:41.722367+00:00 app[web.1]: from /app/vendor/ruby-3.1.2/lib/ruby/3.1.0/tsort.rb:205:in `tsort_each'
2023-08-11T12:54:41.722368+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/initializable.rb:60:in `run_initializers'
2023-08-11T12:54:41.722377+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/application.rb:372:in `initialize!'
2023-08-11T12:54:41.722377+00:00 app[web.1]: from /app/config/environment.rb:5:in `<main>'
2023-08-11T12:54:41.722377+00:00 app[web.1]: from config.ru:3:in `require_relative'
2023-08-11T12:54:41.722377+00:00 app[web.1]: from config.ru:3:in `block in <main>'
2023-08-11T12:54:41.722379+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/rack-2.2.8/lib/rack/builder.rb:116:in `eval'
2023-08-11T12:54:41.722379+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/rack-2.2.8/lib/rack/builder.rb:116:in `new_from_string'
2023-08-11T12:54:41.722380+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/rack-2.2.8/lib/rack/builder.rb:105:in `load_file'
2023-08-11T12:54:41.722381+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/rack-2.2.8/lib/rack/builder.rb:66:in `parse_file'
2023-08-11T12:54:41.722382+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/rack-2.2.8/lib/rack/server.rb:349:in `build_app_and_options_from_config'      
2023-08-11T12:54:41.722383+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/rack-2.2.8/lib/rack/server.rb:249:in `app'
2023-08-11T12:54:41.722384+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/rack-2.2.8/lib/rack/server.rb:422:in `wrapped_app'
2023-08-11T12:54:41.722385+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/rack-2.2.8/lib/rack/server.rb:312:in `block in start'
2023-08-11T12:54:41.722386+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/rack-2.2.8/lib/rack/server.rb:379:in `handle_profiling'
2023-08-11T12:54:41.722387+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/rack-2.2.8/lib/rack/server.rb:311:in `start'
2023-08-11T12:54:41.722388+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/commands/server/server_command.rb:38:in `start'      
2023-08-11T12:54:41.722389+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/commands/server/server_command.rb:143:in `block in perform'
2023-08-11T12:54:41.722391+00:00 app[web.1]: from <internal:kernel>:90:in `tap'
2023-08-11T12:54:41.722392+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/commands/server/server_command.rb:134:in `perform'   
2023-08-11T12:54:41.722393+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/thor-1.2.2/lib/thor/command.rb:27:in `run'
2023-08-11T12:54:41.722394+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/thor-1.2.2/lib/thor/invocation.rb:127:in `invoke_command'
2023-08-11T12:54:41.722396+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/thor-1.2.2/lib/thor.rb:392:in `dispatch'
2023-08-11T12:54:41.722397+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/command/base.rb:87:in `perform'
2023-08-11T12:54:41.722398+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/command.rb:48:in `invoke'
2023-08-11T12:54:41.722399+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/railties-7.0.4/lib/rails/commands.rb:18:in `<main>'
2023-08-11T12:54:41.722400+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/bootsnap-1.12.0/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in 
`require'
2023-08-11T12:54:41.722401+00:00 app[web.1]: from /app/vendor/bundle/ruby/3.1.0/gems/bootsnap-1.12.0/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in 
`require'
2023-08-11T12:54:41.722409+00:00 app[web.1]: from bin/rails:4:in `<main>'
2023-08-11T12:54:41.857968+00:00 heroku[web.1]: Process exited with status 1
2023-08-11T12:54:41.889921+00:00 heroku[web.1]: State changed from starting to crashed
2023-08-11T12:54:47.947717+00:00 app[api]: Scaled to console@0:Basic rake@0:Basic web@0:Basic by user [email protected]
2023-08-11T12:54:48.064190+00:00 heroku[web.1]: State changed from crashed to down
2023-08-11T12:58:34.278315+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=te12-6495be2.herokuapp.com request_id=93c011d5-671d-4217-9013-ba5b1013ea8c fwd="141.523.183.145" dyno= connect= service= status=503 bytes= protocol=https
2023-08-11T12:58:34.762225+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=t12-6495b8e2.herokuapp.com request_id=450be1eb-711e-4545-80cd-5c2850c560f8 fwd="111.223.183.155" dyno= connect= service= status=503 bytes= protocol=https

谁能告诉我该怎么做,Rails应用程序很简单,它只有helloworld

polhcujo

polhcujo1#

看起来你在使用sqlite3-这在Heroku上不起作用。您需要切换到数据库服务器,最常用的是Postgres。
参见https://devcenter.heroku.com/articles/sqlite3

相关问题