ssh-chat-docker/entrypoint.sh

10 lines
266 B
Bash
Raw Normal View History

2018-03-23 17:21:01 +00:00
#!/bin/bash
if [ -f ssh_key ]; then
2020-09-21 11:08:10 +00:00
/ssh-chat -i /ssh_key --admin=/admin_keys --motd=/motd $@
2018-03-23 17:21:01 +00:00
else
echo "SSH Key not found at /ssh_key. Generating..."
ssh-keygen -t rsa -b 4096 -f /ssh_key -q -N ''
2021-02-11 20:09:29 +00:00
/ssh-chat -i /ssh_key --admin="/admin_keys" --motd=/motd $@
2018-03-23 17:21:01 +00:00
fi