Skip to content

Commit 3afad0c

Browse files
committed
增加 gzip 配置
1 parent db91366 commit 3afad0c

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

nginx-conf/default.conf

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,17 @@ server {
33
listen [::]:80;
44
server_name localhost;
55

6+
gzip on;
7+
gzip_static on;
8+
gzip_min_length 16k;
9+
gzip_buffers 4 128k;
10+
gzip_http_version 1.1;
11+
gzip_comp_level 3;
12+
gzip_types text/plain application/javascript application/x-javascript text/javascript text/css application/xml;
13+
gzip_vary on;
14+
gzip_proxied expired no-cache no-store private auth;
15+
gzip_disable "MSIE [1-6]\.";
16+
617
#access_log /var/log/nginx/host.access.log main;
718

819
location / {

0 commit comments

Comments
 (0)