Given the guard-rails gem is an easy way to start a rails server and to relaunch it automatically during development as the source files change;
how should this gem be used to launch the processes in a Procfile instead of having it run rails s
?
I have already found the foreman gem, which can read and start each process listed in the Procfile with foreman start
.
Thanks! -A
This is a bad approach. Each process should be managed individually by guard so that they can
you could fork the gem and add your changes to the RailsRunner that has a hardcoded command:
%{sh -c 'cd #{Dir.pwd} && rails s #{rails_options.join(' ')} &'}
https://github.com/guard/guard-rails/blob/master/lib/guard/rails/runner.rb
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With