Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Determine home network based on whether url can be reached #5034

Open
tag6 opened this issue Feb 6, 2025 · 0 comments
Open

Determine home network based on whether url can be reached #5034

tag6 opened this issue Feb 6, 2025 · 0 comments
Labels
enhancement New feature or request

Comments

@tag6
Copy link

tag6 commented Feb 6, 2025

Is your feature request related to a problem? Please describe.

The current detection of external or internal URL usage is not appropriate to the problem. As a user of DNS66 I'm always using a VPN. But if I change VPN to WireGuard, I'm virtually in my home network. I'm not using an ethernet adapter (although I have one in the drawer), but if I would, I'd do that as well as home as somewhere else where I'm not at home. So both criteria do not really help to tell if internal URL usage is possible. You even may come to a place where the public WLAN is named like your home WLAN!

The current logic does not help me, but it also does not seem to be anywhere near a logic and general solution. It gets more and more complicate, without solving things.

See also
https://community.home-assistant.io/t/wth-does-the-app-not-connect-internally-if-vpn-is-being-used/815767/2

Describe the solution you'd like

There is no reason to check hardware, Ethernet, WLAN, anything to decide if internal or external URL is to be used.
Easy logic:

  1. It is stored what is the "current connection" (internal or external)
  2. On any network change (IR, Bluetooth, WLAN, Ethernet/USB whatever) it is to be checked if the internal URL is reachable. The result determines the new "current connection". From that moment all traffic goes there.

Result: The companion app shall not manage connections. The OS is responsible to route your network packets to the interface it decides. The name of the WLAN, if network traffic is managed via WLAN, VPN, IR, Bluetooth - please don't care! Only check if and how HA is reachable. This is all the companion app should need to know for maximum comfort of the users.

Describe alternatives you've considered, if any

Currently I'm not using Home Assistant with internal URL when not at home but using VPN. I'd like to change that, but the current situation is fine also. But please stop unnecessarily complicating things.

Additional context

@tag6 tag6 added the enhancement New feature or request label Feb 6, 2025
@jpelgrom jpelgrom changed the title Change treatment of Wifi connection Determine home network based on whether url can be reached Feb 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant