-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yaml
56 lines (53 loc) · 1.22 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
version: "3.9"
services:
nats:
image: nats:latest
restart: always
expose:
- 4222
- 6222
ports:
- 8222:8222
db:
image: postgres:latest
restart: always
ports:
- 5432:5432
environment:
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=password
migrations:
build: ./
image: ghcr.io/chrismeller/fourchan-monitor:main
restart: "no"
depends_on:
db:
condition: service_started
command: yarn run migrate:prod
environment:
- DATABASE_HOST=db
- DATABASE_PORT=5432
- DATABASE_USERNAME=postgres
- DATABASE_PASSWORD=password
- DATABASE_DATABASE=postgres
monitor:
build: ./
image: ghcr.io/chrismeller/fourchan-monitor:main
restart: on-failure
ports:
- 3000:3000
depends_on:
nats:
condition: service_started
migrations:
condition: service_completed_successfully
environment:
- NATS_URL=nats://nats:4222
- NODE_ENV=production
- BOARDS=b,pol,biz,adv,trv,news,int
- LOG_LEVELS=log,warn,error
- DATABASE_HOST=db
- DATABASE_PORT=5432
- DATABASE_USERNAME=postgres
- DATABASE_PASSWORD=password
- DATABASE_DATABASE=postgres