forked from nanoninja/docker-gogs-mysql
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
49 lines (46 loc) · 1.26 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
version: '3.4'
services:
gitea-db:
image: mariadb
container_name: ${GITEA_MYSQL_HOST}
restart: always
env_file:
- .env
environment:
- MYSQL_DATABASE=${GITEA_MYSQL_DATABASE}
- MYSQL_ROOT_PASSWORD=${GITEA_MYSQL_ROOT_PASSWORD}
- MYSQL_USER=${GITEA_MYSQL_USER}
- MYSQL_PASSWORD=${GITEA_MYSQL_PASSWORD}
volumes:
- /var/lib/mysql/gitea:/var/lib/mysql
networks:
default:
aliases:
- gitea-db
gitea-app:
image: gitea/gitea
container_name: gitea-app
restart: always
ports:
- ${GITEA_SSH_PORT}:22
environment:
- RUN_CROND=true
- VIRTUAL_HOST=${GITEA_VIRTUAL_HOST}
- VIRTUAL_PORT=3000
- LETSENCRYPT_HOST=${GITEA_VIRTUAL_HOST}
- LETSENCRYPT_EMAIL=${LETSENCRYPT_EMAIL}
volumes:
- /var/lib/gitea-data:/data
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
- ${LETSENCRYPT_CERT_ROOT_PATH}/${GITEA_VIRTUAL_HOST}:/etc/ssl/${GITEA_VIRTUAL_HOST}:ro
depends_on:
- gitea-db
networks:
default:
aliases:
- gitea
networks:
default:
external:
name: nginx-proxy