Why does nginx always send content encoding as gzip

sobuz nginx-forum at forum.nginx.org
Wed Oct 5 10:29:13 UTC 2016


I have set gzip to off

user  nginx;
worker_processes  1;

error_log  /var/log/nginx/error.log warn;
pid        /var/run/nginx.pid;


events {
    worker_connections  1024;
}


http {
    include       /etc/nginx/mime.types;
    default_type  application/octet-stream;

    log_format  main  '$remote_addr - $remote_user [$time_local] "$request"
'
                      '$status $body_bytes_sent "$http_referer" '
                      '"$http_user_agent" "$http_x_forwarded_for"';

    access_log  /var/log/nginx/access.log  main;

    sendfile        on;
    #tcp_nopush     on;

    keepalive_timeout  65;
    gzip off;


    include /etc/nginx/conf.d/*.conf;
}
Check it is not set anywhere else

cd /etc/nginx/
 grep -R gzip .

./nginx.conf:    gzip off;


service nginx restart
yet content is still getiing sent as gzip?

Response Headers

Connection:keep-alive
Content-Encoding:gzip
Content-Length:51
Content-Type:application/json; charset=utf-8 
Date:Wed, 05 Oct 2016 10:00:00 GMT 
Server:nginx/1.6.2 
Vary:Accept-Encoding

Any ideas to turn gzip off completely

Posted at Nginx Forum: https://forum.nginx.org/read.php?2,270070,270070#msg-270070



More information about the nginx mailing list