fix: use individual admins
This commit is contained in:
parent
f9afc7285f
commit
98d5197056
3 changed files with 77 additions and 26 deletions
12
flake.nix
12
flake.nix
|
|
@ -153,13 +153,13 @@
|
|||
type = "app";
|
||||
program = "${pkgs.writeShellScript "bootstrap-host" (
|
||||
builtins.replaceStrings
|
||||
[ "@ADMIN_KEYS@" ]
|
||||
[
|
||||
(lib.concatMapStringsSep "\n" (key: " \"${key}\"") (
|
||||
lib.flatten (
|
||||
lib.mapAttrsToList (_: userCfg: userCfg.openssh.authorizedKeys.keys or [ ]) siteConfig.adminUsers
|
||||
)
|
||||
))
|
||||
"@ADMIN_USERS_JSON@"
|
||||
"@JQ@"
|
||||
]
|
||||
[
|
||||
(builtins.toJSON siteConfig.adminUsers)
|
||||
"${pkgs.jq}/bin/jq"
|
||||
]
|
||||
(builtins.readFile ./scripts/bootstrap-host.sh)
|
||||
)}";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue