-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathdocker-compose.yml
46 lines (42 loc) · 992 Bytes
/
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
services:
next-app:
build:
context: ./
dockerfile: ./Dockerfile
environment:
- "POSTGRES_URL=postgresql://postgres:mysecretpassword@postgres:5432/mydb?schema=public"
- "REDIS_URL=redis://redis:6379"
ports:
- "3000:3000"
depends_on:
- postgres
- redis
api:
build:
context: ./
dockerfile: ./Dockerfile.api
environment:
- "POSTGRES_URL=postgresql://postgres:mysecretpassword@postgres:5432/mydb?schema=public"
- "REDIS_URL=redis://redis:6379"
- "CATCH_ALL_REDIRECT_URL=http://localhost:3001/public/catch-all-url.html"
ports:
- "3001:3001"
depends_on:
- postgres
- redis
postgres:
image: postgres
restart: always
ports:
- "5432:5432"
environment:
- POSTGRES_PASSWORD=mysecretpassword
volumes:
- postgres:/var/lib/postgresql/data
redis:
image: redis
restart: always
ports:
- "6379:6379"
volumes:
postgres: