diff --git a/example/xfs-with-quota.nix b/example/xfs-with-quota.nix new file mode 100644 index 00000000..f4b0fabb --- /dev/null +++ b/example/xfs-with-quota.nix @@ -0,0 +1,34 @@ +{ + disko.devices = { + disk = { + main = { + device = "/dev/disk/by-id/some-disk-id"; + type = "disk"; + content = { + type = "gpt"; + partitions = { + ESP = { + type = "EF00"; + size = "500M"; + content = { + type = "filesystem"; + format = "vfat"; + mountpoint = "/boot"; + mountOptions = [ "umask=0077" ]; + }; + }; + root = { + size = "100%"; + content = { + type = "filesystem"; + format = "xfs"; + mountpoint = "/"; + mountOptions = [ "defaults" "pquota" ]; + }; + }; + }; + }; + }; + }; + }; +} diff --git a/tests/xfs.nix b/tests/xfs.nix new file mode 100644 index 00000000..3c7a123e --- /dev/null +++ b/tests/xfs.nix @@ -0,0 +1,13 @@ +{ pkgs ? import { } +, diskoLib ? pkgs.callPackage ../lib { } +}: +diskoLib.testLib.makeDiskoTest { + inherit pkgs; + name = "xfs"; + disko-config = ../example/xfs-with-quota.nix; + extraTestScript = '' + machine.succeed("mountpoint /"); + + machine.succeed("xfs_quota -c 'print' / | grep -q '(pquota)'") + ''; +}