-
Notifications
You must be signed in to change notification settings - Fork 558
Add reserved pid settings migration #4650
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
base: develop
Are you sure you want to change the base?
Add reserved pid settings migration #4650
Conversation
Signed-off-by: Kush Upadhyay <[email protected]>
Signed-off-by: Kush Upadhyay <[email protected]>
df9c12c
to
cd1d10d
Compare
^ Force push fixes a clippy error |
|
||
// We added new kubernetes settings to reserve pids for kubernetes and system components. | ||
fn run() -> Result<()> { | ||
migrate(AddPrefixesMigration(vec![ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we add context (maybe to the comment) why we are using AddPrefixesMigration
vs the usual AddSettingsMigration
for a setting.
I know it was called out here:
bottlerocket-os/bottlerocket-settings-sdk#98 (review)
But I am curious on the behavior.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the callout! I reran migration testing using AddSettingsMigration
instead and it worked -- the results were the same.
Although AddPrefixesMigration
technically works, I believe AddSettingsMigration
is the correct helper here since the pid
setting is supposed to be set to a single value (so not a prefix for other settings). If pid
had it's own map, then AddPrefixesMigration
would be the right choice. I've fixed this in the latest push.
Signed-off-by: Kush Upadhyay <[email protected]>
cd1d10d
to
6e71b07
Compare
^ Force push replaces |
Issue number:
Related to: #3788
Description of changes:
Add migration for
pid
setting underkube-reserved
andsystem-reserved
settings:Testing done:
Migration testing:
Terms of contribution:
By submitting this pull request, I agree that this contribution is dual-licensed under the terms of both the Apache License, version 2.0, and the MIT license.