forked from powerhouse-inc/switchboard
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yaml
52 lines (47 loc) · 1.05 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
version: '3'
services:
database:
restart: unless-stopped
image: postgres:15
expose:
- 5432
environment:
POSTGRES_DB: "postgres"
POSTGRES_USER: "postgres"
POSTGRES_PASSWORD: "postgres"
POSTGRES_PORT: "5432"
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres"]
interval: 1s
timeout: 5s
retries: 5
api:
restart: unless-stopped
expose:
- 3000
build:
context: ./api
environment:
DATABASE_URL: postgres://postgres:postgres@database:5432/postgres?sslmode=disable
AUTH_SIGNUP_ENABLED: "1"
JWT_SECRET: replace_in_production_with_actual_secret
JWT_EXPIRATION_PERIOD_SECONDS: 3600
depends_on:
- database
frontend:
restart: unless-stopped
build:
context: .
dockerfile: ./frontend/Dockerfile
expose:
- 3000
reverse-proxy:
restart: unless-stopped
image: nginx:stable
ports:
- '80:80'
volumes:
- ./nginx.conf:/etc/nginx/nginx.conf
depends_on:
- api
- frontend