2012-07-26 51 views
0

昨晚做了一个大的更新,我的网站目前正在关闭。我用cap deploy:rollback没有运气。错误日志没有告诉我很多。尝试部署,当我看到最后一个错误是:如何修复糟糕的Capistrano部署?

** [out :: website.com] You are trying to install in deployment mode after changing 
** [out :: website.com] your Gemfile. Run `bundle install` elsewhere and add the 
** [out :: website.com] updated Gemfile.lock to version control. 
** [out :: website.com] 
** [out :: website.com] You have deleted from the Gemfile: 
** [out :: website.com] * asset_sync 
    command finished in 934ms 

cap tail只是说没有任何错误如下:

Migrating to AddSessionsTable (20120722094547) 
Migrating to AddSlugToUserProjects (20120723204816) 
Migrating to AddSlugIndexToUserProjects (20120723205558) 
Migrating to CreateFriendlyIdSlugs (904) 
Migrating to AddNameToUsers (20120723221700) 
Migrating to AddSlugToUsers (20120723222456) 
Migrating to CreateComments (20120724203252) 

任何帮助吗?

回答

0

它看起来像Gemfile变化不顺利。它如何修复:

  1. 登录到服务器,有6个红宝石进程正在采取所有可用的东西。这是几乎可以肯定尝试启动麒麟工艺和不能... killall -9 ruby
  2. CD到应用程序的当前目录
  3. RAILS_ENV =产品包的exec耙资产:预编译
  4. 服务unicorn_whimseybox启动

它看起来像(在unicorn.log中),错误是: E,[2012-07-26T17:27:10.552912#24818]错误 - :未初始化的常量AssetSync(NameError)

0

在您的开发服务器上运行bundle install,然后在cap deploy上运行。另一个可能的解决方案:将asset_sync添加回您的Gemfile。

作为最后的手段,您可以运行cap -d deploy。它将逐步运行部署,要求您继续执行每一步。在单独的shell中登录到生产服务器,并手动在步骤之间进行一些调整。

0

我在转换一些锗mfile source分成块。

错误是由于生产时的旧Bundler版本(1.7.3)与开发时的1.8.3。