# ------------------------------------------------------------ # Default Site # ------------------------------------------------------------ {% if value == "congratulations" %} # Skipping output, congratulations page configuration is baked in. {%- else %} server { {% if enable_proxy_protocol == 1 or enable_proxy_protocol == true%} listen 88 proxy_protocol; {% if ipv6 -%} listen [::]:88 proxy_protocol; {% endif %} {% else -%} listen 80 default; {% if ipv6 -%} listen [::]:80 default; {% endif %} {% endif %} server_name default-host.localhost; access_log /data/logs/default-host_access.log combined; error_log /data/logs/default-host_error.log warn; {% include "_exploits.conf" %} {% include "_proxy_protocol.conf"} include conf.d/include/letsencrypt-acme-challenge.conf; {%- if value == "404" %} location / { return 404; } {% endif %} {%- if value == "redirect" %} location / { return 301 {{ meta.redirect }}; } {%- endif %} {%- if value == "html" %} root /data/nginx/default_www; location / { try_files $uri /index.html; } {%- endif %} } {% endif %}