ansible-role-lstu/templates/nginx-rp-site.j2

19 lines
658 B
Text
Raw Normal View History

2022-12-10 15:02:35 +01:00
server {
listen 80;
server_name {{ lstu.domain }};
include snippets/letsencrypt.conf;
location / { return 301 https://$http_host$request_uri; }
}
server {
listen 443 ssl http2;
server_name {{ lstu.domain }};
ssl_certificate /var/lib/dehydrated/certs/{{ lstu.domain }}/fullchain.pem;
ssl_certificate_key /var/lib/dehydrated/certs/{{ lstu.domain }}/privkey.pem;
include /etc/nginx/snippets/add_headers.conf;
include /etc/nginx/snippets/proxy-transfer.conf;
include /etc/nginx/snippets/lstu.conf;
location = /robots.txt { root /data/lstu/; }
location / { proxy_pass http://{{ inventory_hostname }}:8080; }
}