initial commit
This commit is contained in:
@@ -0,0 +1,27 @@
|
||||
{ config, lib, pkgs, ... }:
|
||||
|
||||
let
|
||||
me = config.network.nodes.${config.network.node};
|
||||
in
|
||||
{
|
||||
networking.firewall = {
|
||||
enable = true;
|
||||
interfaces.wg0.allowedTCPPorts = [ 22 ];
|
||||
};
|
||||
services.openssh = {
|
||||
enable = true;
|
||||
settings = {
|
||||
PermitRootLogin = "prohibit-password";
|
||||
PasswordAuthentication = false;
|
||||
KbdInteractiveAuthentication = false;
|
||||
};
|
||||
listenAddresses = [{
|
||||
addr = me.address-vpn;
|
||||
port = 22;
|
||||
}];
|
||||
};
|
||||
users.users.root.openssh.authorizedKeys.keys = [
|
||||
config.network.nodes.laptop.ssh
|
||||
config.network.nodes.desktop.ssh
|
||||
];
|
||||
}
|
||||
Reference in New Issue
Block a user