-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Graceful way to stop server.js through CLI/Docker? #557
Comments
Are you using webpack-dev-server 2.x or 1.x? It could be due to #357. If so, it will be fixed in the next 1.x version. |
we're currently at 1.14.1. thanks for the lightning response :) |
That doesn't seem to be the same issue, @SpaceK33z... I manually added the line from #357 and it didn't make a difference - docker still timeouts when stopping the container.. From looking into the docs,
|
Okay, could you try if manually applying #352 works for you (and using the new flag of course)? |
You got it now. |
Nice! There will be a 1.x release about not too long. |
Actually, I have no idea of what's going on. Even by commenting out the option, both patches, removing and recreating the container... The stop procedure is taking < 4s... |
I'm closing this issue because of inactivity. Feel free to comment, and we can always re-open it again. |
I'm having the same issue on 2.1.0-beta.10. I am also unable to I'm sure if I'm understanding what the Any advice? |
Having the same problem still, but I don't think it's a |
Just found this in the Docker documentation:
(source: https://docs.docker.com/engine/reference/run/#/foreground) I wonder if that could be the reason behind all this. (poke @SpaceK33z) |
Could be, I have no experience with Docker at all so can't help you with that. |
@SpaceK33z - I'm a Docker *nix guy. Has anyone actually gone in and done a |
@lucsky - You got a Dockerfile I can have a look at? |
I'm using webpack-dev-server 2.4.1 and I'm almost sure I have the same issue: We run all our apps and services via docker-compose. In development mode, we build the local project, create a container from it and run webpack-dev-server for live-reload. So then we can just When we then Ctrl+C the whole compose thing, every container shuts down but the process doesn't return (apparently due to webpack-dev-server still running).
|
I'm using webpack-dev-server under a Docker container, and it's default command is simply
node server.js
, which is sampled below. However, when I ask Docker to stop the container, it timeouts in 10s, meaning it's probably not being able to terminate the node process.What would be the best way to implement some sort of
npm stop
command to gracefully shutdown webpack-dev-server?server.js
The text was updated successfully, but these errors were encountered: