blob: 42a0dee6cedadef3e5608d89da638541f4a6e424 [file] [log] [blame]
Michael Neale93ac93b2014-07-09 16:52:21 +10001FROM ubuntu:14.04
Michael Neale2627b962014-07-21 15:52:23 +10002
Michael Nealea5bfd412014-08-05 20:46:29 +10003RUN echo "1.574" > .lts-version-number
Michael Neale2627b962014-07-21 15:52:23 +10004
5RUN apt-get update && apt-get install -y wget git curl zip
6RUN apt-get update && apt-get install -y --no-install-recommends openjdk-7-jdk
7RUN apt-get update && apt-get install -y maven=3.0.5-1 ant=1.9.3-2build1 ruby rbenv make
8
Michael Neale3e124ed2014-07-18 15:12:27 +10009RUN wget -q -O - http://pkg.jenkins-ci.org/debian-stable/jenkins-ci.org.key | sudo apt-key add -
10RUN echo deb http://pkg.jenkins-ci.org/debian-stable binary/ >> /etc/apt/sources.list
Michael Nealeddcb7cc2014-07-14 12:01:49 +100011RUN apt-get update && apt-get install -y jenkins
Michael Neale640f91d2014-07-09 18:56:29 +100012RUN mkdir -p /var/jenkins_home && chown -R jenkins /var/jenkins_home
Michael Neale57de5eb2014-07-15 19:41:30 +100013ADD init.groovy /tmp/WEB-INF/init.groovy
Michael Neale2627b962014-07-21 15:52:23 +100014RUN cd /tmp && zip -g /usr/share/jenkins/jenkins.war WEB-INF/init.groovy
Michael Neale640f91d2014-07-09 18:56:29 +100015USER jenkins
16
Michael Neale3e124ed2014-07-18 15:12:27 +100017# VOLUME /var/jenkins_home - bind this in via -v if you want to make this persistent.
Michael Neale9be25dd2014-07-09 18:47:57 +100018ENV JENKINS_HOME /var/jenkins_home
Michael Neale3e124ed2014-07-18 15:12:27 +100019
20# for main web interface:
21EXPOSE 8080
22
23# will be used by attached slave agents:
24EXPOSE 50000
Michael Neale2627b962014-07-21 15:52:23 +100025
26CMD ["/usr/bin/java", "-jar", "/usr/share/jenkins/jenkins.war"]