Last active
September 23, 2019 02:03
-
-
Save jdeathe/2048ed251dce639b5d13e8401a84ef7b to your computer and use it in GitHub Desktop.
Docker Compose definition to run a local Jenkins service in a Docker container.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ------------------------------------------------------------------------------ | |
# Ref: https://docs.docker.com/compose/compose-file/ | |
# | |
# Install docker for Mac: | |
# https://www.docker.com/products/docker | |
# | |
# docker-compose -p local_jenkins down | |
# docker-compose -p local_jenkins up -d | |
# docker-compose -p local_jenkins logs | |
# | |
# Use the password from the logs output to access the instance. | |
# http://localhost:49001/ | |
# ------------------------------------------------------------------------------ | |
version: "2" | |
volumes: | |
data-jenkins: | |
driver: "local" | |
services: | |
jenkins: | |
image: "jenkins:2.19.2" | |
ports: | |
- "49001:8080" | |
restart: "always" | |
volumes: | |
- "data-jenkins:/var/jenkins_home" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment