Created
April 19, 2023 11:38
-
-
Save jacob-pro/254b4b6eba0a0386eb3fb36ad1f6aa6a to your computer and use it in GitHub Desktop.
Passwordless SSH Gateway Server in Container
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM oraclelinux:7 | |
RUN yum update && yum install -y openssh-server passwd && yum -y clean all | |
RUN echo "PermitEmptyPasswords yes" >> /etc/ssh/sshd_config | |
RUN echo "GatewayPorts yes" >> /etc/ssh/sshd_config | |
RUN /usr/bin/ssh-keygen -A | |
RUN passwd -d root | |
CMD ["/usr/sbin/sshd", "-D"] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment