diff --git a/authorized_keys b/authorized_keys new file mode 100644 index 0000000..73aa3cb --- /dev/null +++ b/authorized_keys @@ -0,0 +1 @@ +ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAILZKBTf7HdsZDJDwblnROAaGZDIWi/jWNwGjrih8UPuY kalle@kalle-laptop diff --git a/systems/base.nix b/systems/base.nix index b8b20ad..48d203e 100644 --- a/systems/base.nix +++ b/systems/base.nix @@ -33,6 +33,16 @@ "flakes" ]; + # Set up user for remote admin + users.users."maintenance" = { + isNormalUser = true; + group = "maintenance"; + extraGroups = [ "wheel" ]; + openssh.authorizedKeys.keyFiles = [ ../authorized_keys ]; + }; + + users.groups."maintenance" = {}; + # Enable mDNS for `hostname.local` addresses services.avahi.enable = true; services.avahi.nssmdns = true;