我运行迁移时出现heroku错误(rails 3.1 cedar stack)

发布于 2024-12-20 04:00:18 字数 1711 浏览 0 评论 0原文

已解决:由于网络限制

,我刚刚推送了我的应用程序,我需要运行我的迁移文件来初始化数据库,

我收到以下错误:我应该做什么?

编辑:heroku run bash -app appname 产生相同的错误

Running rake db:migrate attached to terminal... /Users/stan/.rvm/gems/ruby-1.9.2-p290/gems/heroku-2.14.0/lib/heroku/client/rendezvous.rb:33:in `initialize': Operation timed out - connect(2) (Errno::ETIMEDOUT)
    from /Users/stan/.rvm/gems/ruby-1.9.2-p290/gems/heroku-2.14.0/lib/heroku/client/rendezvous.rb:33:in `open'
    from /Users/stan/.rvm/gems/ruby-1.9.2-p290/gems/heroku-2.14.0/lib/heroku/client/rendezvous.rb:33:in `block in start'
    from /Users/stan/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/timeout.rb:58:in `timeout'
    from /Users/stan/.rvm/gems/ruby-1.9.2-p290/gems/heroku-2.14.0/lib/heroku/client/rendezvous.rb:27:in `start'
    from /Users/stan/.rvm/gems/ruby-1.9.2-p290/gems/heroku-2.14.0/lib/heroku/command/run.rb:36:in `index'
    from /Users/stan/.rvm/gems/ruby-1.9.2-p290/gems/heroku-2.14.0/lib/heroku/command.rb:114:in `run'
    from /Users/stan/.rvm/gems/ruby-1.9.2-p290/gems/heroku-2.14.0/bin/heroku:14:in `<top (required)>'
    from /Users/stan/.rvm/gems/ruby-1.9.2-p290/bin/heroku:19:in `load'
    from /Users/stan/.rvm/gems/ruby-1.9.2-p290/bin/heroku:19:in `<main>'

这是运行 heroku ps 来检查我正在运行的进程的结果:

Process State Command 
-------------------------------------------------------- 
run.1 complete for 24m bundle exec rake db:migrate 
run.2 complete for 22m bundle exec rake db:migrate 
run.3 complete for 16m bash 
run.4 complete for 5m bundle exec rake db:migrate 
run.5 complete for 1m bundle exec rake db:migrate 
web.1 up for 6m bundle exec rails server -p $PORT 

SOLVED: was due to network limitation

I just pushed my app and i need to run my migration files to initialize the database

i get the following error: what should i do ?

EDIT: heroku run bash -app appname yields the same error

Running rake db:migrate attached to terminal... /Users/stan/.rvm/gems/ruby-1.9.2-p290/gems/heroku-2.14.0/lib/heroku/client/rendezvous.rb:33:in `initialize': Operation timed out - connect(2) (Errno::ETIMEDOUT)
    from /Users/stan/.rvm/gems/ruby-1.9.2-p290/gems/heroku-2.14.0/lib/heroku/client/rendezvous.rb:33:in `open'
    from /Users/stan/.rvm/gems/ruby-1.9.2-p290/gems/heroku-2.14.0/lib/heroku/client/rendezvous.rb:33:in `block in start'
    from /Users/stan/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/timeout.rb:58:in `timeout'
    from /Users/stan/.rvm/gems/ruby-1.9.2-p290/gems/heroku-2.14.0/lib/heroku/client/rendezvous.rb:27:in `start'
    from /Users/stan/.rvm/gems/ruby-1.9.2-p290/gems/heroku-2.14.0/lib/heroku/command/run.rb:36:in `index'
    from /Users/stan/.rvm/gems/ruby-1.9.2-p290/gems/heroku-2.14.0/lib/heroku/command.rb:114:in `run'
    from /Users/stan/.rvm/gems/ruby-1.9.2-p290/gems/heroku-2.14.0/bin/heroku:14:in `<top (required)>'
    from /Users/stan/.rvm/gems/ruby-1.9.2-p290/bin/heroku:19:in `load'
    from /Users/stan/.rvm/gems/ruby-1.9.2-p290/bin/heroku:19:in `<main>'

This is the result of running heroku ps to check my running processes:

Process State Command 
-------------------------------------------------------- 
run.1 complete for 24m bundle exec rake db:migrate 
run.2 complete for 22m bundle exec rake db:migrate 
run.3 complete for 16m bash 
run.4 complete for 5m bundle exec rake db:migrate 
run.5 complete for 1m bundle exec rake db:migrate 
web.1 up for 6m bundle exec rails server -p $PORT 

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

东京女 2024-12-27 04:00:18

Heroku 在我的一些应用程序上遇到了迁移问题。他们告诉我这样做:

heroku run bash --app appname
rake db:migrate

Heroku has had issues with migrations on some of my apps. They have told me to do this:

heroku run bash --app appname
rake db:migrate
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文