1
0

Add ssh public host keys

This commit is contained in:
2023-05-02 10:33:56 +02:00
parent 1cd9f1e52d
commit d068fea2ce
19 changed files with 26 additions and 0 deletions

8
bin/update-ssh-host-keys.sh Executable file
View File

@@ -0,0 +1,8 @@
#!/bin/bash
cd $(git rev-parse --show-toplevel)
for host in $(nix eval --apply 'attrs: builtins.concatStringsSep "\n" (builtins.filter (name: (builtins.substring 0 1 name) != "_") (builtins.attrNames attrs))' --raw .#clerie.hosts); do
echo $host
ssh-keyscan -t ed25519 ${host}.net.clerie.de 2>/dev/null | sed -E 's/(\S+) (.+)/\2/g' > hosts/${host}/ssh.pub
done