I’m using x-accel-redirect to serve a file from a location that has
gzip_static on; however instead of the pre-gzipped version, I am
getting me the un-gzip’d version of the file. I assume that locations
are respected for x-accel-redirects targets, what am I missing / where
should I look for more details? Config snippet follows.
This is the canonical name which redirects to the x_accel_redirect
location
location ~
/dispatch/.*/(ric_sw_version|config.xml|employee.xml|config_data.xml))
{
gzip off;
fastcgi_pass webservices;
include include/fastcgi.conf;
fastcgi_intercept_errors off;
break;
}
this is the direct-route to the dispatched location
location /dispatch {
root /nutricate/static;
gzip_static on;
gzip_proxied any;
break;
}
this is the x_accel_redirect target where the canonical name redirects
to.
location /x_accel_redirect {
internal;
alias /nutricate/static/;
gzip_static on;
gzip_proxied any;
}
}