mirror of
https://github.com/dani-garcia/vaultwarden.git
synced 2026-05-22 08:03:47 -05:00
[PR #1321] [MERGED] Improve shutdown behavior (on kubernetes and allow CTRL+C) #22472
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/dani-garcia/vaultwarden/pull/1321
Author: @mkilchhofer
Created: 1/22/2021
Status: ✅ Merged
Merged: 1/24/2021
Merged by: @dani-garcia
Base:
master← Head:feature/improve_shutdown_behavior📝 Commits (1)
1e31043Improve shutdown behavior (on kubernetes)📊 Changes
7 files changed (+16 additions, -15 deletions)
View changed files
📝
docker/Dockerfile.j2(+3 -7)📝
docker/amd64/Dockerfile(+2 -1)📝
docker/amd64/Dockerfile.alpine(+2 -1)📝
docker/arm64/Dockerfile(+2 -1)📝
docker/armv6/Dockerfile(+2 -1)📝
docker/armv7/Dockerfile(+2 -1)📝
docker/armv7/Dockerfile.alpine(+3 -3)📄 Description
Description of the change
@mfriedenhagen pointed at an init process in this issue here: https://github.com/dani-garcia/bitwarden_rs/issues/905#issuecomment-753454442
First I thought that this would not help, since Rocket does not explicitly handly any signal sent to it. But it seems that adding an init process like
dumb-initstill improves the shutdown behavior. According to the documentation of dumb-init this might be the reason why:Benefits
Especially running bitwarden inside kubernetes resulted, that evicting a node which runs bitwarden takes a long time becase we need to wait until kublet kills bitwarden hardly. With this improvement, the container terminates as fast as all other workload.
Possible drawbacks
No known drawbacks
Applicable issues
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.