Created
October 11, 2017 12:23
-
-
Save estan/0811723dff8118e6f10efe57c4aa96ec to your computer and use it in GitHub Desktop.
This file contains hidden or 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
gitlab: | |
image: 'gitlab/gitlab-ce:10.0.3-ce.0' | |
container_name: 'gitlab' | |
restart: always | |
hostname: 'git.ourdomain.com' | |
environment: | |
GITLAB_OMNIBUS_CONFIG: | | |
external_url 'https://git.ourdomain.com' | |
gitlab_rails['smtp_enable'] = true | |
gitlab_rails['smtp_address'] = "192.168.1.15" | |
gitlab_rails['smtp_port'] = 25 | |
# We only keep 30 days worth of backups | |
gitlab_rails['backup_keep_time'] = 2592000 | |
# World-readable backup archives (we use a pull paradigm for offsite backup). | |
# | |
# Using setfacl to set a default ACL giving access to the remote backup | |
# user won't work, because GitLab will `chmod` the files to be readable | |
# only by `git`, which affects the effective ACLs since there's a | |
# correspondence between traditional UNIX perms and ACLs (see acl(5)). | |
gitlab_rails['backup_archive_permissions'] = 0644 | |
# Don't manage the backup directory, we need it to be accessible for | |
# offsite backups, so we manage it ourself. | |
gitlab_rails['manage_backup_path'] = false | |
# Use the Light navigational theme by default, since the default Indigo one | |
# looks bad with out logo. | |
gitlab_rails['gitlab_default_theme'] = 3 | |
# Enable Mattermost | |
mattermost_external_url 'https://mattermost.ourdomain.com' | |
# By default the NGINX bundled with the GitLab Docker image will auto-detect | |
# whether to use SSL if external_url contains https://. But we are running | |
# GitLab behind a reverse proxy (Apache), and wish to terminate SSL there. | |
# | |
# To do this, we still have to use https:// in external_url above, so that | |
# generated links et.c. are correct in GitLab, but also use the following | |
# snippets disable SSL in GitLab's NGINX. | |
nginx['listen_port'] = 80 | |
nginx['listen_https'] = false | |
nginx['proxy_set_headers'] = { | |
"X-Forwarded-Proto" => "https", | |
"X-Forwarded-Ssl" => "on", | |
"Host" => "git.ourdomain.com" | |
} | |
mattermost_nginx['listen_port'] = 81 | |
mattermost_nginx['listen_https'] = false | |
mattermost_nginx['proxy_set_headers'] = { | |
"X-Forwarded-Proto" => "https", | |
"X-Forwarded-Ssl" => "on", | |
"Host" => "mattermost.ourdomain.com" | |
} | |
ports: | |
- '3280:80' | |
- '3281:81' | |
volumes: | |
- '/srv/gitlab/config:/etc/gitlab' | |
- '/srv/gitlab/logs:/var/log/gitlab' | |
- '/srv/gitlab/data:/var/opt/gitlab' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment