diff --git a/manifests/config.pp b/manifests/config.pp index c56373614..ff9392c46 100644 --- a/manifests/config.pp +++ b/manifests/config.pp @@ -60,7 +60,7 @@ $gzip_min_length = 20, $gzip_http_version = 1.1, $gzip_proxied = 'off', - $gzip_types = 'text/html', + $gzip_types = undef, $gzip_vary = 'off', $http_cfg_append = false, $http_tcp_nodelay = 'on', diff --git a/templates/conf.d/nginx.conf.erb b/templates/conf.d/nginx.conf.erb index ccf8fc108..f239d9fe9 100644 --- a/templates/conf.d/nginx.conf.erb +++ b/templates/conf.d/nginx.conf.erb @@ -74,7 +74,9 @@ http { <% if @gzip_proxied -%> gzip_proxied <%= @gzip_proxied %>; <% end -%> +<% if @gzip_types -%> gzip_types <%= @gzip_types.kind_of?(Array) ? @gzip_types.join(' ') : @gzip_types %>; +<% end -%> gzip_vary <%= @gzip_vary %>; <% end -%>