diff options
Diffstat (limited to 'tools/init-sshkeys.sh')
-rwxr-xr-x | tools/init-sshkeys.sh | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/tools/init-sshkeys.sh b/tools/init-sshkeys.sh new file mode 100755 index 0000000..9427bad --- /dev/null +++ b/tools/init-sshkeys.sh @@ -0,0 +1,14 @@ +#!/bin/bash + +set -e + +source include/tgmanage.cfg.sh +if [ -z ${PRIMARY} ] +then + echo "Not configured!"; + exit 1; +fi; + +ssh-keygen -P '' -f ~/.ssh/id_rsa -b 2048 +ssh-copy-id root@${PRIMARY} +ssh-copy-id root@${SECONDARY} |