Skip to content
This repository has been archived by the owner on Oct 24, 2023. It is now read-only.

feat: configurable unattended-upgrades #4614

Merged

Conversation

jackfrancis
Copy link
Member

@jackfrancis jackfrancis commented Aug 11, 2021

Reason for Change:

This PR introduces a boolean "enableUnattendedUpgrades" configuration property to the LinuxProfile api model configuration object. By default, we set it to true, preserving the existing behavior.

We also log a warning if the user does not explicitly set this configuration, nudging her or him to do so next time.

If the "enableUnattendedUpgrades" is set to false, then don't enable unattended-upgrades to run regularly in the background.

Issue Fixed:

Related to #4595

Credit Where Due:

Does this change contain code from or inspired by another project?

  • No
  • Yes

If "Yes," did you notify that project's maintainers and provide attribution?

  • No
  • Yes

Requirements:

Notes:

@@ -650,6 +650,9 @@ func (a *Properties) validateLinuxProfile() error {
return errors.New("KeyData in LinuxProfile.SSH.PublicKeys cannot be empty string")
}
}
if a.LinuxProfile.EnableUnattendedUpgrades == nil {
log.Warnf("linuxProfile.enableUnattendedUpgrades configuration was not declared, your cluster nodes will be configured to run unattended-upgrade by default")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would make the warning message scarier and add something about the impact, ie. this can lead to downtime if a bad patch is applied to all your nodes at once.

Copy link
Member

@devigned devigned left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

Copy link
Member

@mboersma mboersma left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@jackfrancis jackfrancis merged commit 1704afb into Azure:master Sep 24, 2021
@jackfrancis jackfrancis deleted the configurable-unattended-upgrades branch September 24, 2021 22:19
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants