An image base for linting and ci/cd of Jenkinsfiles and related Shared Libraries written in groovy.
Run these commands from the same folder as this readme. Tweak the Dockerfile to meet your needs.
docker build --pull --rm -f "Dockerfile" -t jankins .
# Start the container and run bash interactively
docker run --rm --entrypoint bash -it jankins
# Start container and run Jenkins exposed on host port 8001, with custom env vars set
docker run --rm -p '8081:8080' -it -e JENKINS_EXECUTORS=4 -e JENKINS_USER='admin2' -e JENKINS_PASSWD='welcome1' jankins
# Exposed as: http://0.0.0.0:8081
- The Jenkins env can be customized at runtime via the following Docker env vars. Sample values are shown below.
JENKINS_USER=jankins
JENKINS_PASSWD=jankins
JENKINS_EXECUTORS=1
- jankins logo derived from the Jenkins project artwork, supplied by @jvanceACX.
- Jake Wernette's awesome series on Jenkins Shared Libraries.
- Jenkins Official Docker hub.
- jankins-workspace, a containerized workspace for jankins using vscode's remote-container feature.