I have a simple Procfile that states:
web: bundle exec rails server thin -p $PORT
worker: bundle exec rake jobs:work
In Heroku, this will launch N work tasks, where N is what I scaled.
In my development system
$ foreman start
runs only one work task. If I want to run three workers, I need a Procfile that looks like this:
web: bundle exec rails server thin -p $PORT
worker: bundle exec rake jobs:work
worker: bundle exec rake jobs:work
worker: bundle exec rake jobs:work
This is a somewhat pedantic question, but if I want my development environment to behave like my Heroku environment, what is the best way to run N work tasks? Is it an approved way to create (e.g. Procfile_local) and use it through foreman -f Procfile_local?
source
share