nginx: fix regexes
This commit is contained in:
parent
ebb066c027
commit
7d2c00ef1f
|
@ -60,7 +60,7 @@ in
|
||||||
fastcgi_param SCRIPT_FILENAME $document_root/$fastcgi_script_name;
|
fastcgi_param SCRIPT_FILENAME $document_root/$fastcgi_script_name;
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
"~ ^/cmd/([^\\n|\\r]*)$".return = "301 https://pad.ifsr.de/$1";
|
"~ ^/cmd(/?[^\\n|\\r]*)$".return = "301 https://pad.ifsr.de$1";
|
||||||
# security
|
# security
|
||||||
"~* /(\.git|cache|bin|logs|backup|tests)/.*$".return = "403";
|
"~* /(\.git|cache|bin|logs|backup|tests)/.*$".return = "403";
|
||||||
# deny running scripts inside core system folders
|
# deny running scripts inside core system folders
|
||||||
|
|
|
@ -104,8 +104,8 @@ in
|
||||||
proxyPass = "http://127.0.0.1:${toString listenPort}";
|
proxyPass = "http://127.0.0.1:${toString listenPort}";
|
||||||
proxyWebsockets = true;
|
proxyWebsockets = true;
|
||||||
};
|
};
|
||||||
locations."~ ^/ese/([^\\n|\\r]*)$".return = "301 https://wiki.ese.ifsr.de/$1";
|
locations."~ ^/ese(/?[^\\n|\\r]*)$".return = "301 https://wiki.ese.ifsr.de$1";
|
||||||
locations."~ ^/fsr/([^\\n|\\r]*)$".return = "301 https://wiki.ifsr.de/$1";
|
locations."~ ^/fsr(/?[^\\n|\\r]*)$".return = "301 https://wiki.ifsr.de$1";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue