server { listen 80; server_name cloud.teier.eu; return 301 https://cloud.teier.net:443$request_uri; } server { listen 443 ssl http2; server_name cloud.teier.eu; ssl on; ssl_certificate /etc/letsencrypt/live/teier.eu/fullchain.pem; ssl_certificate_key /etc/letsencrypt/live/teier.eu/privkey.pem; return 301 https://cloud.teier.net:443$request_uri; }