itfreak
Goto Top

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.

#! bin/bash

cat hostlist
    for line in $(cat hostlist)
       do
             scp /home/admin/.ssh/ida_rsa.pub root@client:/root/.ssh/authorized_keys
done

Content-Key: 125589

Url: https://administrator.de/contentid/125589

Printed on: April 19, 2024 at 06:04 o'clock