From a2692492d73ae7758d8661fa2623f1c5b4b1d8ed Mon Sep 17 00:00:00 2001 From: Tim Hockin Date: Mon, 2 Mar 2020 10:28:48 -0800 Subject: [PATCH] Set a longer grace period for k8s.io nginx --- k8s.io/deployment.yaml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/k8s.io/deployment.yaml b/k8s.io/deployment.yaml index 554c8ebfbba..f31d4c9e704 100644 --- a/k8s.io/deployment.yaml +++ b/k8s.io/deployment.yaml @@ -19,7 +19,7 @@ spec: app: k8s-io version: v1 spec: - terminationGracePeriodSeconds: 5 + terminationGracePeriodSeconds: 30 volumes: - name: nginx configMap: @@ -55,6 +55,10 @@ spec: initialDelaySeconds: 3 timeoutSeconds: 2 failureThreshold: 2 + lifecycle: + preStop: + exec: # nginx likes to terminate ASAP + command: [ "/bin/sleep", "30" ] volumeMounts: - name: nginx mountPath: /etc/nginx