diff --git a/step1/10-disk b/step1/10-disk index 69e15a9..114f89c 100644 --- a/step1/10-disk +++ b/step1/10-disk @@ -159,4 +159,4 @@ setconf "add" "wipe" "${cfg[wipe]}" setconf "add" "diskname" "${disk[name]}" setconf "add" "bootsize" "4" setconf "add" "target_part" "2" -module end + diff --git a/step2/disk/bios b/step2/disk/bios index 5d5b021..06b5fc2 100644 --- a/step2/disk/bios +++ b/step2/disk/bios @@ -8,7 +8,6 @@ module start "disk" "Partition disk . BIOS" diskid="${cfg[diskid]//-/_}" if [[ -n "${cfg[wipe]}" ]]; then echo "Formatting disk" - echo fdisk -w always "${cfg[diskname]}" echo "o w q" | fdisk -w always "${cfg[diskname]}" > /dev/null @@ -24,7 +23,7 @@ p a w q" | fdisk "${cfg[diskname]}" > /dev/null -sleep 2 +sleep 3 if [[ "${cfg[rootfssize]}" == "rest" ]]; then target_partition_tmp="${cfg[diskname]}2" @@ -47,28 +46,28 @@ elif [[ ! "${cfg[rootfssize]}" == "rest" ]]; then w q" | fdisk "${cfg[diskname]}" > /dev/null fi -sleep 2 +sleep 3 target_partition="${target_partition_tmp}" if [[ ! "${cfg[fde_key_store]}" == "none" ]]; then echo -n "${cfg[diskpw]}" | cryptsetup luksFormat --type luks1 "${target_partition}" -d - - sleep 1 + sleep 2 echo -n "${cfg[diskpw]}" | cryptsetup luksOpen "${target_partition}" "voidluks-${diskid}" -d - - sleep 1 + sleep 2 #echo -n "oem" | cryptsetup luksFormat --type luks1 "${target_partition}" -d - #echo -n "oem" | cryptsetup luksOpen "${target_partition}" "voidluks-${diskid}" -d - target_partition="/dev/mapper/voidluks-${diskid}" fi -mkswap "${target_partition}" -sleep 1 +sleep 2 vgcreate -q -f "voidvg.${diskid}" "${target_partition}" || exit 1 -sleep 1 +sleep 2 lvcreate -q -y --name swap -L "${cfg[swapsize]}"G "voidvg.${diskid}" -sleep 1 +sleep 2 lvcreate -q -y --name root -l 100%FREE "voidvg.${diskid}" -sleep 1 +sleep 2 mkfs.btrfs -q -f "/dev/mapper/voidvg.${diskid}-root" + mkswap "/dev/mapper/voidvg.${diskid}-swap" mount "/dev/mapper/voidvg.${diskid}-root" "${dest}"