updated nginx state
This commit is contained in:
parent
ced07392af
commit
25e21f2042
@ -58,6 +58,7 @@ nginx-sites-available-{{ key }}:
|
||||
root_dir: {{ vhost.root_dir|default(None) }}
|
||||
internal_access: {{ vhost.internal_access|default(false) }}
|
||||
dirs: {{ vhost.dirs|default([]) }}
|
||||
php_socket_file: {{ nginx.config.php_socket_file }}
|
||||
|
||||
nginx-site-enabled-{{ key }}:
|
||||
file.symlink:
|
||||
|
@ -4,7 +4,7 @@ ssl_certificate /etc/acme/certs/paulbsd.com.cert;
|
||||
ssl_certificate_key /etc/acme/keys/paulbsd.com.key;
|
||||
ssl_session_timeout 5m;
|
||||
#ssl_protocols SSLv2 SSLv3 TLSv1 TLSv1.1 TLSv1.2;
|
||||
ssl_protocols TLSv1.2;
|
||||
ssl_protocols TLSv1.3 TLSv1.2;
|
||||
#ssl_ciphers HIGH:!aNULL:!MD5;
|
||||
#ssl_ciphers ECDHE-RSA-AES256-GCM-SHA512:DHE-RSA-AES256-GCM-SHA512:ECDHE-RSA-AES256-GCM-SHA384:DHE-RSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-SHA384;
|
||||
ssl_ciphers EECDH+AESGCM:EECDH+CHACHA20;
|
||||
@ -20,4 +20,4 @@ resolver_timeout 5s;
|
||||
add_header Strict-Transport-Security "max-age=63072000; includeSubDomains; preload";
|
||||
add_header X-Frame-Options DENY;
|
||||
add_header X-Content-Type-Options nosniff;
|
||||
add_header X-XSS-Protection "1; mode=block";
|
||||
add_header X-XSS-Protection "1; mode=block";
|
||||
|
@ -1,20 +1,20 @@
|
||||
## {{ salt['pillar.get']('salt_managed', default='Salt Managed') }}
|
||||
|
||||
server {
|
||||
include http;
|
||||
server_name {{ vhost_name }};
|
||||
return 301 https://$server_name$request_uri;
|
||||
include http;
|
||||
server_name {{ vhost_name }};
|
||||
return 301 https://$server_name$request_uri;
|
||||
}
|
||||
|
||||
server {
|
||||
include https;
|
||||
server_name {{ vhost_name }};
|
||||
root {{ root_dir }};
|
||||
include https;
|
||||
server_name {{ vhost_name }};
|
||||
root {{ root_dir }};
|
||||
|
||||
index index.php index.html;
|
||||
index index.php index.html;
|
||||
|
||||
location ~ /(conf|bin|inc)/ {
|
||||
deny all;
|
||||
deny all;
|
||||
}
|
||||
|
||||
location ~ /data/ {
|
||||
|
@ -1,15 +1,15 @@
|
||||
## {{ salt['pillar.get']('salt_managed', default='Salt Managed') }}
|
||||
|
||||
server {
|
||||
include http;
|
||||
server_name {{ vhost_name }};
|
||||
return 301 https://$server_name$request_uri;
|
||||
include http;
|
||||
server_name {{ vhost_name }};
|
||||
return 301 https://$server_name$request_uri;
|
||||
}
|
||||
|
||||
server {
|
||||
include https;
|
||||
server_name {{ vhost_name }};
|
||||
root {{ root_dir }};
|
||||
include https;
|
||||
server_name {{ vhost_name }};
|
||||
root {{ root_dir }};
|
||||
|
||||
index index.php;
|
||||
error_page 403 /core/templates/403.php;
|
||||
|
@ -1,20 +1,20 @@
|
||||
## {{ salt['pillar.get']('salt_managed', default='Salt Managed') }}
|
||||
|
||||
server {
|
||||
include http;
|
||||
server_name {{ vhost_name }};
|
||||
return 301 https://$server_name$request_uri;
|
||||
include http;
|
||||
server_name {{ vhost_name }};
|
||||
return 301 https://$server_name$request_uri;
|
||||
}
|
||||
|
||||
server {
|
||||
include https;
|
||||
server_name {{ vhost_name }};
|
||||
root {{ root_dir }};
|
||||
include https;
|
||||
server_name {{ vhost_name }};
|
||||
root {{ root_dir }};
|
||||
|
||||
index index.php index.html;
|
||||
index index.php index.html;
|
||||
|
||||
location ~ /(conf|bin|inc)/ {
|
||||
deny all;
|
||||
deny all;
|
||||
}
|
||||
|
||||
location ~ /data/ {
|
||||
@ -23,7 +23,7 @@ server {
|
||||
|
||||
location ~ \.php?$ {
|
||||
include fastcgi_params;
|
||||
fastcgi_pass unix:{{ nginx.config.php_socket_file }};
|
||||
fastcgi_pass unix:{{ php_socket_file }};
|
||||
fastcgi_index index.php;
|
||||
fastcgi_param SCRIPT_FILENAME $document_root/$fastcgi_script_name;
|
||||
}
|
||||
|
@ -1,34 +1,34 @@
|
||||
## {{ salt['pillar.get']('salt_managed', default='Salt Managed') }}
|
||||
|
||||
server {
|
||||
include http;
|
||||
server_name {{ vhost_name }};
|
||||
return 301 https://$server_name$request_uri;
|
||||
include http;
|
||||
server_name {{ vhost_name }};
|
||||
return 301 https://$server_name$request_uri;
|
||||
}
|
||||
|
||||
server {
|
||||
include https;
|
||||
server_name {{ vhost_name }};
|
||||
include https;
|
||||
server_name {{ vhost_name }};
|
||||
{%- if not proxy %}
|
||||
root {{ root_dir }};
|
||||
root {{ root_dir }};
|
||||
{%- endif %}
|
||||
location / {
|
||||
{%- if proxy %}
|
||||
proxy_pass {{ proxy_pass }};
|
||||
proxy_pass {{ proxy_pass }};
|
||||
{%- if not cache %}
|
||||
proxy_no_cache 1;
|
||||
proxy_cache_bypass 1;
|
||||
proxy_no_cache 1;
|
||||
proxy_cache_bypass 1;
|
||||
{%- endif %}
|
||||
{%- endif %}
|
||||
{%- if autoindex %}
|
||||
autoindex on;
|
||||
autoindex_localtime on;
|
||||
autoindex on;
|
||||
autoindex_localtime on;
|
||||
{%- endif %}
|
||||
}
|
||||
|
||||
{%- for dir in dirs %}
|
||||
location {{ dir.name }} {
|
||||
alias {{ dir.alias }};
|
||||
alias {{ dir.alias }};
|
||||
}
|
||||
{%- endfor %}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user