-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
60 lines (56 loc) · 2.02 KB
/
docker-compose.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
version: '3.3'
services:
web:
image: 'gitlab/gitlab-ce:latest'
restart: unless-stopped
hostname: ${GITLAB_HOSTNAME}
environment:
GITLAB_OMNIBUS_CONFIG: |
external_url "https://${GITLAB_HOSTNAME}"
nginx['listen_port'] = '80'
nginx['listen_https'] = false
gitlab_rails['gitlab_shell_ssh_port'] = ${GITLAB_SSH_PORT}
# If you want enable mattermost, remove this line and uncomment the following lines
# mattermost_external_url "http://mattermost.${GITLAB_HOSTNAME}"
# mattermost['gitlab_auth_endpoint'] = "http://${GITLAB_HOSTNAME}/oauth/authorize"
# mattermost['gitlab_token_endpoint'] = "http://${GITLAB_HOSTNAME}/oauth/token"
# mattermost['gitlab_user_api_endpoint'] = "http://${GITLAB_HOSTNAME}/api/v4/user"
# Traefik labels are suggested as an example for people using Traefik,
# remove them if you are using another reverse proxy.
labels:
traefik.enable: 'true'
traefik.http.routers.gitlab.entrypoints: websecure
traefik.http.routers.gitlab.rule: "Host(`${GITLAB_HOSTNAME}`)"
traefik.http.routers.gitlab.tls.certresolver: myresolver
# If you want enable mattermost, comment the previous line and uncomment the next line
# traefik.http.routers.gitlab.tls.certresolver: "Host(`${GITLAB_HOSTNAME}`,`mattermost.${GITLAB_HOSTNAME}`)"
traefik.http.services.gitlab.loadbalancer.server.port: 80
# If you don't want to use a reverse proxy (not suitable for production!)
# ports:
# - "80:80"
networks:
- default
- web
ports:
- ${GITLAB_SSH_PORT}:22
volumes:
- web_config:/etc/gitlab
- web_logs:/var/log/gitlab
- web_data:/var/opt/gitlab
runner:
image: 'gitlab/gitlab-runner:latest'
networks:
- runner
restart: unless-stopped
volumes:
- runner_config:/etc/gitlab-runner
- /var/run/docker.sock:/var/run/docker.sock
networks:
runner:
web:
external: true
volumes:
runner_config:
web_config:
web_data:
web_logs: