forked from mingfang/docker-ssh
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
20 lines (14 loc) · 721 Bytes
/
Dockerfile
File metadata and controls
20 lines (14 loc) · 721 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
FROM ubuntu:14.04
RUN apt-get update
#Runit
RUN DEBIAN_FRONTEND=noninteractive apt-get install -y runit
CMD /usr/sbin/runsvdir-start
#SSHD
RUN DEBIAN_FRONTEND=noninteractive apt-get install -y openssh-server && mkdir -p /var/run/sshd && \
echo 'root:root' |chpasswd
RUN sed -i "s/session.*required.*pam_loginuid.so/#session required pam_loginuid.so/" /etc/pam.d/sshd
RUN sed -i "s/PermitRootLogin without-password/#PermitRootLogin without-password/" /etc/ssh/sshd_config
#Utilities
RUN DEBIAN_FRONTEND=noninteractive apt-get install -y vim less net-tools inetutils-ping curl git telnet nmap socat dnsutils netcat tree htop unzip sudo software-properties-common
#Add runit services
ADD sv /etc/service