coder-templates/configs/fox-api/nginx/nginxconfig.io/general.conf

27 lines
668 B
Text
Raw Normal View History

2023-09-26 15:03:01 -04:00
# favicon.ico
location = /favicon.ico {
log_not_found off;
2023-09-26 15:03:01 -04:00
}
# robots.txt
location = /robots.txt {
log_not_found off;
2023-09-26 15:03:01 -04:00
}
# assets, media
location ~* \.(?:css(\.map)?|js(\.map)?|jpe?g|png|gif|ico|cur|heic|webp|tiff?|mp3|m4a|aac|ogg|midi?|wav|mp4|mov|webm|mpe?g|avi|ogv|flv|wmv)$ {
expires 7d;
2023-09-26 15:03:01 -04:00
}
# svg, fonts
location ~* \.(?:svgz?|ttf|ttc|otf|eot|woff2?)$ {
add_header Access-Control-Allow-Origin "*";
expires 7d;
2023-09-26 15:03:01 -04:00
}
# gzip
gzip on;
gzip_vary on;
gzip_proxied any;
2023-09-26 15:03:01 -04:00
gzip_comp_level 6;
gzip_types text/plain text/css text/xml application/json application/javascript application/rss+xml application/atom+xml image/svg+xml;