server: add sakotop key

This commit is contained in:
Sakooooo 2024-10-01 09:46:18 +04:00
parent 92bb854c9e
commit da6c28e055
Signed by: sako
GPG key ID: 3FD715D87D7725E0

View file

@ -1,17 +1,10 @@
{ { config, lib, ... }:
config, with lib;
lib, let cfg = config.modules.server;
...
}:
with lib; let
cfg = config.modules.server;
in { in {
imports = [ imports = [ ];
];
options.modules.server = { options.modules.server = { isServer = mkEnableOption false; };
isServer = mkEnableOption false;
};
config = mkIf cfg.isServer { config = mkIf cfg.isServer {
# we need this if you say otherwise ill throw you # we need this if you say otherwise ill throw you
@ -23,11 +16,13 @@ in {
PermitRootLogin = "no"; PermitRootLogin = "no";
# its so easy to use keys your grandmother could use it # its so easy to use keys your grandmother could use it
PasswordAuthentication = false; PasswordAuthentication = false;
ports = [ ports = [ 69 ];
69
];
openFirewall = true; openFirewall = true;
}; };
}; };
users.users.sako.openssh.authorizedKeys.keys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPGAwG2Fqs3xNF/6/9GdznH/jUIqxW3aTYvmteuq9odZ sako@sakotop"
];
}; };
} }