Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature] Allow enabling Termination Notifications in AKS Node Pools #4797

Open
sdx-jkataja opened this issue Feb 14, 2025 · 0 comments
Open
Labels
feature-request Requested Features

Comments

@sdx-jkataja
Copy link

Is your feature request related to a problem? Please describe.
Termination notifications are not enabled for VM Scale Sets created from AKS Node Pools.
Also they cannot be enabled, since the parameters in VMSS are not exposed on AKS.
We do not receive an advance warning on when the node is about to be disrupted.

Quote:

Scheduled Events is an Azure Metadata Service that gives your application time to prepare for virtual machine (VM) maintenance

Screenshot from the Azure Portal will show this for any such node pool (on the Switzerland North region):

Image

Describe the solution you'd like
Please expose the VMSS Termination Notifications configuration in AKS Node Pool creation.
New nodes would then have the Scheduled Events enabled.

Currently in the CLI the az vmss update accepts the --enable-terminate-notification flag.
See: https://learn.microsoft.com/en-us/cli/azure/vmss?view=azure-cli-latest#az-vmss-update-optional-parameters
I ask that the az aks nodepool add command could also accept --enable-terminate-notification flag and pass it through to VMSS.
Having the flag available in IaC is more important to us, but using CLI since it is easier to explain.

Describe alternatives you've considered
Always enable Termination Notifications, similarly to what AWS EC2 implements. This would work for us but maybe not for everyone.

Azure Policy is unable to modify the parameter, see: Azure/azure-policy#1393

Azure documentation suggests to use the az vmss update command, see: https://learn.microsoft.com/en-us/azure/virtual-machine-scale-sets/virtual-machine-scale-sets-terminate-notification , however this is an additional step and also requires looking up the VMSS resource which AKS created.

Additional context
Possibly related:

@sdx-jkataja sdx-jkataja added the feature-request Requested Features label Feb 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature-request Requested Features
Projects
None yet
Development

No branches or pull requests

1 participant