This repository has been archived by the owner on Nov 18, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yaml
72 lines (67 loc) · 2.11 KB
/
docker-compose.yaml
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
61
62
63
64
65
66
67
68
69
70
71
72
version: '3.9'
services:
app:
build:
context: docker/app
dockerfile: Dockerfile
args:
USER: ${CONTAINER_USER_NAME}
GROUP: ${CONTAINER_GROUP_NAME}
UID: ${LOCAL_UID}
GID: ${LOCAL_GID}
container_name: ${CONTAINER_BASE_NAME}_app
labels:
- "traefik.enable=true"
- "traefik.http.routers.`${CONTAINER_BASE_NAME}`.rule=Host(`${HOST_APP}`)" # domain to expose on
- "traefik.docker.network=traefik_proxy"
ports:
- '${FORWARDED_DEFAULT_PORT:-80}:80'
volumes:
- './:/var/www/app'
networks:
- default
- traefik_proxy
- ac-network
depends_on:
- mariadb
mariadb:
image: mariadb
container_name: ${CONTAINER_BASE_NAME}_mariadb
labels:
- "traefik.enable=false"
ports:
- '${FORWARDED_DB_PORT:-3306}:3306'
environment:
- MYSQL_ROOT_PASSWORD=${DB_ROOT_PASSWORD}
- MYSQL_DATABASE=${DB_DATABASE}
- MYSQL_USER=${DB_USERNAME}
- MYSQL_PASSWORD=${DB_PASSWORD}
volumes:
- mariadb:/var/lib/mysql
networks:
- default
mailhog:
image: 'mailhog/mailhog:latest'
container_name: ${CONTAINER_BASE_NAME}_mail
labels:
- "traefik.enable=true"
- "traefik.http.routers.`${CONTAINER_BASE_NAME}`_mail.rule=Host(`${HOST_MAIL}`)" # domain to expose on\
- "traefik.http.services.`${CONTAINER_BASE_NAME}`_mail.loadbalancer.server.port=8025"
- "traefik.docker.network=traefik_proxy"
ports:
- '${FORWARDED_MAIL_PORT:-1025}:1025'
- '${FORWARDED_MAIL_DASHBOARD_PORT:-8025}:8025'
networks:
- default
- traefik_proxy
networks:
default:
driver: bridge
name: ${CONTAINER_BASE_NAME}
ac-network:
name: ${DB_AUTH_DOCKER_NETWORK}
external: true
traefik_proxy:
external: true
volumes:
mariadb: