ssh-cluster-config: fix sudo user
continuous-integration/laminar-eldarion Build failed with exit code 123 after 3 seconds Details

This commit is contained in:
Starbeamrainbowlabs 2022-08-06 21:51:16 +01:00
parent 7d54bdf5de
commit 994d954703
Signed by: sbrl
GPG Key ID: 1BE5172E637709C2
1 changed files with 1 additions and 0 deletions

View File

@ -3,6 +3,7 @@
task_begin "Configuring ssh";
while read -r username; do
username="$(basename "${username}")"; # find outputs the full path
sudo -u "${username}" bash -c 'ssh -T git@git.starbeamrainbowlabs.com || ssh-keyscan -H git.starbeamrainbowlabs.com >>$HOME/.ssh/known_hosts';
done < <(find /home -mindepth 1 -maxdepth 1 -type d);