2015-09-02 48 views
0

推到Heroku后的某个时候,我的应用程序崩溃了。哪个宝石更新崩溃heroku部署?

使用Heroku的回滚功能,我发现最近的工作承诺。

但是,当我恢复到它,应用程序仍然崩溃。

的错误是数据库没有指定adapter--但没有在数据库配置文件更改...

remote:  Using rake 10.4.2 
remote:  Using i18n 0.7.0 
remote:  Using json 1.8.3 
remote:  Using minitest 5.8.0 
remote:  Using thread_safe 0.3.5 
remote:  Using tzinfo 1.2.2 
remote:  Using activesupport 4.2.4 
remote:  Using builder 3.2.2 
remote:  Using activemodel 4.2.4 
remote:  Using arel 6.0.3 
remote:  Using activerecord 4.2.4 
remote:  Using bundler 1.9.7 
remote:  Using dotenv 2.0.2 
remote:  Using nenv 0.2.0 
remote:  Using rspec-logsplit 0.1.3 
remote:  Using hitimes 1.2.2 
remote:  Using timers 4.1.1 
remote:  Using celluloid-essentials 0.20.2.1 
remote:  Using celluloid-extras 0.20.1 
remote:  Using celluloid-fsm 0.20.1 
remote:  Using celluloid-pool 0.20.1 
remote:  Using celluloid-supervision 0.20.1.1 
remote:  Using celluloid 0.17.1.2 
remote:  Using connection_pool 2.2.0 
remote:  Using ice_cube 0.11.1 
remote:  Using jwt 1.5.1 
remote:  Using kgio 2.9.3 
remote:  Using multi_json 1.11.2 
remote:  Using newrelic_rpm 3.13.0.299 
remote:  Using numbers_in_words 0.2.0 
remote:  Using pg 0.18.2 
remote:  Using r18n-core 2.0.4 
remote:  Using rack 1.6.4 
remote:  Using rack-protection 1.5.3 
remote:  Using raindrops 0.15.0 
remote:  Using redis 3.2.1 
remote:  Using redis-namespace 1.5.2 
remote:  Using sidekiq 3.4.0 
remote:  Using sidetiq 0.6.3 
remote:  Using tilt 2.0.1 
remote:  Using sinatra 1.4.6 
remote:  Using sinatra-activerecord 2.0.8 
remote:  Using sinatra-r18n 2.0.4 
remote:  Using twilio-ruby 4.3.0 
remote:  Using unicorn 4.9.0 
remote:  Bundle complete! 20 Gemfile dependencies, 45 gems now installed. 
remote:  Gems in the groups development and test were not installed. 
remote:  Bundled gems are installed into ./vendor/bundle. 
remote:  Bundle completed (0.52s) 
remote:  Cleaning up the bundler cache. 
remote:  Could not detect rake tasks 
remote:  ensure you can run `$ bundle exec rake -P` against your app with no environment variables present 
remote:  and using the production group of your Gemfile. 
remote:  rake aborted! 
remote:  ActiveRecord::AdapterNotSpecified: database configuration does not specify adapter 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/activerecord-4.2.4/lib/active_record/connection_adapters/connection_specification.rb:171:in `spec' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/activerecord-4.2.4/lib/active_record/connection_handling.rb:50:in `establish_connection' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/sinatra-activerecord-2.0.8/lib/sinatra/activerecord.rb:43:in `database=' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:1216:in `set' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/sinatra-activerecord-2.0.8/lib/sinatra/activerecord.rb:35:in `database_file=' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:1216:in `set' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/sinatra-activerecord-2.0.8/lib/sinatra/activerecord.rb:19:in `registered' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:1399:in `block in register' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:1397:in `each' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:1397:in `register' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:1977:in `register' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:2038:in `register' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/sinatra-activerecord-2.0.8/lib/sinatra/activerecord.rb:54:in `<module:Sinatra>' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/sinatra-activerecord-2.0.8/lib/sinatra/activerecord.rb:10:in `<top (required)>' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/app.rb:2:in `require 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/app.rb:2:in `<top (required)>' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/Rakefile:1:in `require' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/Rakefile:1:in `<top (required)>' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/rake-10.4.2/lib/rake/rake_module.rb:28:in `load' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/rake-10.4.2/lib/rake/rake_module.rb:28:in `load_rakefile' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/rake-10.4.2/lib/rake/application.rb:689:in `raw_load_rakefile' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/rake-10.4.2/lib/rake/application.rb:94:in `block in load_rakefile' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/rake-10.4.2/lib/rake/application.rb:176:in `standard_exception_handling' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/rake-10.4.2/lib/rake/application.rb:93:in `load_rakefile' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/rake-10.4.2/lib/rake/application.rb:77:in `block in run' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/rake-10.4.2/lib/rake/application.rb:176:in `standard_exception_handling' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/rake-10.4.2/lib/rake/application.rb:75:in `run' 
remote:  /tmp/build_0638ee1c1d8c7aba8badade98388cd53/vendor/bundle/ruby/2.0.0/gems/rake-10.4.2/bin/rake:33:in `<top (required)>' 
remote:  vendor/bundle/bin/rake:16:in `load' 
remote:  vendor/bundle/bin/rake:16:in `<main>' 
remote: 
remote: ###### WARNING: 
remote:  You have not declared a Ruby version in your Gemfile. 
remote:  To set your Ruby version add this line to your Gemfile: 
remote:  ruby '2.0.0' 
remote:  # See https://devcenter.heroku.com/articles/ruby-versions for more information. 
remote: 
remote: -----> Discovering process types 
remote:  Procfile declares types -> web 
remote:  Default types for Ruby -> console, rake 
remote: 
remote: -----> Compressing... done, 26.0MB 
remote: -----> Launching... done, v372 
remote:  https://joinstorytime.herokuapp.com/ deployed to Heroku 
remote: 

难道这是由于越野车的宝石更新?无论如何回到以前版本的宝石版本?

+0

要问一个简单的问题:是否有其他人在你的团队谁可能没有做宝石更新?该应用是否适合这些人? –

+0

我是目前唯一在这个项目上工作的人,所以这不会奏效,可悲的是。我不知道还有什么可能,只是一个有缺陷的宝石,因为我已经恢复了所有工作提交(并在之前),但仍然在部署时崩溃。 – Phil

+0

阅读你的堆栈跟踪。你有一个数据库配置问题。另请阅读:http://stackoverflow.com/questions/23336755/activerecordadapternotspecified-database-configuration-does-not-specify-adapte –

回答

0

由于Heroku的创建config/database.yml文件,覆盖你可能在你的项目中的一个,这是一个有点难以解决。

我的猜测是,配置变量(可能DATABASE_URL)被改变,新的价值有无效字符或以某种方式格式不正确。当您回滚Heroku应用程序时,它还会回滚配置变量更改。尽管如此,你仍然可以在应用历史中看到变化的变化。