Make graceful restarting available in wider configurations by ktock · Pull Request #2077 · containerd/stargz-snapshotter (original) (raw)
Depends on #2076
Following up #1892
When stargz snapshotter receives SIGINT, it perform the graceful exit with explicitly unmounting the mountpoints and releasing the associated resources.
This PR makes this avilablable also in the following situations
- when FUSE manager is killed by SIGINT. The user can use SIGTERM and SIGINT for different porpose
- SIGTERM: Usable for restarting only containerd-stargz-grpc (e.g. for reloading configuration). No need to unmount snapshots because they are managed by the FUSE manager.
- SIGINT: Usable when the user wants to use the graceful exit feature of containerd-stargz-grpc because the user will kill the FUSE manager for node restart, etc.
- when containerd-stargz-grpc is killed by SIGTERM (systemd's default KillSignal)
This PR also adds docs about how to gracefully kill and restart Stargz Snapshotter under different configurations.