-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
51 lines (50 loc) · 1.16 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
50
51
version: '3.9'
services:
api:
build:
context: api
environment:
DB_URL: postgresql://nivo:${POSTGRES_PASSWORD:-nivo}@db/nivo
ENV: PROD
SENTRY_DSN: ${SENTRY_DSN:-}
depends_on:
- db
labels:
- "traefik.enable=true"
- "traefik.http.routers.api.rule=Host(`api.nivo.test`)"
db:
image: postgis/postgis:14-3.1
environment:
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-nivo}
POSTGRES_USER: nivo
POSTGRES_DB: nivo
healthcheck:
interval: 30s
timeout: 30s
test: ["CMD", "pg_isready", "-U" ,"nivo"]
labels:
- "traefik.enable=false"
front:
build:
context: frontend
args:
API_HOST: api.nivo.test
API_PREFIX: http
API_PORT: 80
SENTRY_DISABLED: "false"
SENTRY_DSN: ${SENTRY_DSN:-}
depends_on:
- api
labels:
- "traefik.enable=true"
- "traefik.http.routers.front.rule=Host(`nivo.test`)"
proxy:
image: traefik:v2.5
command:
- "--api.insecure=true"
- "--providers.docker"
ports:
- "8080:8080"
- "80:80"
volumes:
- /var/run/docker.sock:/var/run/docker.sock