kong 開啓 gzip

vim /usr/local/share/lua/5.1/kong/templates/nginx.lua

http {
    gzip on;
    gzip_disable "msie6";
    gzip_min_length 1000;
    gzip_proxied expired no-cache no-store private auth;

    # do not add text/html to gzip_types because it's added by default and will generate
    # nginx: [warn] duplicate MIME type "text/html"
    # http://stackoverflow.com/a/6475493/703144
    gzip_types application/json application/x-javascript application/xml application/xml+rss text/css text/javascript text/plain text/xml;

    include 'nginx-kong.conf';
}
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章