Help needed for setting up Cloudflare tunnel in DSM7 (400 Bad Request)🥲

Hello,

I’ve been working on this issue the whole day but still can’t figure it out.
My HA is installed within DSM7 via docker.

I am getting 400 Bad Request when accessing the HA domain after setting up Cloudflare following this vid “https://www.youtube.com/watch?v=xXAwT9N-7Hw&t=546s” and also using this add-on “https://github.com/brenner-tobias/addon-cloudflared/blob/a3ad8795c5799570b556b5f381ed7c3c924448b2/cloudflared/DOCS.md”

Inside the add-on


and I can see the log successful to connected

[01:32:10] INFO: Finished setting up the Cloudflare Tunnel
[01:32:10] INFO: Connecting Cloudflare Tunnel...

and inside configuration.yaml I added all cloudflare ip range (IP Ranges) alongside my docker ip following this (Home assistant (400 Bad Request) Docker + Proxy - Solution)

added the ip from HA log

The IP from docker

but still getting 400 Bad Request
Here’s my configuration.yaml

http:
  use_x_forwarded_for: true
  trusted_proxies:
    - 172.30.33.0/24
    - 103.21.244.0/22
    - 103.22.200.0/22
    - 103.31.4.0/22
    - 104.16.0.0/13
    - 104.24.0.0/14
    - 108.162.192.0/18
    - 131.0.72.0/22
    - 141.101.64.0/18
    - 162.158.0.0/15
    - 172.64.0.0/13
    - 173.245.48.0/20
    - 188.114.96.0/20
    - 190.93.240.0/20
    - 197.234.240.0/22
    - 198.41.128.0/17
    - 170.30.32.2
    - 172.30.33.1
    - 172.17.0.0/16
    - 172.30.32.0/23
    - 172.30.32.1
    - 172.18.0.0/16
    - 172.18.0.1
    - 172.18.0.2/16
    - 172.30.32.0/23
    - 127.0.0.1
    - 10.0.0.2

# Loads default set of integrations. Do not remove.
default_config:

# Load frontend themes from the themes folder
frontend:
  themes: !include_dir_merge_named themes

automation: !include automations.yaml
script: !include scripts.yaml
scene: !include scenes.yaml

Am I missing something or anything else I could try?
Thanks in advance

I’m same boat as yours… helps needed.

Hey guys, I hope you’re both doing well, I also came across the same issue, seems that subnet CIDR notation is an issue with this, at least for me.

I’m running HA in docker compose on one of my raspberry pi’s, tunnelled through cloudflare, I found that if you remove all the subnet declarations and leave just the IPs, it works out.

I reckon a bug should be logged for this, unless we’re all missing something, lol