Commit debde0e6 authored by Vitaly Lipatov's avatar Vitaly Lipatov

add script add_to_rooter.sh

parent 35658749
#!/bin/sh
fatal()
{
echo "Error: $@" >&2
exit 1
}
USER=$1
SSHKEY=$(./get_ssh_pubkey.sh $1)
[ -n "$SSHKEY" ] || fatal
echo "no-port-forwarding,no-X11-forwarding,no-agent-forwarding $SSHKEY" >>/home/rooter/.ssh/authorized_keys
echo "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