构建rockylinux的Dockerfile

1
2
3
4
5
6
7
8
9
FROM rockylinux/rockylinux:latest
LABEL MAINTAINER="huage"
LABEL OS="1.0"
WORKDIR /root/
RUN yum install -y openssh-server net-tools passwd
RUN echo 123456|passwd --stdin root
CMD ["/usr/sbin/sshd", "-D"]
ENTRYPOINT ["/usr/sbin/init"]

构建命令

1
docker build -t rockylinux-ssh:latest ./