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; } }