Skip to content
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

ext: fs-cryptroot-support: don't abuse add_host_dependencies #6785

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions extensions/fs-cryptroot-support.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,20 +5,20 @@
function add_host_dependencies__add_cryptroot_tooling() {
display_alert "Adding cryptroot to host dependencies" "cryptsetup LUKS" "debug"
EXTRA_BUILD_DEPS="${EXTRA_BUILD_DEPS} cryptsetup openssh-client" # @TODO: convert to array later

display_alert "Adding rootfs encryption related packages" "cryptsetup cryptsetup-initramfs" "info"
add_packages_to_rootfs cryptsetup cryptsetup-initramfs

if [[ $CRYPTROOT_SSH_UNLOCK == yes ]]; then
display_alert "Adding rootfs encryption related packages" "dropbear-initramfs" "info"
add_packages_to_rootfs dropbear-initramfs
fi
}

function extension_prepare_config__prepare_cryptroot() {
display_alert "Adding rootfs encryption related packages" "cryptsetup cryptsetup-initramfs" "info"
add_packages_to_image cryptsetup cryptsetup-initramfs

# Config for cryptroot, a boot partition is required.
declare -g BOOTPART_REQUIRED=yes
EXTRA_IMAGE_SUFFIXES+=("-crypt")

if [[ $CRYPTROOT_SSH_UNLOCK == yes ]]; then
display_alert "Adding rootfs encryption related packages" "dropbear-initramfs" "info"
add_packages_to_image dropbear-initramfs
fi
}

function prepare_root_device__encrypt_root_device() {
Expand Down