You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This essentially executes a sleep 5 to allow a grace period before the container receives a SIGTERM and starts gracefully shutting down. This allows an ingress controller to update its list of Endpoints for routing requests without perceived "downtime".
While this has worked wonderfully for many years, its a hack that depends on the sleep binary to exist in the given container. With the rise of distroless-based images, we can no longer expect this to be the case.
Fortunately for us, KEP-3960: Introducing Sleep Action for PreStop Hook addresses this natively in Kubernetes. It is slated to be available as an alpha feature from 1.29, beta from 1.30, and GA from 1.32.
We should switch to using this feature whenever it is available.
The text was updated successfully, but these errors were encountered:
Since the dawn of time (for locally adjusted values of time), Naiserator has configured a default
preStopHook
for pods:naiserator/pkg/resourcecreator/pod/pod.go
Lines 462 to 470 in fb0a723
This essentially executes a
sleep 5
to allow a grace period before the container receives aSIGTERM
and starts gracefully shutting down. This allows an ingress controller to update its list ofEndpoints
for routing requests without perceived "downtime".While this has worked wonderfully for many years, its a hack that depends on the
sleep
binary to exist in the given container. With the rise of distroless-based images, we can no longer expect this to be the case.Fortunately for us, KEP-3960: Introducing Sleep Action for PreStop Hook addresses this natively in Kubernetes. It is slated to be available as an alpha feature from 1.29, beta from 1.30, and GA from 1.32.
We should switch to using this feature whenever it is available.
The text was updated successfully, but these errors were encountered: