fix: prevent [No Host] panel errors behind CDN or missing Host header
Force nginx to pass the domain as Host, add PANEL_DOMAIN fallback in Flask, and document that the admin panel must be accessed over HTTP not HTTPS. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -20,10 +20,11 @@ server {
|
||||
__PANEL_ALLOW__
|
||||
proxy_pass http://127.0.0.1:5080/;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Host $host;
|
||||
proxy_set_header Host __DOMAIN__;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
proxy_set_header X-Forwarded-Proto $scheme;
|
||||
proxy_set_header X-Forwarded-Host __DOMAIN__;
|
||||
proxy_set_header X-Forwarded-Prefix __PANEL_PREFIX__;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user