2015-01-16 310 views
0

我一直在使用NitrousIO作为我的环境和Heroku for Deployment的Ruby on Rails应用程序开发。对于一些模块,我可以成功部署在Heroku和它的工作不错,但对于某些模块,它说:We're sorry, but something went wrong.Heroku迁移问题

我去过的所有步骤一样heroku run rake db:migrate推最新代码的Heroku,但没有成功后但在NitrousIO,一切都运行完美

  1. 什么是现在重置我在Heroku分贝,使得它可以为所有的模块工作,没有问题的方式。指南/请指点一步的过程,请
  2. 是否只有数据库重置选项开始或我们有任何中间解决方案,让我摆脱这种情况?

这些都是我的Heroku日志与heroku logs -n 250

[email protected]:~/enterpriseape(nesting-purchases)$ heroku logs -n 250                              
2015-01-16T16:35:08.590482+00:00 heroku[web.1]: Unidling                                    
2015-01-16T16:35:08.591399+00:00 heroku[web.1]: State changed from down to starting                             
2015-01-16T16:35:12.002231+00:00 heroku[web.1]: Starting process with command `bin/rails server -p 46010 -e production`                    
2015-01-16T16:35:16.619546+00:00 app[web.1]: [2015-01-16 16:35:16] INFO WEBrick 1.3.1                             
2015-01-16T16:35:16.619962+00:00 app[web.1]: [2015-01-16 16:35:16] INFO WEBrick::HTTPServer#start: pid=3 port=46010                     
2015-01-16T16:35:16.619570+00:00 app[web.1]: [2015-01-16 16:35:16] INFO ruby 2.0.0 (2014-11-13) [x86_64-linux]                      
2015-01-16T16:35:16.950487+00:00 heroku[web.1]: State changed from starting to up                              
2015-01-16T16:35:17.990652+00:00 heroku[router]: at=info method=GET path="/" host=enterpriseape-ramakballa.herokuapp.com request_id=6a0355dc-73fd-4b10-9a2e-066ae51a403a fwd="49.205.144.212" dyno=web 
.1 connect=2ms service=115ms status=200 bytes=1896                                      
2015-01-16T16:35:24.243086+00:00 heroku[router]: at=info method=GET path="/assets/application-f71602a6cb0cb5ada02d834e1b9e35cb.css" host=enterpriseape-ramakballa.herokuapp.com request_id=6251571f-d5 
6c-4af4-bc4a-7bf0b4ea1961 fwd="49.205.144.212" dyno=web.1 connect=2ms service=5817ms status=304 bytes=231                        
2015-01-16T16:35:24.699601+00:00 heroku[router]: at=info method=GET path="/favicon.ico" host=enterpriseape-ramakballa.herokuapp.com request_id=0cc95f6f-5255-4345-8f63-e53c43bad31f fwd="49.205.144.21 
2" dyno=web.1 connect=1ms service=9ms status=404 bytes=1829                                   
2015-01-16T16:35:50.967577+00:00 heroku[router]: at=info method=GET path="/invoices" host=enterpriseape-ramakballa.herokuapp.com request_id=e8cdea65-e2f0-4a5a-acbd-cbd599a5e8a6 fwd="49.205.144.212" 
dyno=web.1 connect=2ms service=108ms status=200 bytes=2765                                    
2015-01-16T16:35:51.378408+00:00 heroku[router]: at=info method=GET path="/assets/application-f71602a6cb0cb5ada02d834e1b9e35cb.css" host=enterpriseape-ramakballa.herokuapp.com request_id=9d2facec-b8 
cb-40d5-aebf-264154e5e59e fwd="49.205.144.212" dyno=web.1 connect=2ms service=14ms status=304 bytes=231                        
[email protected]:~/enterpriseape(nesting-purchases)$ 

enter image description here

+0

对Heroku的数据库中的所有命令可以发现这里列出:http://stackoverflow.com/questions/4820549/how-to-empty-db-in-heroku如果他们没有帮助,你可以发布从Heroku获得的确切错误吗?你应该能够在日志'heroku logs'中看到它(如果你需要更多的话,''heroku logs -n 1500'')。 – basiam

+0

我已经粘贴了我的日志。即使我已经尝试过heroku pg:重置DATABASE并重新启动它,但仍然像'我们很抱歉.....'的相同问题,让我知道是否需要任何其他信息... –

+0

嗯,没有错误在这部分日志中。你能1)试图触发错误2)看到什么显示在日志中,看到“我们很抱歉..”3)立即找到错误日志并粘贴它? – basiam

回答

0

基于“缺少主机链接到”你的截图它看起来像你缺少一些配置错误信息上。 link_to方法需要知道用于为给定链接生成完整URL的主机名。您可以在每个环境文件中配置这一点,在这种情况下,你需要像这样添加到您的config/environments/production.rb

config.action_mailer.default_url_options = { :host => "enterpriseape-ramakballa.herokuapp.com" } 
+0

非常感谢,它现在可以像Heroku一样在Heroku上运行。 –