I have a self-hosted Ghost instance running in a docker container on a Raspberry Pi and connected to the internet using a Cloudflare Tunnel (I followed this tutorial).
Everything works great, except when I upload a custom publication icon, it isn’t shown in the browser tab. In Firefox, there is no icon at all, just text, and in Chrome, there is only the default icon.
I noticed in Chrome that the icon’s URL in the head HTML is:
I’m not sure if this is how it should be, but if I change the URL to http:// (rather than https://) then the custom icon appears as it should. So, I’m wondering if it’s maybe a problem with Cloudflare.
Either way, I figured I could just replace the default file instead, which works on a locally installed Ghost instance on my laptop. However, I can’t find the same file on the Docker version.
Any ideas on how to fix this, or where to find the default file on Docker would be great! :)
Thanks Cathy - it’s set to http (the same as the service for my Cloudflare Tunnel), and the local network address of the machine running Ghost. That’s the only way I was able to see my site via it’s domain address (blog.pauljerem.com).
I’ve tried changing the URL in the compose file to https and then changing the tunnel service on Cloudflare to match. But then, when I try to access the site via the domain address I just get Bad Gateway errors (502, I think).
I think the main thing here is the url value in the compose file. Ghost expects that to be the public URL people actually use to access the site, so in your case it should be the public https://... domain rather than http://192.168.0.100:2368.
The Cloudflare Tunnel origin is a separate setting. I’d leave that as HTTP to port 2368 if that’s what Ghost is listening on. Ghost doesn’t need to handle TLS itself just because the public site uses HTTPS.
If the 502 appeared after you also changed the Tunnel origin to HTTPS, I’d switch that part back to HTTP and keep only Ghost’s public url set to HTTPS. It might also be worth checking that the public Host and X-Forwarded-Proto: https are reaching Ghost as expected.
I wouldn’t replace the favicon file itself. Since some of the post images are also ending up with the private 192.168... address, it looks more like the public URL/proxy configuration is the actual issue.