-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.yml
55 lines (51 loc) · 1.03 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
version: '3.8'
services:
db:
container_name: db
build:
context: .
dockerfile: ./docker/db/Dockerfile
restart: always
ports:
- "5432:5432"
environment:
- POSTGRES_DB=strichka_local
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
- POPULATE_LOCAL_DB=true
volumes:
- postgres_data:/var/lib/postgresql/data/
redis:
container_name: redis
image: redis:7.0.1
ports:
- "6379:6379"
volumes:
- redis_data:/data/redis:rw
app:
container_name: app
build:
context: .
dockerfile: ./docker/app/Dockerfile
restart: always
volumes:
- ./:/app
ports:
- "8080:8080"
environment:
- POSTGRES_HOST=db
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
- POSTGRES_DB=strichka_local
- POSTGRES_PORT=5432
- REDIS_HOST=redis
- REDIS_PASSWORD=
- REDIS_PORT=6379
env_file:
- .env
depends_on:
- db
- redis
volumes:
postgres_data:
redis_data: