Welcome! Log In Create A New Profile

Advanced

can proxy_cache(nginx) in front of internal location?

February 27, 2014 09:56PM
I want to using proxy_cache in front of internal location,but proxy_pass not work.my code like following:

location /proxy {
proxy_cache cache;
proxy_cache_key $uri;
proxy_cache_valid 200 304 10d;
expires 10d;
proxy_pass @bar;
}

location @bar {
internal;
content_by_lua '
ngx.log(ngx.ERR,"sssssssssssssssssss")
ngx.say("yaha")
';
}

proxy_cache must used with proxy_pass?any other method to do this?

Thanks.
Subject Author Posted

can proxy_cache(nginx) in front of internal location?

ljw79618@gmail.com February 27, 2014 09:56PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

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