mirror of
https://github.com/puma/puma.git
synced 2022-11-09 13:48:40 -05:00
bebdf266e5
Before this fix if you have an application that uses Puma and this plugin it is impossible to start 2 servers at once even if they are using separate pidfiles and ports. The reason is because this plugin will overwrite the pidfiles no matter. To reproduce: Start a regular Rails server which points to the pidfile in `tmp/pids/server.pid` ``` rails s ``` Start a second Rails server which points to a new pidfile and port ``` rails s -p 4000 -P tmp/pids/new_server.pid ``` The first server will be stopped and claim that the pid is being used by another process. What really is happening is the restart plugin is writing over the original pidfile which stops the server. If we check the file exists first this will prevent the problem from occuring. Touching tmp/restart.txt will still work but starting a separate process with it's own pidfile should not interfere with other running servers in the same app. |
||
---|---|---|
.. | ||
tmp_restart.rb |