-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.backend.yaml
42 lines (38 loc) · 1.25 KB
/
docker-compose.backend.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
version: "3.8"
# Variables used in this Compose file are handled via Portainer, hence a different syntax from base infra
services:
mysql:
image: mysql:8.0.32
container_name: quizae-mysql
volumes:
- mysql_data:/var/lib/mysql
networks:
- db_access
environment:
MYSQL_ROOT_PASSWORD: $MYSQL_ROOT_PASSWORD
MYSQL_DATABASE: $MYSQL_DATABASE
backend:
image: ghcr.io/mareddie/quizae-backend:latest
networks:
- db_access
- public
environment:
APP_ENV: $APP_ENV
DATABASE_URL: $APP_DATABASE_URL
JWT_SECRET: $APP_JWT_SECRET
labels:
- traefik.enable=true
- traefik.http.routers.backend.entrypoints=websecure
- traefik.http.routers.backend.rule=Host(`$QUIZAE_BACKEND_HOST`)
- traefik.http.routers.backend.tls=true
- traefik.http.routers.backend.tls.certresolver=default-resolver
- traefik.http.routers.backend.service=backend
- traefik.http.services.backend.loadbalancer.server.port=3000
networks:
db_access:
external: true
public:
external: true
volumes:
mysql_data:
external: true