I'm trying to run heroku CLI commands like:
heroku run rake db:migrate --app app-name
heroku run rake db:seed --app app-name
from a Resque worker running in the background.
If I run the worker in the foreground with:
RAILS_ENV=production rake resque:work QUEUE="*"
the process completes successfully, and the rake tasks are run.
However, when the worker is started like so:
RAILS_ENV=production PIDFILE=./resque.pid BACKGROUND=yes QUEUE="*" rake resque:work >> worker1.log
the processes silently fail with no indication of what happened in the logs. Is there a way to run these tasks in the background?