-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
85 lines (78 loc) · 1.81 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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
version: '3'
services:
web:
build:
context: .
dockerfile: ./apps/web/Dockerfile
restart: always
ports:
- 3000:3000
expose:
- 3000
networks:
- doodle_together_network
backend:
build:
context: .
dockerfile: ./apps/backend/Dockerfile
restart: always
ports:
- 4000:4000
depends_on:
- postgres
- redis-db
links:
- postgres
- redis-db
environment:
REDIS_HOST: redis-db
REDIS_PORT: 6379
REDIS_PASSWORD: redispassword
DATABASE_URL: postgres://postgres:postgres@postgres:5432/doodle_together
ROOM_EXPIRES: 7200
JWT_COOKIE_NAME: auth-cookie
JWT_SECRET: kasasjvr5s8a6a8e2as
JWT_EXPIRY: 1d
SALT_ROUNDS: 10
APP_PORT: 4000
FRONTEND_ENDPOINT: http://localhost:3000
networks:
- doodle_together_network
redis-db:
image: redis:latest
ports:
- '6379:6379'
command: redis-server --save 20 1 --loglevel warning --requirepass redispassword
networks:
- doodle_together_network
postgres:
image: postgres:latest
restart: always
volumes:
- postgres-data:/var/lib/postgresql/data
ports:
- '5432:5432'
expose:
- 5432
environment:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: doodle_together
networks:
- doodle_together_network
pgadmin:
image: dpage/pgadmin4:latest
environment:
PGADMIN_DEFAULT_EMAIL: admin@example.com
PGADMIN_DEFAULT_PASSWORD: admin
ports:
- '8080:80'
networks:
- doodle_together_network
# Define a network, which allows containers to communicate
# with each other, by using their container name as a hostname
networks:
doodle_together_network:
driver: bridge
volumes:
postgres-data: