-
Notifications
You must be signed in to change notification settings - Fork 275
Description
Problem
Release v1.17.0
(chart version v0.19.0
) deprecated two flags: CHECK_ASG_TAG_BEFORE_DRAINING
and MANAGED_ASG_TAG
, replacing them with CHECK_TAG_BEFORE_DRAINING
and MANAGED_TAG
. This change reflects the fact that we no longer call any ASG APIs when checking tags on an EC2 instance to determine whether NTH should manage it.
Our release notes stated
Release
v1.17.0
supports both configs, but you'll see a warning if you use the deprecated name.
These two values are indeed still supported if invoked via CLI flags. However, they are not supported if invoked via the helm chart.
Solution
We need to add CHECK_ASG_TAG_BEFORE_DRAINING
and MANAGED_ASG_TAG
back to deployment.yaml and add checkASGTagBeforeDraining
and managedAsgTag
back to values.yaml, with appropriate comments to designate them as deprecated. If possible, we should also issue warnings, similar to how the CLI flags work, so that consumers are aware of the deprecation and can take steps to migrate before we eventually remove the deprecated flags in a future release.
Background
As discussed in #679:
Originally posted by jgournet August 25, 2022
Hi,
Just wanted to bring a pain point we just experienced:
Release 1.17.0 introduced this call out:
Deprecate two config values. Release v1.17.0 supports both configs, but you'll see a warning if you use the deprecated name. We may remove the deprecated configs altogether in a future release.
Deprecate CheckASGTagBeforeDraining and replace it with CheckTagBeforeDraining
Great :) that's the right way to deprecate flags
But the helm chart changed to:
https://github.com/aws/aws-node-termination-handler/blob/main/config/helm/aws-node-termination-handler/values.yaml
# If true, check that the instance is tagged with "aws-node-termination-handler/managed" as the key before draining the node
checkTagBeforeDraining: true
=> node termination handler silently suddenly stopped working for us after upgrading. Lucky us for randomly catching it :)
So just mentioning it, in case someone can come up with a solution to slowly deprecate helm values too