delete unused nginx configuration templates (#58346)

This commit is contained in:
Emmanuel Cazenave 2023-03-14 15:46:44 +01:00
parent ae04037004
commit 5c3db6a691
2 changed files with 0 additions and 55 deletions

View File

@ -1,12 +0,0 @@
{% extends "base-nginx-server.j2" %}
{% block middle %}
location ~ ^/static/(.+)$ {
root /;
try_files {{tenants_dir}}/$host/static/$1
{{tenants_dir}}/$host/theme/static/$1
{{state_dir}}/collectstatic/$1
=404;
add_header Access-Control-Allow-Origin *;
}
{% endblock %}

View File

@ -1,43 +0,0 @@
server {
listen 443 ssl;
server_name {{nginx_host_pattern}};
ssl_certificate {{ssl_certificate}};
ssl_certificate_key {{ssl_certificate_key}};
access_log {{nginx_log_base}}-access.log combined;
error_log {{nginx_log_base}}-error.log;
location ~ ^/static/(.+)$ {
root /;
try_files {{tenants_dir}}/$host/static/$1
{{tenants_dir}}/$host/theme/static/$1
{{state_dir}}/collectstatic/$1
=404;
add_header Access-Control-Allow-Origin *;
add_header 'Service-Worker-Allowed' '/';
}
location ~ ^/media/(.+)$ {
alias {{tenants_dir}}/$host/media/$1;
}
location / {
proxy_pass http://127.0.0.1:{{server_port}};
proxy_set_header Host $http_host;
proxy_set_header X-Forwarded-SSL on;
proxy_set_header X-Forwarded-Protocol ssl;
proxy_set_header X-Forwarded-Proto https;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}
}
# catchall http → https
server {
listen 80;
server_name {{nginx_host_pattern}};
access_log {{nginx_log_base}}-access.log combined;
error_log {{nginx_log_base}}-error.log;
return 301 https://$host$request_uri;
}