Welcome! Log In Create A New Profile

Advanced

Re: Cache only static files in sub/subfolder but not sub

Francis Daly
February 20, 2017 02:08PM
On Sun, Feb 19, 2017 at 02:53:22PM -0500, JoakimR wrote:

Hi there,

> Now the trouble shooting: as noticed above, this only works when I out
> comments the second location, which is NOT to be cached at all. I have of
> course tried to switch between which location comes first. Even chose I
> recall it as first rule matching is served first.
>
> Any one who can tell me why this isn't working as i like it to?

> location /thumbs/embedded {

> ##Match what's not in above location directive
> location ~* ^.+.(jpg|jpeg|gif|css|png|js|ico|xml)$ {

It looks to me like you want "match the prefix location, and then do
not check the regex locations".

There's a squiggle for that. http://nginx.org/r/location

f
--
Francis Daly francis@daoine.org
_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Cache only static files in sub/subfolder but not sub

JoakimR February 19, 2017 02:53PM

Re: Cache only static files in sub/subfolder but not sub

JoakimR February 20, 2017 07:52AM

Re: Cache only static files in sub/subfolder but not sub

Francis Daly February 20, 2017 02:08PM

Re: Cache only static files in sub/subfolder but not sub

JoakimR February 22, 2017 11:01AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

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