Open inyerade opened 6 years ago
@inyerade
Puma phased_restart has two requirements
Important info https://github.com/puma/puma/blob/master/docs/restart.md
I spent hours debugging why deployment wouldn't work, then I finally stumbled over this.
I tried activating 3 workers in puma.rb
:
workers ENV.fetch("WEB_CONCURRENCY") { 3 }
But didn't work for me. I just switched to puma:hard_restart
in the deploy.rb
config. Now it seems to work:
-----> Restart Puma -- hard...
-----> Stopping Puma...
Puma is not running!
-----> Starting Puma...
Puma starting in single mode...
* Version 4.1.1 (ruby 2.4.1-p111), codename: Fourth and One
* Min threads: 5, max threads: 5
* Environment: production
* Daemonizing...
By the way, puma:restart
doesn't seem to work:
-----> Restart Puma....
Puma is not running!
I feel this info should be added to the README.
PS: In the docs (https://github.com/puma/puma/blob/master/docs/restart.md), there is no "hard restart" mentioned. Is "hot restart" equivalent to "hard restart"? Or what's the difference?
I do a new feature adding a new gem and when I want to deploy I execute
mina deploy
.In the deploy the new gem install but the I get error when I go to a page where I use this gem. Then I do a
mina puma:phased_restart
and the behavor is the same. Then I do amina puma:stop
and amina puma:start
and work perfectI do not know what is wrong