crypt/mount

This commit is contained in:
Marc Beninca 2023-12-28 12:44:00 +01:00
parent 2b1610bbe6
commit ac69623ed3

View file

@ -284,12 +284,17 @@ function hetzner-rescue-wipe-8-8-2 {
# open # open
echo "${passphrase}" \ echo "${passphrase}" \
| cryptsetup luksOpen '/dev/md/crypt' 'crypt' | cryptsetup luksOpen '/dev/md/crypt' 'crypt'
# format data # format crypt
mkfs.btrfs --force \ mkfs.btrfs --force \
--label 'crypt' \ --label 'crypt' \
--uuid '00000000-0000-0000-0000-00000000000c' \ --uuid '00000000-0000-0000-0000-00000000000c' \
--checksum 'sha256' \ --checksum 'sha256' \
'/dev/mapper/crypt' '/dev/mapper/crypt'
# mount crypt
mkdir --parents '/media/crypt'
mount \
--options 'autodefrag,compress=zstd' \
'/dev/mapper/crypt' '/media/crypt'
# format swap # format swap
mkswap \ mkswap \
--label 'swap' \ --label 'swap' \