-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
49 lines (47 loc) · 1.02 KB
/
docker-compose.yml
File metadata and controls
49 lines (47 loc) · 1.02 KB
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
version: '3'
services:
db:
container_name: chatDB
build:
context: ./db
dockerfile: Dockerfile
env_file:
- ./db/.env
volumes:
- /var/docker/postgres_data:/var/lib/postgresql/data
restart: always
healthcheck:
test: [ "CMD-SHELL", "pg_isready -U postgres" ]
interval: 5s
timeout: 5s
retries: 5
app:
container_name: chatApi
build:
context: ./app
dockerfile: Dockerfile
restart: always
env_file:
- ./app/.env
ports:
- "3030:3030"
depends_on:
db:
condition: service_healthy
volumes:
- ./src:/app/src
healthcheck:
test: [ "CMD", "curl", "-f", "http://localhost:3030/health" ]
interval: 30s
timeout: 10s
retries: 3
fluentd:
container_name: chatfluentd
user: root
image: fluent/fluent:latest
volumes:
- /var/lib/docker/containers:/fluentd/log/containers
- ./fluent.conf:/fluentd/etc/fluent.conf
- ./logs:/output/
logging:
driver: "local"