sshd/entrypoint.sh

12 lines
244 B
Bash
Raw Normal View History

2022-02-26 19:27:02 +01:00
#!/bin/bash
set -e;
echo $SSH_USER:$SSH_PASS
if [ -z `getent passwd $SSH_USER` ]; then useradd $SSH_USER -d /home/user; fi
echo "$SSH_USER:$SSH_PASS" | chpasswd
#echo "/bin/false" | tee -a /etc/shells
usermod $SSH_USER -s /bin/false
exec $@