-
-
Notifications
You must be signed in to change notification settings - Fork 2
/
compose.prod.yml
49 lines (45 loc) · 1003 Bytes
/
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
name: stationapi-prod
services:
api:
build:
context: .
dockerfile: ./docker/api/Dockerfile.prod
depends_on:
- db
- migration
environment:
DATABASE_URL: mysql://stationapi:password@db/stationapi
ACCEPT_HTTP1: true
HOST: 0.0.0.0
ports:
- 50051:50051
restart: always
networks:
- sapi-link
db:
image: mariadb:11.5.2
environment:
MARIADB_RANDOM_ROOT_PASSWORD: true
MARIADB_USER: stationapi
MARIADB_PASSWORD: password
MARIADB_DATABASE: stationapi
restart: always
networks:
- sapi-link
migration:
build:
context: .
dockerfile: ./docker/migration/Dockerfile
command: ["./wait-for-it.sh", "db:3306", "--", "./migration"]
depends_on:
- db
environment:
MYSQL_USER: stationapi
MYSQL_PASSWORD: password
MYSQL_HOST: db
MYSQL_DATABASE: stationapi
restart: on-failure
networks:
- sapi-link
networks:
sapi-link: