V8.00.000.2025.06.17
All checks were successful
🛡️ Shell Script Linting / 🛡️ Shell Script Linting (push) Successful in 43s

Signed-off-by: Marc S. Weidner <msw@coresecret.dev>
This commit is contained in:
2025-07-26 22:30:11 +02:00
parent 35e7ea588f
commit 106ed253f4
5 changed files with 70 additions and 50 deletions

View File

@@ -59,8 +59,8 @@ partition_formatting() {
### Preparation of Ephemeral 'SWAP' and '/tmp' as per https://wiki.archlinux.org/title/Dm-crypt/Swap_encryption#UUID_and_LABEL
case "${var_mount_path,,}" in
swap|/tmp)
mkfs.ext4 -L "${var_fs_label}" "/dev/${var_dev}${var_part}" 1M
do_log "info" "file_only" "Partition: '/dev/${var_dev}${var_part}' ephemeral encryption prepared for: '${var_mount_path}'."
# mkfs.ext4 -L "${var_fs_label}" "/dev/${var_dev}${var_part}" 1M
do_log "info" "file_only" "3240() Partition: '/dev/${var_dev}${var_part}' ephemeral encryption already prepared in 3220(): '${var_mount_path}'."
continue
;;
esac
@@ -77,7 +77,7 @@ partition_formatting() {
ary_opts=( -L "${var_fs_label}" -f --csum "${var_fs_btrfs_checksum}" )
[[ "${var_fs_btrfs_dedup,,}" == "true" ]] && ary_opts+=( -m dup )
mkfs.btrfs "${ary_opts[@]}" "${var_node}"
do_log "info" "file_only" "Partition: '${var_node}' formatted: btrfs."
do_log "info" "file_only" "3240() Partition: '${var_node}' formatted: btrfs."
echo "Partition: '${var_node}':" >> "${DIR_LOG}/btrfs.log"
btrfs filesystem show "${var_node}" >> "${DIR_LOG}/btrfs.log"
var_fs_uuid=$(blkid -s UUID -o value "${var_node}")
@@ -87,7 +87,7 @@ partition_formatting() {
ext4)
read -r -a ary_fmt_opts <<< "${var_fs_options}"
mkfs.ext4 -L "${var_fs_label}" "${ary_fmt_opts[@]}" "${var_node}"
do_log "info" "file_only" "Partition: '${var_node}' formatted: ext4."
do_log "info" "file_only" "3240() Partition: '${var_node}' formatted: ext4."
echo "Partition: '${var_node}':" >> "${DIR_LOG}/ext4.log"
tune2fs -l "${var_node}" >> "${DIR_LOG}/ext4.log"
var_fs_uuid=$(blkid -s UUID -o value "${var_node}")
@@ -96,13 +96,13 @@ partition_formatting() {
fat32)
mkfs.fat -F 32 -n "${var_fs_label}" "${var_node}"
do_log "info" "file_only" "Partition: '${var_node}' formatted: FAT32."
do_log "info" "file_only" "3240() Partition: '${var_node}' formatted: FAT32."
var_fs_uuid=$(blkid -s UUID -o value "${var_node}")
HMP_PATH_FSUUID["UUID_${var_mount_path}"]="${var_fs_uuid}"
;;
*)
do_log "error" "file_only" "Unsupported filesystem format: '${var_fs_version}'."
do_log "error" "file_only" "3240() Unsupported filesystem format: '${var_fs_version}'."
;;
esac
@@ -110,6 +110,7 @@ partition_formatting() {
done
done
return 0
}
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh