diff --git a/docker/ssh/Dockerfile b/docker/ssh/Dockerfile index a1d12f6..34023aa 100644 --- a/docker/ssh/Dockerfile +++ b/docker/ssh/Dockerfile @@ -1,7 +1,10 @@ FROM library/alpine RUN apk add --no-cache openssh && \ - sed -i /etc/ssh/sshd_config -e s/'#Port.*'/'Port 2222'/ -e s/'AllowTcpForwarding.*'/'AllowTcpForwarding yes'/ && \ - ssh-keygen -A + sed -i /etc/ssh/sshd_config \ + -e s/'#Port.*'/'Port 2222'/ \ + -e s/'AllowTcpForwarding.*'/'AllowTcpForwarding yes'/ \ + -e s/'GatewayPorts.*'/'GatewayPorts clientspecified'/ \ + && ssh-keygen -A RUN adduser -D -s /bin/ash beagle ADD beagle.key /home/beagle/.ssh/authorized_keys RUN passwd -u beagle && \