pyinfra-nginx/pyinfra_nginx/webroot.nginx_config.j2
hagi f289afbbef Add webroot param to add_nginx_domain (#70)
* add webroot param to add_nginx_domain

* add slash to webroot param docstring

Co-authored-by: missytake <missytake@systemli.org>

* make webroot notrequire proxyport

Co-authored-by: missytake <missytake@systemli.org>

* fix nginx template for webroot param

Co-authored-by: missytake <missytake@systemli.org>

* remove unneeded lines from webroot nginx config

* rename webroot jinja template

---------

Co-authored-by: missytake <missytake@systemli.org>
2024-04-24 12:44:16 +02:00

14 lines
361 B
Django/Jinja

server {
server_name {{ domain }};
root {{ webroot }};
location / {
try_files $uri $uri/ $uri.html =404;
}
listen [::]:443 ssl http2;
listen 443 ssl http2;
ssl_certificate /var/lib/acme/live/{{ domain }}/fullchain; # managed by acmetool
ssl_certificate_key /var/lib/acme/live/{{ domain }}/privkey; # managed by acmetool
}