location ~^/([0-9]*)/(.*)$ {
set $cache_file $1;
set $redirect 0;
if ( $http_cookie ~* qa_session ) {
set $redirect 1;
}
if ( $request_method = POST ) {
set $redirect 1;
}
if ( $redirect = 1 ) {
return 412;
error_page 412 = @goapach;
}
types {}
default_type text/html;
try_files /qa-plugin/cache-master/cache/$cache_file @goapach;
}