fix nginx location regexp

This commit is contained in:
wxiaoguang 2024-05-18 10:22:34 +08:00
parent 3fd173b73a
commit 7e3ba7db73
1 changed files with 1 additions and 4 deletions

View File

@ -68,10 +68,7 @@ into the `http` section of `nginx.conf`:
```nginx
server {
...
location /gitea {
return 301 $scheme://$host/gitea/;
}
location ~ ^/(gitea|v2)/ {
location ~ ^/(gitea|v2)($|/) {
client_max_body_size 512M;
# make nginx use unescaped URI, keep "%2F" as-is, remove the "/gitea" sub-path prefix, pass "/v2" as-is.