include order fixes

This commit is contained in:
Szekeres Bálint
2018-01-10 16:08:38 +01:00
parent ccdd4ec318
commit 3e55b6cd97
6 changed files with 20 additions and 14 deletions

View File

@@ -6,7 +6,7 @@ add_header X-UA-Compatible "IE=Edge" always;
add_header Cache-Control "no-transform" always;
# . files
location ~ /\.(?!well-known).* {
location ~ /\. {
deny all;
}<span ng-if="data.expires_assets !== '' && data.expires_assets !== data.expires_media">

View File

@@ -1,3 +1,4 @@
# ACME-challenge
location ^~ /.well-known/acme-challenge/ {
default_type "text/plain";
root /var/www/_letsencrypt;

View File

@@ -16,7 +16,6 @@ ssl_prefer_server_ciphers on;
add_header Strict-Transport-Security "max-age=15768000" always;
# OCSP Stapling
# fetch OCSP records from URL in ssl_certificate and cache them
ssl_stapling on;
ssl_stapling_verify on;

View File

@@ -15,21 +15,20 @@ server {
location / {
try_files $uri $uri/ {{ data.index_html ? '/index.html' : '' }}{{ data.index_html && data.php !== 'off' && data.index_php ? ' ' : '' }}{{ data.php !== 'off' && data.index_php ? '/index.php?$query_string' : '' }};
}</span>
<span ng-if="data.file_structure === 'separated'">
include _ssl.conf;<span ng-if="data.file_structure === 'separated'">
include _letsencrypt.conf;
include _general.conf;<span ng-if="data.php !== 'off' && data.wordpress">
include _wordpress.conf;</span><span ng-if="data.php !== 'off'">
include _php.conf;</span>
include _letsencrypt.conf;
include _ssl.conf;</span><span ng-if="data.file_structure === 'unified'">
include _php.conf;</span></span><span ng-if="data.file_structure === 'unified'">
<ng-include ng-include-tabs="2" src="'templates/_letsencrypt.conf.html'" onload="refreshHighlighting()"></ng-include>
<ng-include ng-include-tabs="2" src="'templates/_general.conf.html'" onload="refreshHighlighting()"></ng-include><span ng-if="data.php !== 'off' && data.wordpress">
<ng-include ng-include-tabs="2" src="'templates/_wordpress.conf.html'" onload="refreshHighlighting()"></ng-include></span><span ng-if="data.php !== 'off'">
<ng-include ng-include-tabs="2" src="'templates/_php.conf.html'" onload="refreshHighlighting()"></ng-include></span>
<ng-include ng-include-tabs="2" src="'templates/_letsencrypt.conf.html'" onload="refreshHighlighting()"></ng-include></span><span ng-if="data.file_structure === 'unified'">
include _ssl.conf;</span>
<ng-include ng-include-tabs="2" src="'templates/_php.conf.html'" onload="refreshHighlighting()"></ng-include></span></span>
}<span ng-if="data.cdn">
# CDN
@@ -53,7 +52,10 @@ server {
gzip_comp_level 6;
gzip_types {{ gzipTypes }};</span>
include _ssl.conf;
include _ssl.conf;<span ng-if="data.file_structure === 'separated'">
include _letsencrypt.conf;</span><span ng-if="data.file_structure === 'unified'">
<ng-include ng-include-tabs="2" src="'templates/_letsencrypt.conf.html'" onload="refreshHighlighting()"></ng-include></span>
location ~* \.(?:{{ extensions.assets }}|{{ extensions.fonts }}|{{ extensions.svg }}|{{ extensions.images }}|{{ extensions.audio }}|{{ extensions.video }}|{{ extensions.docs }})$ {
add_header Access-Control-Allow-Origin "*";
@@ -77,7 +79,10 @@ server {
ssl_certificate_key /etc/letsencrypt/live/{{ data.domain }}/privkey.pem;
ssl_trusted_certificate /etc/letsencrypt/live/{{ data.domain }}/fullchain.pem;
include _ssl.conf;
include _ssl.conf;<span ng-if="data.file_structure === 'separated'">
include _letsencrypt.conf;</span><span ng-if="data.file_structure === 'unified'">
<ng-include ng-include-tabs="2" src="'templates/_letsencrypt.conf.html'" onload="refreshHighlighting()"></ng-include></span>
return 301 https://{{ !data.non_www ? 'www.' : '' }}{{ data.domain }}$request_uri;
}

View File

@@ -37,5 +37,6 @@ http {
include /etc/nginx/conf.d/*.conf;<span ng-if="data.file_structure === 'separated'">
include /etc/nginx/sites-enabled/*;</span><span ng-if="data.file_structure === 'unified'">
# {{ !data.non_www ? 'www.' : '' }}{{ data.domain }}
<ng-include ng-include-tabs="1" src="'templates/example.com.conf.html'" sonload="refreshHighlighting()"></ng-include></span>
}