Welcome! Log In Create A New Profile

Advanced

Re: try_files is broken with geoip?

Francis Daly
March 30, 2015 03:20PM
On Mon, Mar 30, 2015 at 08:26:13PM +0300, Peter Volkov wrote:

Hi there,

> We experience problem: if inside location we use geoip variable try_files
> is not working and only root location is looked up for files.

That is working as expected for "if" inside "location". It's unrelated
to geoip.

http://wiki.nginx.org/IfIsEvil

Third item:

# try_files wont work due to if

location /if-try-files {
try_files /file @fallback;

set $true 1;

if ($true) {
# nothing
}
}

You'll want to redesign whatever you are doing not to use "if" inside
"location" for anything other than "return" or effective equivalents.

f
--
Francis Daly francis@daoine.org

_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

try_files is broken with geoip?

Peter Volkov March 30, 2015 01:28PM

Re: try_files is broken with geoip?

itpp2012 March 30, 2015 01:45PM

Re: try_files is broken with geoip?

Peter Volkov March 30, 2015 03:18PM

Re: try_files is broken with geoip?

itpp2012 March 30, 2015 05:11PM

Re: try_files is broken with geoip?

Francis Daly March 30, 2015 03:20PM

Re: try_files is broken with geoip?

Peter Volkov March 30, 2015 03:52PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 296
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