From f6f2e009d62427e8f7b0d5db1e91b0051cf04284 Mon Sep 17 00:00:00 2001 From: lassulus Date: Thu, 21 Mar 2024 05:36:16 +0100 Subject: [PATCH] types zpool: create pool if device is a zfs_member --- lib/types/zpool.nix | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/types/zpool.nix b/lib/types/zpool.nix index 1253196..fd09e67 100644 --- a/lib/types/zpool.nix +++ b/lib/types/zpool.nix @@ -73,6 +73,9 @@ elif (blkid "$dev" -o export | grep '^PTUUID='); then echo "device $dev already has a partuuid, skipping creating zpool ${config.name}" >&2 continue=0 + elif (blkid "$dev" -o export | grep '^TYPE=zfs_member'); then + # zfs_member is a zfs partition, so we try to add the device to the pool + : elif (blkid "$dev" -o export | grep '^TYPE='); then echo "device $dev already has a partition, skipping creating zpool ${config.name}" >&2 continue=0