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

Close process when stdin is closed. #1658

Closed
wants to merge 2 commits into from
Closed

Close process when stdin is closed. #1658

wants to merge 2 commits into from

Conversation

ndarilek
Copy link

I'm using Nuxt as the builder for assets in a Phoenix application. Phoenix uses Erlang's ports mechanism to open the binary for the asset builder. This mechanism expects the binary to terminate when STDIN is closed.

Without this patch, Nuxt can be used as an asset builder. However, killing the Elixir process leaves the Nuxt process still running. With this patch, Nuxt binaries like nuxt-dev terminate correctly when the Elixir process is killed.

@pi0
Copy link
Member

pi0 commented Oct 13, 2017

Hi. I think that's a really special use case. Process managers usually use SIGINT for gracefully shutdown signal. and we can add such hook inside nuxt.config.js or maybe a module to add this.

@pi0 pi0 requested a review from Atinux October 13, 2017 08:36
@Atinux Atinux closed this Oct 13, 2017
@Atinux
Copy link
Member

Atinux commented Oct 13, 2017

Hi @ndarilek, thank you for you PR

Actually, as @pi0 said, it's a really special use case, BTW, you can do this into your nuxt.config.js and it will work as well :)

@lock
Copy link

lock bot commented Nov 1, 2018

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked as resolved and limited conversation to collaborators Nov 1, 2018
@danielroe danielroe added the 2.x label Jan 18, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants