502 Bad Gateway only when visiting via HTTPS

I have a very weird issue with my site
For this URL: http://receiver.n7dmr.radio/kiwisdr.min.js and most resources on this site, it works fine when visiting via http but I will get a 502 Bad gateway error when I visits them via HTTPS.
This site is proxied via Cloudflared Tunnel. The original server doesn’t have https support. The log from the server seem like normal and that it has served the content to Cloudflared daemon. And I don’t see any errors on Cloudflared log.
I even tried using an NGINX reverse proxy between cloudflare tunnel and the application. It didn’t make any difference. I could clearly see NGINX serving the content with HTTP 200 but still getting 502 error on Cloudflare.

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.