Skip to content

Instantly share code, notes, and snippets.

@hardik250186
Forked from punit5658/nginx.conf
Created May 31, 2018 12:12
Show Gist options
  • Save hardik250186/6590dd0f8d826e798a4e778ee83ce19d to your computer and use it in GitHub Desktop.
Save hardik250186/6590dd0f8d826e798a4e778ee83ce19d to your computer and use it in GitHub Desktop.
Nginx Configuration
gzip on;
gzip_static on;
gzip_disable "msie6";
gzip_vary on;
gzip_proxied any;
gzip_comp_level 6;
gzip_min_length 512;
gzip_buffers 16 8k;
gzip_http_version 1.1;
gzip_types text/css text/javascript text/xml text/plain text/x-component application/javascript application/x-javascript application/json application/xml application/rss+xml font/truetype application/x-font-ttf font/opentype application/vnd.ms-fontobject image/svg+xml;
location ~* \.(jpg|jpeg|png|gif|ico|css|js|mp3)$ {
expires 30d;
add_header Cache-Control public,max-age=259200;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment