Merge snap-kubelet:gkk/configure-dont-restart into snap-kubelet:master
Status: | Merged |
---|---|
Approved by: | Kevin W Monroe |
Approved revision: | c25c56f83f1e2792315db870f4a9b24f31c35e8c |
Merged at revision: | c25c56f83f1e2792315db870f4a9b24f31c35e8c |
Proposed branch: | snap-kubelet:gkk/configure-dont-restart |
Merge into: | snap-kubelet:master |
Diff against target: |
11 lines (+0/-1) 1 file modified
snapcraft.yaml.in (+0/-1) |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Kevin W Monroe | Approve | ||
Review via email: mp+444585@code.launchpad.net |
Commit message
Don't restart kubelet(-eks) service during configure hook
This `snapctl restart` call was introduced in commit 6c89724 along with a number of other changes to fix LP:2012689. The restart call was added to align with behavior and examples from snapcraft documentation, but was not a core part of the fix.
As a consequence, every call to `snap set` now causes kubelet to start or restart, even if it was not running before. This created a new race condition in EKS images (LP:2023284) in which kubelet can start and register with Kubernetes before it is fully configured, leading user-specified options like --register-
To fix this, we can remove the `snapctl restart` call from the configure hook and revert to the old behavior where `snap start` or `snap restart` must be called explicitly after `snap set`. This should resolve the race condition for LP:2023284 while still preserving the most important parts of 6c89724.
yup, +1. the previous 4s restart delay and atomic args from lp:2012689 are maintained, while allowing for multiple 'snap sets' before start/restart.