forked from gocd/gocd-docker
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile.gocd-dev
30 lines (23 loc) · 1.34 KB
/
Dockerfile.gocd-dev
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
# Build using: docker build -f Dockerfile.gocd-dev -t gocd-dev .
FROM phusion/baseimage:0.9.16
MAINTAINER Aravind SV <arvind.sv@gmail.com>
RUN rm -rf /etc/service/sshd /etc/my_init.d/00_regen_ssh_host_keys.sh
RUN apt-get update && apt-get install -y -q unzip openjdk-7-jre-headless git
# Due to a bug, it looks like you cannot create a pipeline if you're physically located west of the server. Hmm. :(
RUN echo Pacific/Samoa > /etc/timezone && dpkg-reconfigure --frontend noninteractive tzdata
RUN mkdir /etc/service/go-server
ADD gocd-dev/go-common-scripts.sh /etc/service/go-server/go-common-scripts.sh
ADD gocd-dev/go-server-start.sh /etc/service/go-server/run
RUN mkdir /etc/service/go-agent
ADD gocd-dev/go-common-scripts.sh /etc/service/go-agent/go-common-scripts.sh
ADD gocd-dev/go-agent-start.sh /etc/service/go-agent/run
ADD http://download.go.cd/gocd-deb/go-server-15.2.0-2248.deb /tmp/go-server.deb
ADD http://download.go.cd/gocd-deb/go-agent-15.2.0-2248.deb /tmp/go-agent.deb
WORKDIR /tmp
RUN dpkg -i /tmp/go-server.deb
RUN dpkg -i /tmp/go-agent.deb
RUN sed -i -e 's/DAEMON=Y/DAEMON=N/' /etc/default/go-server /etc/default/go-agent
RUN echo 'export GO_SERVER_SYSTEM_PROPERTIES="-DpluginLocationMonitor.sleepTimeInSecs=1"' >>/etc/default/go-server
EXPOSE 8153 8154
RUN apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
CMD ["/sbin/my_init"]