Skip to content

Instantly share code, notes, and snippets.

@bluebrown
Created October 19, 2020 00:51
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bluebrown/3ca6b5fa619d2fb3b6c3c94c3d6eca49 to your computer and use it in GitHub Desktop.
Save bluebrown/3ca6b5fa619d2fb3b6c3c94c3d6eca49 to your computer and use it in GitHub Desktop.
Single-Node Jenkins & Blue Ocean - Docker Compose
version: "3.7"
services:
jenkins:
image: docker:dind
privileged: true
environment:
- DOCKER_TLS_CERTDIR="/certs"
volumes:
- data:/var/jenkins_home
- certs:/certs/client:ro
ocean:
image: jenkinsci/blueocean
ports:
- "8080:8080"
environment:
- DOCKER_HOST="tcp://docker:2376"
- DOCKER_CERT_PATH="/certs/client"
- DOCKER_TLS_VERIFY=1
volumes:
- data:/var/jenkins_home
- certs:/certs/client:ro
volumes:
data:
certs:
@bluebrown
Copy link
Author

Grep the Access-Token

docker exec jenkins_jenkins_1 cat /var/jenkins_home/secrets/initialAdminPassword

Remove Volumes

docker volume rm $(docker volume ls -q | grep jenkins)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment