-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose-prod.yml
60 lines (53 loc) · 1.39 KB
/
docker-compose-prod.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'
services:
# Fast API service
api-whoami:
image: api-whoami
build:
context: ./api_whoami
dockerfile: Dockerfile
ports:
- 8000
# Angular service
app-whoami:
image: app-whoami
build:
context: ./app-whoami
dockerfile: Dockerfile
deploy:
labels:
- "traefik.enable=true"
- "traefik.http.routers.whoami.rule=Host(`app-whoami.localhost`)"
- "traefik.http.routers.whoami.entrypoints=web"
ports:
- 80
# Redis service for redis things.
redis-whoami:
image: redis
ports:
- 6379
volumes:
- redis-whoami-vol:/data
# MySQL service for redis things.
mysql-whoami:
image: redis
environment:
- MYSQL_ROOT_PASSWORD=angular-fastapi
- MYSQL_DATABASE=angular-fastapi
- MYSQL_USER=angular-fastapi
- MYSQL_PASSWORD=angular-fastapi
ports:
- 3306
volumes:
- mysql-whoami-vol:/data
# Postgres service for postgres things.
postgres-whoami:
image: postgres
ports:
- 5432
volumes:
- postgres-whoami-vol:/var/lib/postgresql
volumes:
redis-whoami-vol:
postgres-whoami-vol:
mysql-whoami-vol: