-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
48 lines (46 loc) · 960 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
47
48
version: '3.8'
services:
database:
image: postgres:latest
container_name: postgres-database
ports:
- 5432:5432
environment:
- POSTGRES_USER=${DATABASE_USER}
- POSTGRES_PASSWORD=${DATABASE_PASSWORD}
- POSTGRES_DB=${DB_NAME}
networks:
- uno
backend:
build: ./
ports:
- 3000:3000
environment:
- DB_TYPE=${DB_TYPE}
- POSTGRES_HOST=${POSTGRES_HOST}
- POSTGRES_USER=${DATABASE_USER}
- POSTGRES_PASS=${DATABASE_PASSWORD}
- POSTGRES_DB=${DB_NAME}
- POSTGRES_SYNC=false
- POSTGRES_PORT=${POSTGRES_PORT}
depends_on:
- database
- redis
networks:
- uno
redis:
image: redis:latest
command: /bin/sh -c "redis-server "
container_name: redis
env_file:
- .env
restart: always
ports:
- 6379:6379
volumes:
- ./redis/data:/data
networks:
- uno
networks:
uno:
driver: bridge