Answer the question
In order to leave comments, you need to log in
How to cache only one method in nginx?
I want to cache successful responses from the server in nginx using only one method. Methods are specified in $request_uri.
In theory, you should use the if construct and direct it to the internal location where everything has already been described for caching and proxy_pass
if ( $request_uri ~ "^\/api\/info") {
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question