-
Notifications
You must be signed in to change notification settings - Fork 1k
Fixes #37857 - Tang support multiple phys. volumes #10334
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
Merged
sbernhard
merged 1 commit into
theforeman:develop
from
ATIX-AG:clevis-tang-multiple-disks
Nov 21, 2024
Merged
Fixes #37857 - Tang support multiple phys. volumes #10334
sbernhard
merged 1 commit into
theforeman:develop
from
ATIX-AG:clevis-tang-multiple-disks
Nov 21, 2024
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sbernhard
reviewed
Sep 23, 2024
app/views/unattended/provisioning_templates/snippet/disk_enc_clevis_tang.erb
Show resolved
Hide resolved
sbernhard
reviewed
Sep 23, 2024
app/views/unattended/provisioning_templates/snippet/disk_enc_clevis_tang.erb
Show resolved
Hide resolved
sbernhard
reviewed
Sep 23, 2024
app/views/unattended/provisioning_templates/snippet/disk_enc_clevis_tang.erb
Outdated
Show resolved
Hide resolved
jloeser
approved these changes
Sep 24, 2024
jloeser
left a comment
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.
Looks good to me.
app/views/unattended/provisioning_templates/snippet/disk_enc_clevis_tang.erb
Outdated
Show resolved
Hide resolved
Contributor
|
Can you please rebase this PR? |
712dd33 to
c80f28b
Compare
Contributor
Author
|
Sure, I just rebased onto foreman/develop with no conflicts. |
sbernhard
reviewed
Nov 5, 2024
app/views/unattended/provisioning_templates/snippet/disk_enc_clevis_tang.erb
Outdated
Show resolved
Hide resolved
Contributor
|
Bernhard asked me to take a look, too. I tested the script locally and took a look at the code. LGTM despite the indentation of the for loop Bernhard already mentioned. |
c80f28b to
eda914c
Compare
eda914c to
d35a06d
Compare
Often there is more than a single disk that gets encrypted during installation. When multiple disks are available and `autopart` is used in the kickstart config, all disks get encrypted and put into a volume group on which a logical volume for the root partition is created. Another example is when users add a separate disk for directories like /var to separate application data. This means we need to recursively resolve all underlying encrypted volumes, not just for the root partition. To identify these, we take all entries from /etc/crypttab, which should catch all block devices that were encrypted in the installation process. As this feature should also work for Ubuntu, we also address some bugs with the Ubuntu support: - disk_enc_clevis_tang.erb needs to work with dash (not just bash) - the check of the minor version in the autoinstall template is broken, recommendation is also to not rely on the minor version for this OS - PKG_MANAGER_INSTALL is missing in preseed_autoinstall_cloud_init.erb
d35a06d to
d6c08fe
Compare
sbernhard
approved these changes
Nov 21, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Link to the corresponding issue: https://projects.theforeman.org/issues/37857
This fixes some bugs that I found in the clevis/tang that was added via #9887
It should overall increase the usefulness of this feature for more realistic partitioning schemes,
and address some bugs that prevent this feature from working on Ubuntu.
Copy of the Commit Message Describing the Changes
Often there is more than a single disk that gets encrypted during installation. When multiple disks are available and
autopartis used in the kickstart config, all disks get encrypted and put into a volume group on which a logical volume for the root partition is created. Another example is when users add a separate disk for directories like /var to separate application data. This means we need to recursively resolve all underlying encrypted volumes, not just for the root partition. To identify these, we take all entries from /etc/crypttab, which should catch all block devices that were encrypted in the installation process.As this feature should also work for Ubuntu, we also address some bugs with the Ubuntu support: