Files
de-praxis/deploy/Caddyfile
T
juli f237a0c25d Add the relay campaign library and its control panel page
Imported .dpc packages under DATA_DIR/campaigns/library with version rules, enable/hide, default, export, delete and clean-up of unused pinned versions; MAX_CAMPAIGNS; public cover route; admin API with per-route body limits; /admin/campaigns page with shared panel helpers.
2026-10-25 03:02:05 +01:00

46 lines
997 B
Caddyfile

{
servers {
max_header_size 16KB
timeouts {
read_header 5s
read_body 10s
write 45s
idle 30s
}
}
}
# Replace with your actual domain. Caddy manages HTTPS certificates and renewal.
relay.example.com {
request_body {
max_size 16KB
}
header {
Strict-Transport-Security "max-age=31536000"
X-Content-Type-Options nosniff
Referrer-Policy no-referrer
-Server
}
# Allowlist game routes. Never proxy the administration surface publicly.
@game path /health /campaigns /campaigns/* /rooms /rooms/*
handle @game {
reverse_proxy 127.0.0.1:1337 {
# Tiny bounded JSON requests are fully received before occupying a Java worker.
request_buffers 16KB
unhealthy_request_count 32
# Replace untrusted client-supplied forwarding headers.
header_up X-Real-IP {remote_host}
header_up X-Forwarded-Proto {scheme}
transport http {
dial_timeout 3s
response_header_timeout 40s
max_conns_per_host 64
}
}
}
handle {
respond "Not found" 404
}
}