feat: add error handling for ZFS pool creation in prepare-zfs-datasets script
Some checks failed
Nix Format Check / check-format (push) Failing after 37s

This commit is contained in:
Menno van Leeuwen 2025-03-12 11:31:35 +01:00
parent b03278ac86
commit cc2e48c96f
Signed by: vleeuwenmenno
SSH Key Fingerprint: SHA256:OJFmjANpakwD3F2Rsws4GLtbdz1TJ5tkQF0RZmF0TRE

View File

@ -27,6 +27,12 @@ fi
# Create ZFS pool # Create ZFS pool
sudo zpool create -f datapool "$device" sudo zpool create -f datapool "$device"
# Check if this went well
if [ $? -ne 0 ]; then
echo "Error creating ZFS pool. Exiting..."
exit 1
fi
# Create datasets with mountpoint=legacy # Create datasets with mountpoint=legacy
datasets=( datasets=(
isos isos