Keys verteilen für SSH
Moin Moin
Ich will in meiner Linux Umgebung mit Bash die SSH Keys verteilen.
Leider muss ich immer noch das Passwort mitgeben.hat jemand eine Idee wie
ich das besser lösen könnte. Die Hosts werden von der Hostlists ausgelesen.
Vielen Dank für eure Hilfe.
Ich will in meiner Linux Umgebung mit Bash die SSH Keys verteilen.
Leider muss ich immer noch das Passwort mitgeben.hat jemand eine Idee wie
ich das besser lösen könnte. Die Hosts werden von der Hostlists ausgelesen.
Vielen Dank für eure Hilfe.
#! bin/bash
cat hostlist
for line in $(cat hostlist)
do
scp /home/admin/.ssh/ida_rsa.pub root@client:/root/.ssh/authorized_keys
done
Please also mark the comments that contributed to the solution of the article
Content-Key: 125589
Url: https://administrator.de/contentid/125589
Printed on: April 23, 2024 at 11:04 o'clock