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
{{ message }}
Repository navigation
Commit 8bcb709
Browse filesBrowse the repository at this point in the historyBrowse files
fix(fluxcd): refuse a flux-plunger drain deadline that leaves no time
A drain deadline of zero or less is already spent when the drain
starts, so flux-plunger would exit holding every uninstall fence
without listing one. The chart could produce one: its 40-second floor
was a literal, so raising the manager's stop bound or the margin before
SIGKILL, which the drain subtraction is already tied to, would leave the
floor rendering a non-positive deadline. The binary now refuses such a
flag at startup, before it reaches for a cluster, and the chart's floor
and the timings the README and the values comment state are held to
the same constants.
A whole number of a million seconds or more printed in exponent form
and was refused as a fraction; the range is now checked first, so it
gets the range message.
Assisted-by: LLM
Signed-off-by: Alexey Artamonov <[email protected]>
Copy file name to clipboardExpand all lines: packages/system/flux-plunger/templates/deployment.yaml
+3-3Lines changed: 3 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -22,12 +22,12 @@ spec:
22
22
rejected on upgrade.
23
23
*/}}
24
24
{{- $grace := int .Values.shutdownGracePeriodSeconds }}
25
-
{{- if ne (toString .Values.shutdownGracePeriodSeconds) (toString $grace) }}
26
-
{{- fail "shutdownGracePeriodSeconds must be a whole number of seconds: terminationGracePeriodSeconds takes an integer" }}
27
-
{{- end }}
28
25
{{- if or (lt $grace 40) (gt $grace 140) }}
29
26
{{- fail "shutdownGracePeriodSeconds must be between 40 and 140: below, the drain gets no time after the manager's 10s stop; above, the pre-delete hook cannot wait the pod out inside its deadline" }}
30
27
{{- end }}
28
+
{{- if ne (toString .Values.shutdownGracePeriodSeconds) (toString $grace) }}
29
+
{{- fail "shutdownGracePeriodSeconds must be a whole number of seconds: terminationGracePeriodSeconds takes an integer" }}
0 commit comments