cstate #29
1 changed files with 22 additions and 0 deletions
22
templates/etc/nginx/sites-available/cstate.j2
Normal file
22
templates/etc/nginx/sites-available/cstate.j2
Normal file
|
@ -0,0 +1,22 @@
|
|||
{% extends "core.j2" %}
|
||||
|
||||
{% block root %}
|
||||
root {{ item.root }};
|
||||
index {{ item.index }};
|
||||
{% endblock %}
|
||||
|
||||
{% block location %}
|
||||
|
||||
## LOCATIONS
|
||||
location / {
|
||||
# Add cache for static files
|
||||
if ($request_uri ~* ^/(img|css|font|js)/) {
|
||||
add_header Expires "Thu, 31 Dec 2037 23:55:55 GMT";
|
||||
add_header Cache-Control "public, max-age=315360000";
|
||||
}
|
||||
|
||||
# HTTPS only header, improves security
|
||||
add_header Strict-Transport-Security "max-age=15768000";
|
||||
|
||||
}
|
||||
{% endblock %}
|
Loading…
Reference in a new issue