Skip to content

Commit

Permalink
Merge pull request #705 from TheYoctoJester/configurable_boot_partition
Browse files Browse the repository at this point in the history
feat: make boot partition mount point configurable
  • Loading branch information
TheYoctoJester authored Oct 24, 2024
2 parents ac1f1c8 + 204ed0d commit c88a0ef
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 3 deletions.
14 changes: 14 additions & 0 deletions configs/mender_convert_config
Original file line number Diff line number Diff line change
Expand Up @@ -230,6 +230,20 @@ MENDER_ENABLE_PARTUUID="n"
# Partition used as the boot partition.
MENDER_BOOT_PART=""

# Path to mount the boot partition in the root filesystem
#
# In order to access the boot partition from the running system,
# it needs to be mounted to a defined directory location.
# By default, this is
# - /boot/efi: for GRUB-EFI based integrations
# - /uboot: for all other integrations
#
# The value of this variable overrides all defaults.
# Example:
# MENDER_BOOT_PART_MOUNT_LOCATION="/boot/firmware"
#
#MENDER_BOOT_PART_MOUNT_LOCATION=""

# Partition used as the first (A) rootfs partition.
MENDER_ROOTFS_PART_A=""

Expand Down
10 changes: 7 additions & 3 deletions mender-convert-modify
Original file line number Diff line number Diff line change
Expand Up @@ -186,10 +186,14 @@ run_and_log_cmd "echo -n ${VERSION_STRING} | sudo tee work/rootfs/etc/mender/scr

log_info "Installing a custom /etc/fstab (see ${MENDER_CONVERT_LOG_FILE} for more info)"

if [ "${MENDER_GRUB_EFI_INTEGRATION}" == "y" ]; then
boot_part_mountpoint="/boot/efi"
if [ -n "${MENDER_BOOT_PART_MOUNT_LOCATION:-}" ]; then
boot_part_mountpoint="${MENDER_BOOT_PART_MOUNT_LOCATION}"
else
boot_part_mountpoint="/uboot"
if [ "${MENDER_GRUB_EFI_INTEGRATION}" == "y" ]; then
boot_part_mountpoint="/boot/efi"
else
boot_part_mountpoint="/uboot"
fi
fi

run_and_log_cmd "sudo mkdir -p work/rootfs/${boot_part_mountpoint}"
Expand Down

0 comments on commit c88a0ef

Please sign in to comment.