-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.local.yaml
More file actions
99 lines (96 loc) · 2.35 KB
/
docker-compose.local.yaml
File metadata and controls
99 lines (96 loc) · 2.35 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
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
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
services:
nginx:
build:
context: .
dockerfile: nginx.Dockerfile.local
restart: always
ports:
- "80:80"
- "443:443"
volumes:
- ./nginx/ssl:/etc/nginx/ssl:ro
- ./nginx/certbot:/var/www/certbot:ro
depends_on:
server:
condition: service_healthy
end_user:
condition: service_started
networks:
- default
server:
build:
context: ./server
dockerfile: Dockerfile
restart: always
expose:
- "8081"
volumes:
- ./server/uploads:/server/uploads
- ./server/backups:/server/backups
env_file:
- .env
environment:
- SERVER_ADMIN_EMAIL=${SERVER_ADMIN_EMAIL:-admin@mail.com}
- SERVER_ADMIN_PASSWORD=${SERVER_ADMIN_PASSWORD:-admin}
- NODE_ENV=${NODE_ENV:-development}
- MONGODB_URL=${MONGODB_URL:-mongodb://mongo:27017}
depends_on:
mongo:
condition: service_started
healthcheck:
test:
[
"CMD",
"node",
"-e",
"require('http').get('http://localhost:8081/health', (r) => {process.exit(r.statusCode === 200 ? 0 : 1)})",
]
interval: 10s
timeout: 3s
retries: 3
start_period: 10s
networks:
- default
end_user:
build:
context: ./end_user
dockerfile: Dockerfile
restart: always
expose:
- "8080"
env_file:
- .env
environment:
- NODE_ENV=${NODE_ENV:-development}
- NUXT_API_BASE_URL=/api/
- NUXT_PUBLIC_BASE_URL=http://localhost
- NUXT_SSR_API_BASE_URL=http://localhost/api
- PORT=8080
- NITRO_PORT=8080
depends_on:
server:
condition: service_healthy
healthcheck:
test:
[
"CMD",
"node",
"-e",
"require('http').get('http://localhost:8080', (r) => {process.exit(r.statusCode < 500 ? 0 : 1)}).on('error', () => process.exit(1))",
]
interval: 10s
timeout: 5s
retries: 5
start_period: 30s
networks:
- default
mongo:
image: ghcr.io/navidshad/chord_library_mongodb:4.4.28
# Fallback to official MongoDB if GHCR image is not available locally
# Uncomment the line below if you don't have access to GHCR image
# image: mongo:4.4.28
volumes:
- ./database_data:/data/db
restart: always
networks:
- default