Added further exit conditions
This commit is contained in:
parent
2ac4d7c95f
commit
0f8bfe2875
@ -243,9 +243,9 @@ install() {
|
|||||||
sfdisk --delete "${install_path}" >/dev/null
|
sfdisk --delete "${install_path}" >/dev/null
|
||||||
log "info" "Wiped partitions on $(important "${install_disk}")"
|
log "info" "Wiped partitions on $(important "${install_disk}")"
|
||||||
log "info" "Securely erasing remaining data on $(important "${install_disk}")"
|
log "info" "Securely erasing remaining data on $(important "${install_disk}")"
|
||||||
# echo YES | cryptsetup open --type plain -d /dev/urandom "${install_path}" to_be_wiped > /dev/null
|
# echo YES | cryptsetup open --type plain -d /dev/urandom "${install_path}" to_be_wiped > /dev/null || exit
|
||||||
# dd bs=1M if=/dev/zero of=/dev/mapper/to_be_wiped status=progress 2> /dev/null
|
# dd bs=1M if=/dev/zero of=/dev/mapper/to_be_wiped status=progress 2> /dev/null || exit
|
||||||
# cryptsetup close to_be_wiped
|
# cryptsetup close to_be_wiped || exit
|
||||||
log "info" "Writing new partitions to $(important "${install_disk}")"
|
log "info" "Writing new partitions to $(important "${install_disk}")"
|
||||||
(echo n
|
(echo n
|
||||||
echo
|
echo
|
||||||
@ -270,7 +270,7 @@ install() {
|
|||||||
|
|
||||||
mount /dev/mapper/cryptroot /mnt
|
mount /dev/mapper/cryptroot /mnt
|
||||||
mkdir /mnt/boot
|
mkdir /mnt/boot
|
||||||
mount "${install_path}" /mnt/boot/
|
mount "${install_path}" /mnt/boot
|
||||||
local mem_amount
|
local mem_amount
|
||||||
mem_amount="$(grep MemTotal /proc/meminfo | tr -s " " | cut -d " " -f2)"
|
mem_amount="$(grep MemTotal /proc/meminfo | tr -s " " | cut -d " " -f2)"
|
||||||
mem_amount=$(( mem_amount * 3/2 / 1000 ))
|
mem_amount=$(( mem_amount * 3/2 / 1000 ))
|
||||||
|
Loading…
Reference in New Issue
Block a user