Terminates HTTPS on port 443 with self-signed cert, redirects :80 to HTTPS. Required for Payload admin CSRF (browsers only send Sec-Fetch-Site in secure context). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
12 lines
148 B
Caddyfile
12 lines
148 B
Caddyfile
{
|
|
auto_https off
|
|
}
|
|
|
|
:80 {
|
|
redir https://{host}{uri} permanent
|
|
}
|
|
|
|
:443 {
|
|
tls /certs/cert.pem /certs/key.pem
|
|
reverse_proxy app:3000
|
|
}
|