diff --git a/types/default.nix b/types/default.nix index 96c7dfa..bdfb94f 100644 --- a/types/default.nix +++ b/types/default.nix @@ -55,12 +55,14 @@ rec { deviceNumbering = dev: index: if match "/dev/[vs]d.+" dev != null then dev + toString index # /dev/{s,v}da style - else if match "/dev/disk/.+" dev != null then - "${dev}-part${toString index}" # /dev/disk/by-id/xxx style + else if match "/dev/(disk|zvol)/.+" dev != null then + "${dev}-part${toString index}" # /dev/disk/by-id/xxx style, also used by zfs's zvolumes else if match "/dev/(nvme|md/|mmcblk).+" dev != null then "${dev}p${toString index}" # /dev/nvme0n1p1 style else - abort "${dev} seems not to be a supported disk format"; + abort '' + ${dev} seems not to be a supported disk format. Please add this to disko in https://github.com/nix-community/disko/blob/master/types/default.nix + ''; /* A nix option type representing a json datastructure, vendored from nixpkgs to avoid dependency on pkgs */ jsonType =