Welcome! Log In Create A New Profile

Advanced

Files in location

B.R.
February 01, 2012 12:38AM
Hello,

I would like to set up a rule redirecting the root location to another
address, but to serve files inside this location directly.
I tried the following:
location = / {
rewrite .* http://inter.net permanent;
}

http://intra.net/ is redirected as wanted
http://intra.net/codes.txt is also redirected... but that is not intended

How to avoid that? SHould I try something with an if or a try_files
directive on the $uri variable?
---
*B. R.*
_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Files in location

B.R. February 01, 2012 12:38AM

Re: Files in location

António P. P. Almeida February 01, 2012 01:04AM

Re: Files in location

B.R. February 01, 2012 02:10AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 121
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready