Compare commits
1 Commits
slurm-grou
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
| cf47139ebe |
@@ -134,7 +134,7 @@
|
||||
home = "/home/Computational/varcila";
|
||||
description = "Vincent Arcila";
|
||||
group = "Computational";
|
||||
hosts = [ "apex" "hut" "tent" "fox" ];
|
||||
hosts = [ "apex" "hut" "tent" "fox" "owl1" "owl2" ];
|
||||
hashedPassword = "$6$oB0Tcn99DcM4Ch$Vn1A0ulLTn/8B2oFPi9wWl/NOsJzaFAWjqekwcuC9sMC7cgxEVb.Nk5XSzQ2xzYcNe5MLtmzkVYnRS1CqP39Y0";
|
||||
openssh.authorizedKeys.keys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKGt0ESYxekBiHJQowmKpfdouw0hVm3N7tUMtAaeLejK vincent@varch"
|
||||
@@ -224,8 +224,6 @@
|
||||
|
||||
groups = {
|
||||
Computational = { gid = 564; };
|
||||
fox = { gid = 565; };
|
||||
owl = { gid = 566; };
|
||||
tracing = { };
|
||||
};
|
||||
};
|
||||
|
||||
@@ -17,13 +17,8 @@ with lib;
|
||||
allowedUser = host: userConf: builtins.elem host userConf.hosts;
|
||||
filterUsers = host: users: filterAttrs (n: v: allowedUser host v) users;
|
||||
removeHosts = users: mapAttrs (n: v: builtins.removeAttrs v [ "hosts" ]) users;
|
||||
addExtraGroups = mapAttrs (_: user: user // {
|
||||
extraGroups = (user.extraGroups or [ ])
|
||||
++ (lib.optionals (allowedUser "fox" user) [ "fox" ])
|
||||
++ (lib.optionals (allowedUser "owl1" user || allowedUser "owl2" user) [ "owl" ]);
|
||||
});
|
||||
currentHost = config.networking.hostName;
|
||||
in {
|
||||
users.users = removeHosts (addExtraGroups (filterUsers currentHost config.users.jungleUsers));
|
||||
users.users = removeHosts (filterUsers currentHost config.users.jungleUsers);
|
||||
};
|
||||
}
|
||||
|
||||
@@ -10,8 +10,8 @@
|
||||
];
|
||||
|
||||
partitionName = [
|
||||
"owl Nodes=owl[1-2] Default=YES DefaultTime=01:00:00 MaxTime=INFINITE State=UP AllowGroups=wheel,owl"
|
||||
"fox Nodes=fox Default=NO DefaultTime=01:00:00 MaxTime=INFINITE State=UP AllowGroups=wheel,fox"
|
||||
"owl Nodes=owl[1-2] Default=YES DefaultTime=01:00:00 MaxTime=INFINITE State=UP"
|
||||
"fox Nodes=fox Default=NO DefaultTime=01:00:00 MaxTime=INFINITE State=UP"
|
||||
];
|
||||
|
||||
# See slurm.conf(5) for more details about these options.
|
||||
|
||||
Reference in New Issue
Block a user