123456789101112131415161718192021222324252627282930313233343536 |
- ##################################################################
- FROM debian:8.0
- RUN apt-get update && apt-get install -yq parallel git vim tmux python-pip lockfile-progs expect telnet
- RUN pip install supervisor
- RUN mkdir -p /var/log/supervisor/
- EXPOSE 9001
- ##################################################################
- #sshd server
- RUN apt-get install -yq openssh-server
- RUN apt-get update && apt-get install -y openssh-server
- RUN mkdir /var/run/sshd
- #RUN echo 'root:screencast' | chpasswd
- #RUN sed -i 's/PermitRootLogin prohibit-password/PermitRootLogin yes/' /etc/ssh/sshd_config
- # SSH login fix. Otherwise user is kicked off after login
- RUN sed 's@session\s*required\s*pam_loginuid.so@session optional pam_loginuid.so@g' -i /etc/pam.d/sshd
- ENV NOTVISIBLE "in users profile"
- RUN echo "export VISIBLE=now" >> /etc/profile
- RUN mkdir /etc/ssh/keys/
- COPY keys/bitbucket.id_rsa.pub /etc/ssh/keys/authorized_keys
- RUN chmod 0700 /etc/ssh/keys
- RUN chmod 0600 /etc/ssh/keys/authorized_keys
- RUN chown root:root -R /etc/ssh/keys
- EXPOSE 22
- ##################################################################
- CMD bash -c "/usr/sbin/sshd ; while true; do supervisord --configuration /etc/supervisord/supervisor.conf --nodaemon ; sleep 5 ; done"
|