-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yaml
52 lines (51 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
services:
db:
container_name: kfet-db
image: postgres:15-alpine
restart: always
env_file: ".env"
volumes:
- postgres_data:/var/lib/postgresql/data
- pg-socket:/var/run/postgresql
networks:
- kfet-network
cache:
build:
context: .
dockerfile: Dockerfile.redis
restart: always
volumes:
- redis-socket:/var/run/redis
- cache:/data
app:
container_name: kfet-app
build:
context: .
dockerfile: Dockerfile.app
restart: always
working_dir: /app
env_file: ".env"
command: sh -c "npm install && npm run db:deploy && npm run build && npm run start"
ports:
- "3000:3000"
expose:
- "3000"
depends_on:
- db
networks:
- kfet-network
volumes:
- redis-socket:/var/run/redis
- pg-socket:/var/run/postgresql
volumes:
postgres_data:
name: kfet-postgres-data
cache:
name: kfet-cache
redis-socket:
name: kfet-redis-socket
pg-socket:
name: kfet-pg-socket
networks:
kfet-network:
driver: bridge