# Dependencies: ssh, scp, sshpass, ~/.ssh/id_rsa.pub, properly
# configured sshd_config file in reach.
set -e
-set -x
# Location of an sshd_config with "PermitRootLogin no" and
# "PasswordAuthentication no".
# would require setting a password for user plom otherwise not needed.
sshpass -e scp ~/.ssh/id_rsa.pub root@"${server}":/tmp/authorized_keys
sshpass -e ssh root@"${server}" \
- 'useradd -m plom && '\
+ 'useradd -m plom -s /bin/bash && '\
'mkdir /home/plom/.ssh && '\
'chown plom:plom /home/plom/.ssh && '\
'chown plom:plom /tmp/authorized_keys && '\