# redirect http to https without wildcards server { listen 80; server_name ~^.*\.johnbintz.com$; return 301 https://johnbintz.com$request_uri; } # serve subdomainless from sandstorm server { listen 443 ssl; # let's encrypt certificates go here server_name ~^johnbintz.com$; location / { proxy_set_header Host johnbintz.com; proxy_pass https://the-sandcats-url-sandstorm-static-publishing-gives-you; proxy_intercept_errors on; error_page 404 /404/; } }