Hi, I am running HAOS on Proxmox with Cloudflare configured for remote access via tunnel. I can access the HA console using the configured remote URL https://ha.mysite.com however I am only able to access /local files locally using http://192.168.1.20/local/picture.jpg and not remotely using https://ha.mysite.com/local/picture.jpg.
I see no events in Cloudflare’s tunnel log stream when trying to get the file but I do see the event if I browse to https://ha.mysite.com/local. In this case the expected 403 error as there is no sharing of the folder at the webserver end.
I have tried opening up the permissions on the files in the www folder to no avail. There are no firewall policies in place for the Cloudflare tunnel.
Any ideas please.
What settings do you have for http:
settings in your HA config file?
http:
use_x_forwarded_for: true
trusted_proxies:
I have no issues accessing my local pics using https://ha.mysite.com/local/picture.jpg
Hi LiQuid_cOOled,
My configuration.yaml file reads:
http:
use_x_forwarded_for: true
trusted_proxies:
- 172.30.33.0/24
Do you have a file editor installed and are you able to access the files via your remote URL?
I spent some time this evening trying to break my Cloudfare Tunnel’s access to local files and was unsuccessful.
I had this working on my old system so I went back and examined the configuration.yaml file from an old backup.
Adding the lines:
homeassistant:
allowlist_external_dirs:
- ‘/config/www’
to the new build resolved this issue. I am now able to access the /local share remotely over Cloudflare.
Thanks for your time. I appreciate you tried the help.
I do not have that in my config, but if it works it works.