Skip to content

Commit de279c1

Browse files
committed
update caddy config
1 parent 5651c9a commit de279c1

File tree

2 files changed

+21
-22
lines changed

2 files changed

+21
-22
lines changed

demo/Caddyfile

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
demo.pulsebeam.dev {
2+
# Use Let's Encrypt for trusted certificates
3+
# Uncomment and add your email for production
4+
# tls your-email@example.com
5+
6+
# Simple reverse proxy to your application
7+
reverse_proxy localhost:3000
8+
}

demo/compose.yaml

Lines changed: 13 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,40 +1,31 @@
11
version: "3.8"
2-
32
services:
43
pulsebeam:
54
image: ghcr.io/pulsebeamdev/pulsebeam:pulsebeam-v0.1.12
65
restart: unless-stopped
76
network_mode: "host" # Linux only; uses real host IPs for WebRTC
7+
healthcheck:
8+
test: ["CMD", "curl", "-f", "http://localhost:3000/healthz"]
9+
interval: 30s
10+
timeout: 10s
11+
retries: 3
12+
start_period: 10s
13+
logging:
814

915
caddy:
10-
image: caddy:2
16+
image: docker.io/library/caddy:2
1117
restart: unless-stopped
1218
network_mode: "host" # shares host networking
1319
volumes:
20+
- ./Caddyfile:/etc/caddy/Caddyfile:z # Mount the Caddyfile from the host
1421
- caddy_data:/data
1522
- caddy_config:/config
16-
configs:
17-
- source: caddyfile
18-
target: /etc/caddy/Caddyfile
1923
command: ["caddy", "run", "--config", "/etc/caddy/Caddyfile", "--adapter", "caddyfile"]
24+
environment:
25+
- CADDY_ADMIN=0.0.0.0:2019 # Expose Caddy admin API for monitoring (optional)
2026

2127
volumes:
2228
caddy_data:
29+
name: caddy_data
2330
caddy_config:
24-
25-
configs:
26-
caddyfile:
27-
data: |
28-
YOUR_DOMAIN_HERE {
29-
reverse_proxy pulsebeam:3478
30-
31-
# rate limiting for HTTP requests (signaling)
32-
@http_requests {
33-
path /api/v1/*
34-
}
35-
rate_limit @http_requests {
36-
window 1m
37-
average 30
38-
burst 50
39-
}
40-
}
31+
name: caddy_config

0 commit comments

Comments
 (0)