diff --git a/hosters/hetzner-dedicated/zfs-uefi-nvme-nixos.sh b/hosters/hetzner-dedicated/zfs-uefi-nvme-nixos.sh index 6ef83a1..736dd8e 100644 --- a/hosters/hetzner-dedicated/zfs-uefi-nvme-nixos.sh +++ b/hosters/hetzner-dedicated/zfs-uefi-nvme-nixos.sh @@ -26,8 +26,6 @@ # * exports of env vars are added throughout the script in case you want to run it manually export LC_ALL=C -set -euox pipefail - # ORIGINAL WARNING: on 2023/07/16 the rescue system of hetzner boots with kernel 6.3.7 which # is by default not supported by the latest debian package. You need to update to debian # unstable to proceed with the zfs installation. @@ -35,12 +33,14 @@ set -euox pipefail # NEW WARNING: Upgrading to unstable is too much work, maybe just downloading zfs and building it is easier. apt update -apt install -y dpkg-dev linux-headers-$(uname -r) linux-image-amd64 sudo parted +apt install -y dpkg-dev linux-headers-$(uname -r) linux-image-amd64 sudo parted zfsutils-linux libssl-dev uuid-dev zlib1g-dev libblkid-dev +set -euox pipefail + +# TODO: This part is slow and not idempotent, so it needs to be commented out on +# subsequent runs cd "$(mktemp -d)" wget "$(curl -Ls https://api.github.com/repos/openzfs/zfs/releases/latest| grep -E "browser_download_url.*\.tar.gz\"$"| cut -d '"' -f 4)" -apt update -apt install libssl-dev uuid-dev zlib1g-dev libblkid-dev -y tar xfv zfs*.tar.gz && rm zfs*.tar.gz cd zfs* ./configure && make -j "$(nproc)"