2012-12-20 35 views

回答

1

當您推送應用程序時,不是爲框架選擇'Rails',而是選擇'other',然後'standalone',然後系統會提示您提供一個命令來啓動應用程序,這是您要輸入的位置bundle exec sidekiq

+0

整個應用程序是Rails應用程序,Sikdekiq只是其中的一部分。所以,你說的方式 - 如何推Rails應用程序?或者他們需要獨立推送? – Nishant

+0

獨立,是的,最簡單的方法是維護兩種清單,您可以根據是否要推送員工或Web應用程序來進行交換。或者,你可以寫一個腳本,像這樣... https://github.com/danhigham/log_squirrel/blob/master/deploy.rb,前者雖然可能更容易:-) –

+0

我剛剛說過,但任務仍然不運行。在日誌中,我剛剛看到sidekiq已啓動,但沒有執行任何工作 – Nishant

0

嘗試創建一個新的清單(manifest.worker.yml),幷包括以下內容:

applications: 
    .: 
    name: APPNAME-worker 
    framework: 
     name: standalone 
     info: 
     mem: 64M 
     description: Standalone Application 
     exec: 
    url: 
    path: . 
    runtime: ruby19 
    command: bundle exec sidekiq -e production 
    mem: 256M 
    instances: 1 
    services: 
     APPNAME-postgresql: 
     type: postgresql 
     APPNAME-redis: 
     type: redis 

現在開始你sidekiq工人:

vmc push --manifest manifest.worker.yml --path . 

服務應該與您的網絡應用程序的manifest.yml中包含的服務相同。