Add never option to PUBLIC_URL_DETECTION configuration (#353)

https://github.com/go-gitea/gitea/pull/36785
Reviewed-on: https://gitea.com/gitea/docs/pulls/353
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: Zettat123 <zettat123@gmail.com>
Co-committed-by: Zettat123 <zettat123@gmail.com>
This commit is contained in:
Zettat123
2026-03-01 19:00:35 +00:00
committed by Lunny Xiao
parent d6bd3c6fb9
commit dc136aa31b
2 changed files with 2 additions and 0 deletions

View File

@@ -316,6 +316,7 @@ The following configuration set `Content-Type: application/vnd.android.package-a
especially when the Gitea instance needs to be accessed in a container network.
- "legacy": generate the public URL by "Host" header if "X-Forwarded-Proto" header exists, otherwise use "ROOT_URL".
- "auto": always use "Host" header, and also use "X-Forwarded-Proto" header if it exists. If no "Host" header, use "ROOT_URL".
- "never": always use "ROOT_URL", never detect from request headers.
- `STATIC_URL_PREFIX`: **_empty_**:
Overwrite this option to request static resources from a different URL.
This includes CSS files, images, JS files and web fonts.