Skip to content

Instantly share code, notes, and snippets.

@sidpalas
Created June 5, 2020 04:29
Show Gist options
  • Save sidpalas/25b0cbe5cbb89ca2abf59f698fc4a3be to your computer and use it in GitHub Desktop.
Save sidpalas/25b0cbe5cbb89ca2abf59f698fc4a3be to your computer and use it in GitHub Desktop.
Docker compose file for setting up Jenkins + dind
version: '3'
services:
dind:
image: "docker:dind"
volumes:
- jenkins-docker-certs:/certs/client
- jenkins-data:/var/jenkins_home
networks:
jenkins:
aliases:
- docker
ports:
- "2376:2376"
environment:
DOCKER_TLS_CERTDIR: "/certs"
privileged: true
jenkins:
image: "jenkinsci/blueocean"
volumes:
- jenkins-data:/var/jenkins_home
- jenkins-docker-certs:/certs/client:ro
ports:
- "8080:8080"
- "50000:50000"
environment:
DOCKER_HOST: "tcp://docker:2376"
DOCKER_CERT_PATH: "/certs/client"
DOCKER_TLS_VERIFY: 1
volumes:
jenkins-docker-certs:
jenkins-data:
networks:
jenkins:
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment