-
-
Notifications
You must be signed in to change notification settings - Fork 102
Open
Labels
bugSomething isn't workingSomething isn't workinghelp wantedExtra attention is neededExtra attention is neededv2v2 releasev2 release
Description
Search for duplicate issues
- I already searched, and this issue is not a duplicate.
Issue scope
Docker / Kubernetes
Describe the bug
In my case I have to specify globing pattern to set alternative root path for my static. The config is:
[general]
....
redirect-trailing-slash = true
....
[[advanced.rewrites]]
source = "/value/manage{**}"
destination = "/$1"
That's required cause I store my static in ./public
root, but endpoint is behind the nginx reverse proxy on location /value/manage
So, the accessed URL from browser is 'example.com/value/manage' provides no redirect to trailing slash URL, breaking my relative paths
I know the workaround is to specify rewrites inside reverse proxy configuration or probably just make hard redirect using [[advanced.redirects]]
but anyways, the redirect-trailing-slash
seems for me completely not working
How to reproduce it
- Create a new server with enabled
{**}
rewrite directive and specifyredirect-trailing-slash = true
- Try to access server endpoint without trailing slash at the URL
For example takeexample.com/manage
Expected behavior
HTTP 301
or HTTP 308
redirect to example.com/manage/
URL
Complementary information
No response
Build target
Docker linux/amd64
Environment and specs
- static-web-server: [e.g. v1.24.1]
- OS: [e.g. Debian 12.2, Macos 14.1.2, Windows 11, etc]
- Arch: [e.g. x86_64 (64-bit), ARM (32-bit), ARM64 (64-bit), i686 (32-bit), etc]
- Docker: [e.g. 20.10.7]
- Client: [e.g. Chrome 91.0.4472.114, Firefox 119.0.1, curl, etc]
- Specify others
Additional context
No response
valerii15298
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workinghelp wantedExtra attention is neededExtra attention is neededv2v2 releasev2 release