Files
dsk-iac/ansible/rsa_key/key.sh
havelight-ee e3a240bc41 bastion update
2023-06-28 15:48:32 +09:00

10 lines
185 B
Bash
Executable File

#!/usr/bin/expect -f
set password [lindex $argv 0]
set host [lindex $argv 1]
spawn ssh-copy-id -o StrictHostKeyChecking=no root@$host
expect "password:"
send "$password\n"
expect eof