From 3afad0ceb0a1f6c0cf53d0d550b563e7b6b2838e Mon Sep 17 00:00:00 2001 From: zhaojun <873019219@qq.com> Date: Thu, 4 Jul 2024 22:14:30 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=20gzip=20=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- nginx-conf/default.conf | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/nginx-conf/default.conf b/nginx-conf/default.conf index 8359fb7..ad4ec57 100644 --- a/nginx-conf/default.conf +++ b/nginx-conf/default.conf @@ -3,6 +3,17 @@ server { listen [::]:80; server_name localhost; + gzip on; + gzip_static on; + gzip_min_length 16k; + gzip_buffers 4 128k; + gzip_http_version 1.1; + gzip_comp_level 3; + gzip_types text/plain application/javascript application/x-javascript text/javascript text/css application/xml; + gzip_vary on; + gzip_proxied expired no-cache no-store private auth; + gzip_disable "MSIE [1-6]\."; + #access_log /var/log/nginx/host.access.log main; location / {