-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathdocker-compose.yml
78 lines (71 loc) · 1.63 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
75
76
77
78
services:
api:
image: ghcr.io/satont/livestreamx:api-latest
build:
context: .
dockerfile: apps/api/Dockerfile
args:
- VITE_STREAM_URL=http://localhost:8889/mystream/
env_file: .env
networks:
- default
- caddy
restart: always
depends_on:
postgres:
condition: service_healthy
volumes:
- ./thumbnails:/app/thumbnails
labels:
caddy: streamx.satont.dev
caddy.handle_path: /api/*
caddy.handle_path.0_reverse_proxy: "{{upstreams 1337}}"
frontend:
image: ghcr.io/satont/livestreamx:frontend-latest
restart: always
build:
context: .
dockerfile: apps/frontend/Dockerfile
networks:
- default
- caddy
labels:
caddy: streamx.satont.dev
caddy.reverse_proxy: "{{upstreams 8080}}"
redis:
image: redis:latest
command: redis-server --appendonly yes
restart: always
volumes:
- redis:/data
postgres:
image: postgres:16
environment:
POSTGRES_USER: livestreamx
POSTGRES_PASSWORD: livestreamx
POSTGRES_DB: livestreamx
volumes:
- postgres:/var/lib/postgresql/data
restart: always
healthcheck:
test: [ "CMD-SHELL", "pg_isready" ]
interval: 10s
timeout: 5s
retries: 5
mediamtx:
image: ghcr.io/satont/livestreamx:mediamtx-latest
restart: always
network_mode: host
volumes:
- ./mediamtx.yml:/mediamtx.yml
- ./thumbnails:/thumbnails
nats:
image: nats:2.10.11-scratch
command: -js -m 8222
restart: always
volumes:
postgres:
redis:
networks:
caddy:
external: true