2012-12-23 33 views
1

我使用nginx的+麒麟+ Capistrano的部署我的服務器上的應用程序。我的數據庫是sqlite,因爲我只有一個小表。 我deploy.rb配置在這裏deploy.rb很抱歉,但出事了Capistrano的部署

當我做帽部署:安裝然後帽部署:冷應用程序工作正常。 當我做一些修改,然後提交併運行帽部署我有

**We're sorry, but something went wrong.** 

在production.rb我有以下錯誤

Processing by DomainsController#index as */* 
Completed 500 Internal Server Error in 1ms 

ActiveRecord::StatementInvalid (Could not find table 'domains'): 
app/controllers/domains_controller.rb:8:in `index' 

我不明白爲什麼我看到這個錯誤?如何檢查我錯在哪裏?

回答

1

每個部署是創建你的服務器稱爲當前上,因爲你的數據庫是不是在源代碼控制系統的版本(和它不應該是),它是在每次部署後失去了新的目錄。你需要把你的sqlite數據庫放到共享文件夾中,並在你的部署中將它鏈接。

相關問題