Commit 83ec81f0 authored by Nico Schottelius's avatar Nico Schottelius

add script to add key to server

parent ee7ca287
#!/bin/sh
if [ $# -lt 2 ]; then
echo "$0 server keyname [keyname...]"
exit 1
fi
server=$1; shift
for keyname in "$@"; do
url=https://key.wf/${keyname}
ssh root@$server "curl -Ls $url >> ~/.ssh/authorized_keys" < /dev/null
done
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment