Problems getting case insensitive match to work
Mario Gazzo
mario.gazzo at gmail.com
Thu Nov 6 14:53:47 MSK 2008
Thanks a lot. This worked.
How is the ^ interpreted in NGINX? I did not find any examples/
documentation that indicated this was necessary. I like to understand
why I need it.
Cheers
Mario
On 06/11/2008, at 11.19, Igor Sysoev wrote:
> On Thu, Nov 06, 2008 at 10:49:50AM +0100, Mario Gazzo wrote:
>
>> I have for some reasons difficulties to get the following nginx setup
>> to respond case insensitive to www.mydomain.dk/demo. It only responds
>> to www.mydomain.dk/Demo. Shouldn't "~*" make the match case
>> insensitive? The nginx reverseproxy server runs linux whereas the
>> application server is Windows Server 2003 with IIS.
>>
>> What am I doing wrong?
>>
>> Cheers
>> Mario
>>
>> worker_processes 1;
>>
>> events {
>> worker_connections 1024;
>> }
>>
>> http {
>> include mime.types;
>> include proxy.conf;
>> default_type application/octet-stream;
>>
>> sendfile on;
>> keepalive_timeout 65;
>>
>> upstream demo_hosts {
>> server 192.168.0.97:80;
>> }
>>
>> server {
>> listen 80;
>>
>> server_name www.mydomain.dk;
>>
>> location ~* /Demo {
>> proxy_pass http://demo_hosts/Demo;
>> }
>>
>> }
>> }
>
> Try
>
> location ~* ^/Demo {
> proxy_pass http://demo_hosts;
> }
>
> proxy_pass inside location with regex may not have URI part (/Demo).
>
>
> --
> Igor Sysoev
> http://sysoev.ru/en/
>
More information about the nginx
mailing list