Browse Source

sshd_config tunning

master
parent
commit
547509a8d8
  1. 6
      Dockerfile

6
Dockerfile

@ -10,7 +10,11 @@ RUN apt-get update \ @@ -10,7 +10,11 @@ RUN apt-get update \
&& useradd --non-unique --uid $USERID --gid $GROUPID --no-create-home --home-dir $DATADIR $OWNER \
&& mkdir -p "$DATADIR" \
&& chown $OWNER "$DATADIR" \
&& echo "AuthorizedKeysFile $AUTHORIZED_KEYS_FILE" >>/etc/ssh/sshd_config \
&& echo "AuthorizedKeysFile $AUTHORIZED_KEYS_FILE" >> /etc/ssh/sshd_config \
&& echo "X11Forwarding no" >> /etc/ssh/sshd_config \
&& echo "AllowTcpForwarding no" >> /etc/ssh/sshd_config \
&& echo "ChrootDirectory %h" >> /etc/ssh/sshd_config \
&& echo "ForceCommad internal-sftp" >> /etc/ssh/sshd_config \
&& touch $AUTHORIZED_KEYS_FILE \
&& chown $OWNER $AUTHORIZED_KEYS_FILE \
&& chmod 0600 $AUTHORIZED_KEYS_FILE \

Loading…
Cancel
Save