From 2f258a319465383b0d5cf03898555a2e9e3a26b6 Mon Sep 17 00:00:00 2001 From: Stefan Reimer Date: Thu, 20 Aug 2020 17:38:18 +0100 Subject: [PATCH] Apply graceful shutdown fixes interim like Contour --- .../templates/istio-private-ingress.yaml | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/charts/kubezero-istio/templates/istio-private-ingress.yaml b/charts/kubezero-istio/templates/istio-private-ingress.yaml index f064c6b5..40b753e2 100644 --- a/charts/kubezero-istio/templates/istio-private-ingress.yaml +++ b/charts/kubezero-istio/templates/istio-private-ingress.yaml @@ -30,8 +30,9 @@ spec: name: istio-private-ingressgateway {{- end }} env: - - name: TERMINATION_DRAIN_DURATION_SECONDS - value: "60" + # https://github.com/istio/istio/issues/26524 + #- name: TERMINATION_DRAIN_DURATION_SECONDS + # value: "60" - name: ISTIO_META_HTTP10 value: '"1"' - name: ISTIO_META_ROUTER_MODE @@ -53,6 +54,16 @@ spec: rollingUpdate: maxSurge: 100% maxUnavailable: 25% + overlays: + - apiVersion: apps/v1 + kind: Deployment + name: istio-private-ingressgateway + patches: + - path: spec.template.spec.containers.[name:istio-proxy].lifecycle + value: {"preStop": {"exec": {"command": ["sh", "-c", "curl -X POST http://localhost:15000/healthcheck/fail && sleep 30"]}}} + - path: spec.template.spec.terminationGracePeriodSeconds + value: 90 + values: gateways: istio-ingressgateway: