Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(nginx) wait for nginx reload to avoid zombies #6

Conversation

felixbuenemann
Copy link
Contributor

If a unix process is spawned, the parent process must wait for its pid or the process will become a zombie after exit. This fixes the problem that the /opt/router/sbin/router binary leaves behing a defunct nginx process each time the config is reloaded by spawning "nginx -s reload".

Copied from deis/router#356 by request of @Cryptophobia to fix deis/router#331.

If a unix process is spawned, the parent process must wait for its pid
or the process will become a zombie after exit. This fixes the problem
that the "/opt/router/sbin/router" binary leaves behing a defunct nginx
process each time the config is reloaded by spawning "nginx -s reload".
@Cryptophobia
Copy link
Member

@felixbuenemann : Thank you for the PR! We are going to merge this in now because we trust that it has been tested on your side and it is a very small isolated change.

By the way, are you using Workflow in production? Are you interested in joining the fork as a maintainer?

@Cryptophobia Cryptophobia self-assigned this Jan 30, 2018
@Cryptophobia Cryptophobia self-requested a review January 30, 2018 14:34
Copy link
Member

@Cryptophobia Cryptophobia left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good!

@Cryptophobia Cryptophobia merged commit 87e61d9 into teamhephy:master Jan 30, 2018
@felixbuenemann
Copy link
Contributor Author

By the way, are you using Workflow in production?

Yes, we are currently running 2 Staging and 2 Production clusters with Deis Workflow on AWS.

Are you interested in joining the fork as a maintainer?

I'm already way too busy and we might switch to vanilla k8s or possibly convox in the future – but it is nice to have this fork as an alternative.

In the mean time I will send pull requests with fixes to hephy, if I have any.

@felixbuenemann felixbuenemann deleted the fix-nginx-zombies-on-config-reload branch January 30, 2018 14:46
@Cryptophobia
Copy link
Member

I'm already way too busy and we might switch to vanilla k8s or possibly convox in the future – but it is nice to have this fork as an alternative.

Okay, no problem. Nice of you to keep the fork in mind.

In the mean time I will send pull requests with fixes to hephy, if I have any.

Okay, thank you for your help! 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Router makes zombies permanently
2 participants