Skip to content

Instantly share code, notes, and snippets.

@ljdelight
Created April 24, 2017 02:56
Show Gist options
  • Save ljdelight/d41962d9e7de2059ecf9929758b9b8ef to your computer and use it in GitHub Desktop.
Save ljdelight/d41962d9e7de2059ecf9929758b9b8ef to your computer and use it in GitHub Desktop.
docker-compose for gitlab and jenkins
#
# Simple docker-compose file for Gitlab CE and a Jenkins master.
# This is for testing and builds are done on the jenkins master.
#
version: "2"
services:
gitlab:
image: "gitlab/gitlab-ce:8.15.2-ce.0"
container_name: "gitlab"
restart: "always"
hostname: "gitlab"
ports:
- "8081:80"
volumes:
- "/opt/automation/gitlab/config:/etc/gitlab"
- "/opt/automation/gitlab/logs:/var/log/gitlab"
- "/opt/automation/gitlab/data:/var/opt/gitlab"
environment:
GITLAB_OMNIBUS_CONFIG: |
external_url "http://gitlab"
jenkins-master:
image: "jenkins:2.19.4"
container_name: "jenkins-master"
restart: "always"
ports:
- "8080:8080"
- "50000:50000"
volumes:
- "/opt/automation/jenkins-master:/var/jenkins_home"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment