diff --git a/modules/mcl-disko/default.nix b/modules/mcl-disko/default.nix index a71b5bb7..c4e3babc 100644 --- a/modules/mcl-disko/default.nix +++ b/modules/mcl-disko/default.nix @@ -29,20 +29,25 @@ description = "Declare the type of the primary partition"; }; - swap = { - size = mkOption { - type = types.nullOr types.str; - default = "32G"; - example = "32768M"; - description = "The size of the hard disk space used when RAM is full"; - }; + swap = mkOption { + type = types.submodule { + options = { + size = mkOption { + type = types.nullOr types.str; + default = "32G"; + example = "32768M"; + description = "The size of the hard disk space used when RAM is full"; + }; - randomEncryption = mkOption { - type = types.bool; - default = true; - example = false; - description = "Whether to use random encryption for swap partition"; + randomEncryption = mkOption { + type = types.bool; + default = true; + example = false; + description = "Whether to use random encryption for swap partition"; + }; + }; }; + default = { }; }; espSize = mkOption {