From 80ad250b681138fa15376cd05cefede16c2ae996 Mon Sep 17 00:00:00 2001 From: Steve Nay <265958+snay2@users.noreply.github.com> Date: Mon, 12 Sep 2022 17:31:58 -0500 Subject: [PATCH] Add back deprecated flags for checking whether an instance is managed by NTH We removed these flags in NTH release v1.17.0, but they are still supported for now. The Helm chart should support both in the mean time. --- .../aws-node-termination-handler/templates/deployment.yaml | 6 ++++++ config/helm/aws-node-termination-handler/values.yaml | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/config/helm/aws-node-termination-handler/templates/deployment.yaml b/config/helm/aws-node-termination-handler/templates/deployment.yaml index 548f00ab..241eddf1 100644 --- a/config/helm/aws-node-termination-handler/templates/deployment.yaml +++ b/config/helm/aws-node-termination-handler/templates/deployment.yaml @@ -82,8 +82,14 @@ spec: value: {{ .Values.enablePrometheusServer | quote }} - name: PROMETHEUS_SERVER_PORT value: {{ .Values.prometheusServerPort | quote }} + # [DEPRECATED] Use CHECK_TAG_BEFORE_DRAINING instead + - name: CHECK_ASG_TAG_BEFORE_DRAINING + value: {{ .Values.checkASGTagBeforeDraining | quote }} - name: CHECK_TAG_BEFORE_DRAINING value: {{ .Values.checkTagBeforeDraining | quote }} + # [DEPRECATED] Use MANAGED_TAG instead + - name: MANAGED_ASG_TAG + value: {{ .Values.managedAsgTag | quote }} - name: MANAGED_TAG value: {{ .Values.managedTag | quote }} - name: USE_PROVIDER_ID diff --git a/config/helm/aws-node-termination-handler/values.yaml b/config/helm/aws-node-termination-handler/values.yaml index 5e31b302..2fbdf2d3 100644 --- a/config/helm/aws-node-termination-handler/values.yaml +++ b/config/helm/aws-node-termination-handler/values.yaml @@ -173,9 +173,15 @@ queueURL: "" # The maximum amount of parallel event processors to handle concurrent events workers: 10 +# [DEPRECATED] Use checkTagBeforeDraining instead +checkASGTagBeforeDraining: true + # If true, check that the instance is tagged with "aws-node-termination-handler/managed" as the key before draining the node checkTagBeforeDraining: true +# [DEPRECATED] Use managedTag instead +managedAsgTag: "aws-node-termination-handler/managed" + # The tag to ensure is on a node if checkTagBeforeDraining is true managedTag: "aws-node-termination-handler/managed"