From 6adc2d9e3724f9a42ab824327b6d2b47dc4be408 Mon Sep 17 00:00:00 2001 From: Sanzhar Date: Thu, 1 Aug 2024 20:57:56 +0500 Subject: [PATCH 1/2] feat(issue-62): add gzip compression --- default.conf | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/default.conf b/default.conf index c1e92282..5145840a 100644 --- a/default.conf +++ b/default.conf @@ -50,4 +50,31 @@ server { #location ~ /\.ht { # deny all; #} + + gzip on; + gzip_vary on; + gzip_proxied any; + gzip_comp_level 6; + gzip_buffers 16 8k; + gzip_http_version 1.1; + gzip_types + application/atom+xml + application/geo+json + application/javascript + application/x-javascript + application/json + application/ld+json + application/manifest+json + application/rdf+xml + application/rss+xml + application/xhtml+xml + application/xml + font/eot + font/otf + font/ttf + image/svg+xml + text/css + text/javascript + text/plain + text/xml; } From 545f000c829bdfc5953884f202a8a16ff4ae1eda Mon Sep 17 00:00:00 2001 From: Sanzhar Date: Thu, 1 Aug 2024 21:19:24 +0500 Subject: [PATCH 2/2] refactor(issue-62): format gzip types --- default.conf | 38 +++++++++++++++++++------------------- 1 file changed, 19 insertions(+), 19 deletions(-) diff --git a/default.conf b/default.conf index 5145840a..f65a7e68 100644 --- a/default.conf +++ b/default.conf @@ -58,23 +58,23 @@ server { gzip_buffers 16 8k; gzip_http_version 1.1; gzip_types - application/atom+xml - application/geo+json - application/javascript - application/x-javascript - application/json - application/ld+json - application/manifest+json - application/rdf+xml - application/rss+xml - application/xhtml+xml - application/xml - font/eot - font/otf - font/ttf - image/svg+xml - text/css - text/javascript - text/plain - text/xml; + application/atom+xml + application/geo+json + application/javascript + application/x-javascript + application/json + application/ld+json + application/manifest+json + application/rdf+xml + application/rss+xml + application/xhtml+xml + application/xml + font/eot + font/otf + font/ttf + image/svg+xml + text/css + text/javascript + text/plain + text/xml; }