-
Notifications
You must be signed in to change notification settings - Fork 7
Image Customizer: clean the /boot folder selectively if keepKdumpBootFiles is specified #296
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: main
Are you sure you want to change the base?
Conversation
2cc3608
to
641a0e6
Compare
7151c1b
to
8b3c5ff
Compare
@@ -32,6 +32,23 @@ pxe: | |||
|
|||
See also the [PXE Support](../../concepts/pxe.md) page. | |||
|
|||
## keepKdumpBootFiles [bool] |
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.
Use of this new API should sit behind a preview feature flag.
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.
! yes, I missed that
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.
pending
@@ -25,13 +26,16 @@ import ( | |||
) | |||
|
|||
const ( | |||
bootDirPermissions = 0700 |
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.
nit: 0o700
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.
pending
// without having to do an extra iteration. | ||
sort.Strings(bootFolderFilePaths) | ||
|
||
savedFilesDir, err := os.MkdirTemp("", "files-to-save-*") |
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.
Use the build directory for storing temporary files.
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.
pending
Clean the /boot folder selectively if keepKdumpBootFiles is specified.
If set to true, the Image Customizer tool will not delete any kdump files found under the boot folder on the full OS image. The kdump files include:
initramfs-<kernel-version>kdump.img
.vmlinuz-<kernel-version>
- where its version matches that of theinitramfs-<kernel-version>kdump.img
.The default is
false
.Note that by default, the Image Customizer tool removes the
/boot
folder from the full OS image. This is because all of its contents have already been copied unto the root of the PXE artifacts folder.