In case Unicorn process has been stopped with SIGKILL signal and PID file is exists, anicorn tries to restart Unicorn and, unsurprisingly, exits with an error. I suggest adding an extra check of PID file existence and remove it if process is dead.
How did you implement it:
I added one more condition to checkPIDFile function to remove stale PID file.
How can we verify it:
Finish Unicorn process with SIGKILL signal.
Make sure that PID file exists.
Run anicorn.
It should successfully start the new Unicorn process.
Is this ready for review?: Yes
Is it a breaking change?: No
What did you implement:
In case Unicorn process has been stopped with SIGKILL signal and PID file is exists,
anicorn
tries to restart Unicorn and, unsurprisingly, exits with an error. I suggest adding an extra check of PID file existence and remove it if process is dead.How did you implement it:
I added one more condition to
checkPIDFile
function to remove stale PID file.How can we verify it:
anicorn
.It should successfully start the new Unicorn process.
Is this ready for review?: Yes Is it a breaking change?: No