ssh fix
This commit is contained in:
@@ -10,9 +10,12 @@ in {
|
|||||||
|
|
||||||
services.openssh.enable = true;
|
services.openssh.enable = true;
|
||||||
services.openssh.ports = [ 422 ];
|
services.openssh.ports = [ 422 ];
|
||||||
|
services.openssh.extraConfig = activeUsers;
|
||||||
users.users = lib.mapAttrs (name: userList: {
|
users.users = lib.mapAttrs (name: userList: {
|
||||||
openssh.authorizedKeys.keys = lib.unique (map (u: u.pubssh) userList);
|
openssh.authorizedKeys.keys = lib.unique (
|
||||||
}) activeUsers
|
lib.concatMap (u: if u ? pubssh then [ u.pubssh ] else []) userList
|
||||||
|
);
|
||||||
|
}) groupedUsers
|
||||||
// {
|
// {
|
||||||
root = {openssh.authorizedKeys.keys = [];};
|
root = {openssh.authorizedKeys.keys = [];};
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user