Изменить 'staticfiles.conf'

This commit is contained in:
2021-02-21 06:11:21 +00:00
parent 17440d0fdb
commit 7bb89e9e7e

View File

@ -1,18 +1,10 @@
rewrite ^(.*)\.(\d+)\.(css|js)$ $1.$3 break;
location ~* \.(jpg|jpeg|gif|png|svg|ico)$ { location ~* \.(jpg|jpeg|gif|png|svg|ico)$ {
access_log off; access_log off;
expires max; expires max;
log_not_found off; log_not_found off;
error_page 404 = /empty; error_page 404 = /empty;
#location ~ ^/\d*.jpg$ {
# default_type 'image/jpeg';
# content_by_lua_file image.lua;
#}
} }
#location ~ ^/\d*.html$ {
# rewrite_by_lua_file redirect_to_product.lua;
#}
location = /empty { location = /empty {
expires 0; expires 0;
empty_gif; empty_gif;
@ -21,12 +13,12 @@ location ~* \.(eot|ttf|woff|pdf|css|js)$ {
access_log off; access_log off;
expires max; expires max;
} }
#location ~* \.(xml|xls)$ { location ~* \.(xml|xls)$ {
# add_header Cache-Control "no-cache"; add_header Cache-Control "no-cache";
#} }
location ~ /\. { location ~ /\. {
deny all; deny all;
} }
location ~* \.(tpl|ini|sh) { location ~* \.(tpl|ini|sh|conf|example) {
deny all; deny all;
} }