-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
74 lines (70 loc) · 1.6 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
version: '3.7'
services:
products-api:
image: node:18
container_name: products-api
working_dir: /usr/src/app
restart: always
depends_on:
postgres_database:
condition: service_healthy
ports:
- '8012:3000' # Expose Node API server on 8012
- '9238:9229' # Debugging related - server
- '9002:9002' # Debugging related - queue
volumes:
- .:/usr/src/app
- ./temp:/usr/src/app/temp
expose:
- '9238'
env_file:
- .env.local
command: sh -i development.sh
postgres_database:
image: postgres:14.1-alpine
restart: always
user: postgres
container_name: postgres_database
environment:
POSTGRES_USER: 'postgres'
POSTGRES_PASSWORD: 'password'
POSTGRES_DB: 'products'
POSTGRES_PORT: 5432
ports:
- '5432:5432'
expose:
- '5432'
volumes:
- dbdata:/var/lib/postgresql/data
healthcheck:
test: ['CMD-SHELL', 'pg_isready']
interval: 10s
timeout: 5s
retries: 5
# pgadmin:
# image: dpage/pgadmin4
# container_name: api_pgadmin
# links:
# - postgres_database
# environment:
# PGADMIN_DEFAULT_EMAIL: [email protected]
# PGADMIN_DEFAULT_PASSWORD: 1234
# restart: always
# ports:
# - 8083:80
# volumes:
# - dbdata-pgadmin:/var/lib/pgadmin
# logging:
# driver: none
redis:
container_name: redis
restart: always
image: redis:6.0-alpine
ports:
- "6379:6379"
volumes:
- app_redis_data:/data
volumes:
dbdata: null
dbdata-pgadmin: null
app_redis_data: null