bottlerocket-os / bottlerocket

An operating system designed for hosting containers
https://bottlerocket.dev
Other
8.81k stars 520 forks source link

Add a setting to delay updates on a Bottlerocket node #4273

Open cbgbt opened 3 weeks ago

cbgbt commented 3 weeks ago

What I'd like: Bottlerocket nodes currently decide for themselves when an update "becomes visible" to the host. This is controlled by a combination of the following factors:

It would be useful if we could add an additional setting to add an arbitrary delay to the update.

As an example, suppose we introduce a new setting:

apiclient set settings.updates.delay="48 hours"

Instead of using the settings.updates.seed value to make the update available exactly when that node's position becomes "ready" in the wave schedule, we would use the relevant wave's start time + the offset dictated by the new value.

We may be able to retrofit this setting into settings.updates.ignore-waves so that string values indicate the delay:

ignore-waves = "for 1 week"
ignore-waves = "for 3 days"

Any alternatives you've considered:

This is something that could also be implemented in the update agents (e.g. brupop). I'm not as inclined to prefer this, since it would only solve the problem for a subset of Bottlerocket users which use in-place updates.

cbgbt commented 3 weeks ago

After some further discussion, I think two unique settings may be less ambiguous:

The semantics would be as such: