diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..0c1386a --- /dev/null +++ b/Dockerfile @@ -0,0 +1,30 @@ +# Dockerfile +# Jenkins LTS as of 2023-05-03 +FROM jenkinsci/jenkins:2.500.0 + +USER root + +# Update and install modules, show Linux Standard Base info +RUN apt-get update && apt-get install -y lsb-release + +# Setup access to docker hub +RUN curl -fsSLo /usr/share/keyrings/docker-archive-keyring.asc \ + https://download.docker.com/linux/debian/gpg +RUN echo "deb [arch=$(dpkg --print-architecture) \ + signed-by=/usr/share/keyrings/docker-archive-keyring.asc] \ + https://download.docker.com/linux/debian \ + $(lsb_release -cs) stable" > /etc/apt/sources.list.d/docker.list + +# Install the Docker community edition CLI +# Our docker run code specifies DOCKER_HOST so local Docker commands are executed on a remote Docker daemon +RUN apt-get update && apt-get install -y docker-ce-cli + +USER jenkins + +ENV JAVA_OPTS -Djenkins.install.runSetupWizard=false + +#COPY ./casc_configs /var/jenkins_home/casc_configs +#ENV CASC_JENKINS_CONFIG /var/jenkins_home/casc_configs + +COPY plugins.txt /usr/share/jenkins/ref/plugins.txt +RUN jenkins-plugin-cli --plugin-file /usr/share/jenkins/ref/plugins.txt \ No newline at end of file