Skip to content

Instantly share code, notes, and snippets.

@boiyama
Last active April 6, 2017 07:32
Show Gist options
  • Save boiyama/1858251438d5399e851b5fe934bc5253 to your computer and use it in GitHub Desktop.
Save boiyama/1858251438d5399e851b5fe934bc5253 to your computer and use it in GitHub Desktop.
docker-compose.yml configuring GitLab
version: '2'
services:
gitlab:
container_name: gitlab
image: gitlab/gitlab-ce:latest
restart: always
environment:
GITLAB_OMNIBUS_CONFIG: |
## GitLab configuration settings
##! Check out the latest version of this file to know about the different
##! settings that can be configured by this file, which may be found at:
##! https://gitlab.com/gitlab-org/omnibus-gitlab/raw/master/files/gitlab-config-template/gitlab.rb.template
## GitLab URL
##! URL on which GitLab will be reachable.
##! For more details on configuring external_url see:
##! https://docs.gitlab.com/omnibus/settings/configuration.html#configuring-the-external-url-for-gitlab
external_url 'http://gitlab.example.com'
################################################################################
## gitlab.yml configuration
##! Docs: https://gitlab.com/gitlab-org/omnibus-gitlab/blob/master/doc/settings/gitlab.yml.md
################################################################################
gitlab_rails['gitlab_ssh_host'] = 'ssh.gitlab.example.com'
gitlab_rails['time_zone'] = 'UTC'
volumes_from:
- gitlab-data
ports:
- "80:80"
- "2222:22"
gitlab-data:
container_name: gitlab-data
image: busybox
volumes:
- /etc/gitlab
- /var/log/gitlab
- /var/opt/gitlab
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment