ruby-on-rails – heroku db:migrate aborted

前端之家收集整理的这篇文章主要介绍了ruby-on-rails – heroku db:migrate aborted前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。
我是 Ruby on Rails和heroku的新手.我按照视频教程中的步骤进行操作.我认为我没有做任何不同的事情.但是,我无法在heroku上运行rake db:migrate,而一切都在我的localhost:3000上运行
您还可以详细说明GEMFILE.lock和GEMFILE的功能. @H_301_3@$heroku run rake db:migrate Running `rake db:migrate` attached to terminal... up,run.9550 DEPRECATION WARNING: You have Rails 2.3-style plugins in vendor/plugins! Support for these plugins will be removed in Rails 4.0. Move them out and bundle them in your Gemfile,or fold them in to your app as lib/myplugin/* and config/initializers/myplugin.rb. See the release notes for more on this: http://weblog.rubyonrails.org/2012/1/4/rails-3-2-0-rc2-has-been-released. (called from <top (required)> at /app/Rakefile:7) DEPRECATION WARNING: You have Rails 2.3-style plugins in vendor/plugins! Support for these plugins will be removed in Rails 4.0. Move them out and bundle them in your Gemfile,or fold them in to your app as lib/myplugin/* and config/initializers/myplugin.rb. See the release notes for more on this: http://weblog.rubyonrails.org/2012/1/4/rails-3-2-0-rc2-has-been-released. (called from <top (required)> at /app/Rakefile:7) Connecting to database specified by DATABASE_URL rake aborted! could not translate host name "ec2-54-225-69-193.compute-1.amazonaws.com" to address: Temporary failure in name resolution /app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/postgresql_adapter.rb:1216:in `initialize' /app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/postgresql_adapter.rb:1216:in `new' /app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/postgresql_adapter.rb:1216:in `connect' /app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/postgresql_adapter.rb:324:in `initialize' /app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/postgresql_adapter.rb:28:in `new' /app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/postgresql_adapter.rb:28:in `postgresql_connection'

我的GEMFILE的相关内容

@H_301_3@group :production do gem 'pg' end group :development,:test do gem 'sqlite3' end

我的GEMFILE.lock的相关内容

@H_301_3@sqlite3 (1.3.7) thor (0.18.0) tilt (1.3.6) treetop (1.4.12) polyglot polyglot (>= 0.3.1) tzinfo (0.3.37) uglifier (1.3.0) execjs (>= 0.3.0) multi_json (~> 1.0,>= 1.0.2) PLATFORMS ruby DEPENDENCIES coffee-rails (~> 3.2.1) jquery-rails pg rails (= 3.2.13) sass-rails (~> 3.2.3) sqlite3 uglifier (>= 1.0.3)

解决方法

这与您的代码或ruby在轨道上没有任何关系.

它是一个DNS错误,如果你有你的rails应用程序和Heroku中的数据库(这是默认的),然后尝试达到heroku支持,并继续尝试,一旦dns更新它应该工作,但以防万一,尝试联系Heroku支持,他们应该能够很快解决问题.

猜你在找的Ruby相关文章