If you use a custom host and your domain shows a 502 Bad Gateway error when you try to access it over HTTPS, then you will need to make sure that your domain, in your custom host, has SSL installed as well. A self-signed certificate will work just fine.
This error is because our service uses end-to-end encryption, which means that all traffic is encrypted from the IP node down to the webserver.