diff options
author | Markus Kowalewski <markus.kowalewski@gmail.com> | 2018-10-25 20:34:17 +0200 |
---|---|---|
committer | Markus Kowalewski <markus.kowalewski@gmail.com> | 2018-10-30 19:50:52 +0100 |
commit | d2799d1835fdfc68e2b621beff1fa951f055ae39 (patch) | |
tree | 25b85978cef531e9538bdadc7c53f0a15acb294d /nixos/modules | |
parent | f51f7534163ec0159c195657dddd5c10443c54a4 (diff) | |
download | nixlib-d2799d1835fdfc68e2b621beff1fa951f055ae39.tar nixlib-d2799d1835fdfc68e2b621beff1fa951f055ae39.tar.gz nixlib-d2799d1835fdfc68e2b621beff1fa951f055ae39.tar.bz2 nixlib-d2799d1835fdfc68e2b621beff1fa951f055ae39.tar.lz nixlib-d2799d1835fdfc68e2b621beff1fa951f055ae39.tar.xz nixlib-d2799d1835fdfc68e2b621beff1fa951f055ae39.tar.zst nixlib-d2799d1835fdfc68e2b621beff1fa951f055ae39.zip |
nixos/slurm: node/partitionName option -> list
Make the node and partitionname options lists. There can be more than paratition or set of nodes. Add changes to release notes
Diffstat (limited to 'nixos/modules')
-rw-r--r-- | nixos/modules/services/computing/slurm/slurm.nix | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/nixos/modules/services/computing/slurm/slurm.nix b/nixos/modules/services/computing/slurm/slurm.nix index d9a201dc7ed8..a3f2367dba40 100644 --- a/nixos/modules/services/computing/slurm/slurm.nix +++ b/nixos/modules/services/computing/slurm/slurm.nix @@ -16,8 +16,8 @@ let SlurmUser=${cfg.user} ${optionalString (cfg.controlMachine != null) ''controlMachine=${cfg.controlMachine}''} ${optionalString (cfg.controlAddr != null) ''controlAddr=${cfg.controlAddr}''} - ${optionalString (cfg.nodeName != null) ''nodeName=${cfg.nodeName}''} - ${optionalString (cfg.partitionName != null) ''partitionName=${cfg.partitionName}''} + ${toString (map (x: "NodeName=${x}\n") cfg.nodeName)} + ${toString (map (x: "PartitionName=${x}\n") cfg.partitionName)} PlugStackConfig=${plugStackConfig} ProctrackType=${cfg.procTrackType} ${cfg.extraConfig} @@ -149,9 +149,9 @@ in }; nodeName = mkOption { - type = types.nullOr types.str; - default = null; - example = "linux[1-32] CPUs=1 State=UNKNOWN"; + type = types.listOf types.str; + default = []; + example = literalExample ''[ "linux[1-32] CPUs=1 State=UNKNOWN" ];''; description = '' Name that SLURM uses to refer to a node (or base partition for BlueGene systems). Typically this would be the string that "/bin/hostname -s" @@ -160,9 +160,9 @@ in }; partitionName = mkOption { - type = types.nullOr types.str; - default = null; - example = "debug Nodes=linux[1-32] Default=YES MaxTime=INFINITE State=UP"; + type = types.listOf types.str; + default = []; + example = literalExample ''[ "debug Nodes=linux[1-32] Default=YES MaxTime=INFINITE State=UP" ];''; description = '' Name by which the partition may be referenced. Note that now you have to write the partition's parameters after the name. |