On Mon, Oct 06, 2025 at 09:46:36AM +0200, Tom Rodr wrote:
> If any url ends with "/" but the directory does not exist,
> open the same url, but without the "/" at the
> end.
>
> ie:
>
> if the following doesn't exist
> http://example.com/non/existent/path/
> open:
> http://example.com/non/existent/path
>
> It doesn't matter, whether the redirected path exists.
>
> (if the directory does exist, don't redirect anywhere
> and open it normally)
Do you want a redirect at the http level, or do you want to simply serve the
content at both urls?
If you want a redirect, something like this in httpd.conf should work:
location not found match "^(.+)/$" {
block return 303 "%1"
}
If that's not what you wanted, let us know.