# This Dockerfile is used to build an image containing basic stuff to be used as a Jenkins slave build node. FROM ubuntu:trusty MAINTAINER Jean-Baptiste Aubort # Make sure the package repository is up to date. RUN apt-get update RUN apt-get -y upgrade # Install need packages RUN apt-get update && apt-get -y install \ bash-completion \ build-essential \ gfortran \ cmake \ git \ subversion \ mercurial \ php5-cli \ php5-curl \ maven # Remove uneeded packages RUN apt-get -y purge libgl1-mesa-dri # Install a basic SSH server RUN apt-get update && apt-get -y install openssh-server RUN sed -i 's|session required pam_loginuid.so|session optional pam_loginuid.so|g' /etc/pam.d/sshd RUN mkdir -p /var/run/sshd # Install JDK 7 (latest edition) RUN apt-get update && apt-get -y install openjdk-7-jdk # Add user jenkins to the image RUN adduser --quiet jenkins RUN echo "jenkins:jenkins" | chpasswd # Jenkins RUN mkdir /home/jenkins/workspace RUN chown jenkins.jenkins /home/jenkins/workspace # Phabricator API RUN cd /opt; \ git clone https://github.com/phacility/arcanist.git; \ git clone https://github.com/phacility/libphutil.git; \ ln -s /opt/arcanist/bin/arc /usr/local/bin/arc # Clean RUN apt-get clean RUN rm -rf /var/lib/apt/lists/* # Standard SSH port EXPOSE 22 CMD ["/usr/sbin/sshd", "-D"]