forked from fleetman-ci-cd-demo/jenkins
-
Notifications
You must be signed in to change notification settings - Fork 114
/
Dockerfile
30 lines (25 loc) · 1.36 KB
/
Dockerfile
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
from jenkins/jenkins:lts-alpine
USER root
# Pipeline
RUN /usr/local/bin/install-plugins.sh workflow-aggregator && \
/usr/local/bin/install-plugins.sh github && \
/usr/local/bin/install-plugins.sh ws-cleanup && \
/usr/local/bin/install-plugins.sh greenballs && \
/usr/local/bin/install-plugins.sh simple-theme-plugin && \
/usr/local/bin/install-plugins.sh kubernetes && \
/usr/local/bin/install-plugins.sh docker-workflow && \
/usr/local/bin/install-plugins.sh kubernetes-cli && \
/usr/local/bin/install-plugins.sh github-branch-source
# install Maven, Java, Docker, AWS
RUN apk add --no-cache maven \
openjdk8 \
docker \
gettext
# Kubectl
RUN wget https://storage.googleapis.com/kubernetes-release/release/$(curl -s https://storage.googleapis.com/kubernetes-release/release/stable.txt)/bin/linux/amd64/kubectl && chmod +x ./kubectl && mv ./kubectl /usr/local/bin/kubectl
# Need to ensure the gid here matches the gid on the host node. We ASSUME (hah!) this
# will be stable....keep an eye out for unable to connect to docker.sock in the builds
# RUN delgroup ping && delgroup docker && addgroup -g 999 docker && addgroup jenkins docker
# See https://github.com/kubernetes/minikube/issues/956.
# THIS IS FOR MINIKUBE TESTING ONLY - it is not production standard (we're running as root!)
RUN chown -R root "$JENKINS_HOME" /usr/share/jenkins/ref