-
Notifications
You must be signed in to change notification settings - Fork 16
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(3062): fix Dockerfile not to use npm start
, and add shutdown method
#143
fix(3062): fix Dockerfile not to use npm start
, and add shutdown method
#143
Conversation
plugins/shutdown.js
Outdated
/** | ||
* Hapi plugin to handle serve graceful shutdown | ||
* @method register | ||
* @param {Hapi.Server} server |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[nits]
Is lint working? It looks like there are many space between {Hapi.Server} and server
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lint may not be working. I deleted the space.
Co-authored-by: Tiffany K <[email protected]>
🎉 This PR is included in version 5.0.9 🎉 The release is available on: Your semantic-release bot 📦🚀 |
Context
Store server cannot receive
SIGTERM
, and moreover the store even does not have the method of shutdown like api.See this issue for details:
screwdriver-cd/screwdriver#3062
Objective
node ./bin/server
directly, not vianpm start
References
Issue: screwdriver-cd/screwdriver#3062
Docker and Node.js Best Practices:
https://github.com/nodejs/docker-node/blob/main/docs/BestPractices.md#handling-kernel-signals
License
I confirm that this contribution is made under the terms of the license found in the root directory of this repository's source tree and that I have the authority necessary to make this contribution on behalf of its copyright owner.