Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
39 lignes
1.1 KiB
Caddyfile
39 lignes
1.1 KiB
Caddyfile
# EXEMPLE — NON APPLIQUÉ. À adapter puis à appliquer par Théo (sudo) après accord de Nils.
|
|
# Bloc à ajouter au Caddyfile du VPS, À CÔTÉ du bloc jobrunner.fr existant (qui reste protégé
|
|
# par basic_auth, inchangé).
|
|
# Options globales (bloc en tête du Caddyfile : à FUSIONNER avec l'existant, pas à dupliquer)
|
|
{
|
|
servers {
|
|
timeouts {
|
|
read_header 10s
|
|
read_body 15s
|
|
write 20s
|
|
idle 15s
|
|
}
|
|
max_header_size 16KB
|
|
}
|
|
}
|
|
|
|
beta.jobrunner.fr {
|
|
encode zstd gzip
|
|
header {
|
|
Strict-Transport-Security "max-age=31536000"
|
|
X-Content-Type-Options nosniff
|
|
Referrer-Policy no-referrer
|
|
X-Robots-Tag "noindex, nofollow"
|
|
}
|
|
# Chaîne : ce Caddy (VPS) -> wg -> Caddy de cornafserver -> Python sur 127.0.0.1:8830 (jamais exposé).
|
|
# <IP_WG_CORNAFSERVER> : à lire sur le serveur (ip a show wg1), ne pas deviner.
|
|
reverse_proxy <IP_WG_CORNAFSERVER>:8830 {
|
|
header_up X-Forwarded-For {remote_host}
|
|
header_up X-Forwarded-Proto https
|
|
}
|
|
request_body {
|
|
max_size 3MB
|
|
}
|
|
log {
|
|
output file /var/log/caddy/beta.jobrunner.fr.log
|
|
# pas de corps, pas de cookie : le serveur ne journalise lui-même ni IP ni cookie
|
|
}
|
|
}
|