-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathdocker-compose.example.yml
More file actions
54 lines (48 loc) · 1.26 KB
/
docker-compose.example.yml
File metadata and controls
54 lines (48 loc) · 1.26 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
version: '3.8'
services:
# Example 1: Running at root path (default)
gait-detection-root:
build:
context: .
dockerfile: Dockerfile
image: gait-detection:latest
ports:
- "8080:80"
environment:
- BASE_PATH=/
# Example 2: Running at /gait-detection subpath
gait-detection-subpath:
# Use the same image - subpath is configured at runtime!
image: gait-detection:latest
ports:
- "8081:80"
environment:
- BASE_PATH=/gait-detection
# Example 3: Running at /apps/pose-detector subpath
gait-detection-nested:
# Use the same image - subpath is configured at runtime!
image: gait-detection:latest
ports:
- "8082:80"
environment:
- BASE_PATH=/apps/pose-detector
# Example 4: Behind a reverse proxy with path rewriting
gait-detection-proxied:
image: gait-detection:latest
environment:
- BASE_PATH=/ai/pose
networks:
- proxy-network
# Example reverse proxy
nginx-proxy:
image: nginx:alpine
ports:
- "80:80"
volumes:
- ./nginx-proxy.conf:/etc/nginx/conf.d/default.conf:ro
networks:
- proxy-network
depends_on:
- gait-detection-proxied
networks:
proxy-network: