How can I rewrite a request that comes in so that it is all lowercase? I've looked around and some answers were to use the rewrite Module but those weren't for the specific case of using a reverse proxy.
What I would want is for a request that comes in like this:
mywebsite/SomeApPlIcAtIon
to be converted to this:
mywebsite/someapplication/
Any Suggestions?
UPDATE:
I've got it setup with what I assume should be correct, my httpd.conf looks like this:
servername localhost
RewriteEngine on
RewriteLog "/var/log/apache2/rewrite.log"
RewriteLogLevel 9
RewriteMap lc int:tolower
RewriteCond %{REQUEST_URI} [A-Z]
RewriteRule (.*) ${lc:$1} [R=301,L]
My reverse proxy is setup in a file in conf.d called sabnzbd.conf as such:
ProxyRequests Off
ProxyPreserveHost On
<Proxy *>
Order allow,deny
Allow from all
</Proxy>
ProxyPass /sabnzbd/ 192.168.21.21:9999/sabnzbd/
ProxyPassReverse /sabnzbd 192.168.21.21:9999/sabnzbd/
In my enabled-sites, my 000-defailt I have all AllowOverride set to All
When I go to 192.168.21.21/sabnzbd/ it works just fine.
When I go to 192.168.21.21/SABNZBD/ I get a 404. The rewrite rule doesn't work.
When I go to my rewrite log file to check it out, there is no data.
What is going wrong?
Force Lowercase URL for Reverse Proxy on Ubuntu Apache Server
Forum rules
Help us help you:
Help us help you:
- Are you using the latest stable version of SABnzbd? Downloads page.
- Tell us what system you run SABnzbd on.
- Adhere to the forum rules.
- Do you experience problems during downloading?
Check your connection in Status and Interface settings window.
Use Test Server in Config > Servers.
We will probably ask you to do a test using only basic settings. - Do you experience problems during repair or unpacking?
Enable +Debug logging in the Status and Interface settings window and share the relevant parts of the log here using [ code ] sections.
Re: Force Lowercase URL for Reverse Proxy on Ubuntu Apache Server
... how is this a sabnzbd specific question?
