Skip to content

Commit

Permalink
Fix ssh login (#825)
Browse files Browse the repository at this point in the history
  • Loading branch information
xu-song authored Mar 26, 2023
1 parent 5c5fb94 commit ee9a143
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 35,7 @@ ENV PASSWORD=password
RUN mkdir /var/run/sshd && \
echo "root:${PASSWORD}" | chpasswd && \
# Allow root login with password
sed -i 's/PermitRootLogin without-password/PermitRootLogin yes/' /etc/ssh/sshd_config && \
sed -i 's/#PermitRootLogin prohibit-password/PermitRootLogin yes/' /etc/ssh/sshd_config && \
# Prevent user being kicked off after login
sed -i 's@session\s*required\s*pam_loginuid.so@session optional pam_loginuid.so@g' /etc/pam.d/sshd && \
echo 'AuthorizedKeysFile .ssh/authorized_keys' >> /etc/ssh/sshd_config && \
Expand Down

0 comments on commit ee9a143

Please sign in to comment.