-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
43 lines (41 loc) · 997 Bytes
/
docker-compose.yml
File metadata and controls
43 lines (41 loc) · 997 Bytes
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
services:
frontend:
image: nginx:alpine
container_name: helloworld_frontend
volumes:
- ./frontend:/usr/share/nginx/html:ro
- ./docker/frontend/nginx.conf:/etc/nginx/conf.d/default.conf:ro
restart: always
healthcheck:
test: curl -f http://localhost/
interval: 30s
timeout: 5s
retries: 2
start_period: 5s
start_interval: 5s
backend:
image: node:24-alpine
container_name: helloworld_backend
working_dir: /app
volumes:
- ./backend:/app:ro
command: node --enable-source-maps index.js
env_file:
- docker/backend/env
environment:
NODE_ENV: production
PORT: 4000
expose:
- 4000
restart: on-failure:5
healthcheck:
test: wget --no-verbose --tries=1 --spider http://127.0.0.1:4000/health || exit 1
interval: 30s
timeout: 5s
retries: 2
start_period: 25s
start_interval: 10s
networks:
default:
external: true
name: apps