From 755333a2e118896c885674567fe11bcf7db5504b Mon Sep 17 00:00:00 2001 From: Aly Raffauf Date: Fri, 3 May 2024 06:29:05 -0400 Subject: [PATCH] authorize same ssh keys for root as user aly --- nixosModules/user/aly/default.nix | 8 +------- nixosModules/user/default.nix | 7 +++++++ 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/nixosModules/user/aly/default.nix b/nixosModules/user/aly/default.nix index 31f1c021..2be767cd 100644 --- a/nixosModules/user/aly/default.nix +++ b/nixosModules/user/aly/default.nix @@ -19,13 +19,7 @@ description = "Aly Raffauf"; extraGroups = ["networkmanager" "wheel" "docker" "libvirtd" "video"]; hashedPassword = config.alyraffauf.user.aly.password; - openssh.authorizedKeys.keys = [ - "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOuRiyf9Fbl3Plqqzy5YkE2UJv8evF8YI9eG7Iu2CIRa aly@petalburg" - "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINHdpGTfjmnnau18CowChY4hPn/fzRkgJvXFs+yPy74I aly@mauville" - "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIEREYTfh+b8XKcfTLpENqRzzWQLSkXCZIKGUFTlmJPy6 aly@lavaridge" - "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOz2Lvy5WB/fCJnbK4eY2MY4CTYkKqQzUwRkXWiipHSc aly@rustboro" - "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIGcJBb7+ZxkDdk06A0csNsbgT9kARUN185M8k3Lq7E/d u0_a336@localhost" # termux on winona - ]; + openssh.authorizedKeys.keys = config.users.users.root.openssh.authorizedKeys.keys; }; }; } diff --git a/nixosModules/user/default.nix b/nixosModules/user/default.nix index d3f51e75..c4548daa 100644 --- a/nixosModules/user/default.nix +++ b/nixosModules/user/default.nix @@ -15,4 +15,11 @@ }; users.mutableUsers = false; + users.users.root.openssh.authorizedKeys.keys = [ + "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOuRiyf9Fbl3Plqqzy5YkE2UJv8evF8YI9eG7Iu2CIRa aly@petalburg" + "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINHdpGTfjmnnau18CowChY4hPn/fzRkgJvXFs+yPy74I aly@mauville" + "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIEREYTfh+b8XKcfTLpENqRzzWQLSkXCZIKGUFTlmJPy6 aly@lavaridge" + "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOz2Lvy5WB/fCJnbK4eY2MY4CTYkKqQzUwRkXWiipHSc aly@rustboro" + "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIGcJBb7+ZxkDdk06A0csNsbgT9kARUN185M8k3Lq7E/d u0_a336@localhost" # termux on winona + ]; }