28 lines
727 B
Django/Jinja
28 lines
727 B
Django/Jinja
# distributed with ansible
|
|
|
|
server {
|
|
listen 443 ssl;
|
|
{% if inventory_hostname in wg_clients -%}
|
|
listen {{ wg_clients[inventory_hostname].ip }}:443 ssl http2;
|
|
{% endif -%}
|
|
# listen [::]:443 ssl;
|
|
|
|
include listen-proxy-protocol.conf;
|
|
server_name {{ apt_url }};
|
|
root /var/www/{{ apt_url }};
|
|
|
|
location / {
|
|
index index.html index.htm;
|
|
autoindex on;
|
|
autoindex_exact_size off;
|
|
}
|
|
|
|
access_log /var/log/nginx/access_{{ apt_url }}.log main;
|
|
error_log /var/log/nginx/error_{{ apt_url }}.log;
|
|
|
|
ssl_session_timeout 5m;
|
|
|
|
ssl_certificate /usr/local/etc/certs/{{ apt_url }}/fullchain.pem;
|
|
ssl_certificate_key /usr/local/etc/certs/{{ apt_url }}/privkey.pem;
|
|
}
|