add build server user account
All checks were successful
Hydra nixosConfigurations.not522 Hydra build #22341 of nixos-config:pr618:nixosConfigurations.not522
All checks were successful
Hydra nixosConfigurations.not522 Hydra build #22341 of nixos-config:pr618:nixosConfigurations.not522
This commit is contained in:
parent
4d33b5dfde
commit
69dd93c11b
3 changed files with 21 additions and 0 deletions
|
@ -6,5 +6,6 @@
|
|||
./environment/impermanence.nix
|
||||
./secrets/sops.nix
|
||||
disko.nixosModules.default
|
||||
./hydra/build-server.nix
|
||||
];
|
||||
}
|
||||
|
|
1
modules/hydra/build-server-list.nix
Normal file
1
modules/hydra/build-server-list.nix
Normal file
|
@ -0,0 +1 @@
|
|||
["not522"]
|
19
modules/hydra/build-server.nix
Normal file
19
modules/hydra/build-server.nix
Normal file
|
@ -0,0 +1,19 @@
|
|||
{
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}:
|
||||
with lib; {
|
||||
options.hydra.buildServer.enable = mkEnableOption "Make this device a build server";
|
||||
config.hydra.buildServer.enable = let
|
||||
buildServers = import ./build-server-list.nix;
|
||||
in
|
||||
mkDefault (any (t: t == config.networking.hostName) buildServers);
|
||||
config.users.users.remote-build = mkIf config.hydra.buildServer.enable {
|
||||
description = "Remote builder";
|
||||
isNormalUser = true;
|
||||
openssh.authorizedKeys.keys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINN5Q/L2FyB3DIgdJRYnTGHW3naw5VQ9coOdwHYmv0aZ darkkirb@thinkrac"
|
||||
];
|
||||
};
|
||||
}
|
Loading…
Reference in a new issue