From 5827b0c16ac62a0ffd05a5f781c9c6e492d3a7e8 Mon Sep 17 00:00:00 2001 From: Paul Sarena Date: Wed, 2 Feb 2011 07:21:18 +0800 Subject: [PATCH] Add to and fix typo in MIME types to be gzipped: Add text/x-component. It's listed in html5-boilerplate/.htaccess and is in our nginx-mime.types Fix application/xml+rss, should be application/rss+xml Comment indicating text/html is always compressed, so there's no need to include it --- nginx.conf | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/nginx.conf b/nginx.conf index 9756886..a93b8c6 100644 --- a/nginx.conf +++ b/nginx.conf @@ -67,7 +67,21 @@ http { gzip_min_length 1100; gzip_buffers 4 8k; gzip_proxied any; - gzip_types text/plain text/xml application/xml application/xml+rss text/css text/javascript application/javascript application/json image/svg+xml font/truetype font/opentype application/vnd.ms-fontobject; + gzip_types + # text/html is always compressed by HttpGzipModule + text/css + text/javascript + text/xml + text/plain + text/x-component + application/javascript + application/json + application/xml + application/rss+xml + font/truetype + font/opentype + application/vnd.ms-fontobject + image/svg+xml; gzip_static on;