Allow setting up a persistent static route with ha network command

I am trying to create a persistent static route to allow access to HA from my VPN, but I can’t find any viable way to do that using official built-in tools.

I have found that a few years ago it was possible to set up a persistent static route using nmcli, but that functionality has since been broken with 2022.4 update.

Some other users were also having trouble with nmcli and they reported their issues on Github. Recently, in response to said issues, the nmcli was removed from the SSH add-on, stating that the “Correct way to handle network configuration in HA OS is to use ha network command set”.

The problem is that ha network command appears to be very basic, and it doesn’t seem to allow to define any routes, persistent or not.

I know there are workaround solutions. I could add a static route to my router’s routing table, but my ISP doesn’t allow that. I could also create a script setting up a route on startup, but I don’t find it very elegant.

Some people are accessing their HAs through a VPN, and I think there should be an easy way to set up routes from the cli or the dashboard.

nmcli is present in the advanced ssh and terminal addon.

The second link in my original post directs to the pull request for the Advanced SSH and Web Terminal add-on, which states:

Using nmcli from the SSH add-on is an unsupported way of adjusting network configuration in HA OS, and the mismatch of versions of the NetworkManager in the OS and nmcli in the add-on leads to errors that even make it impossible to use it. Having nmcli bundled in the SSH terminal add-on (even the unofficial one) makes users think this is somehow the correct and supported way of configuring advanced networking features.

Remove the package from the default set of installed software. Correct way to handle network configuration in HA OS is to use ha network command set, and if there’s any functionality missing, open feature requests for that.

I know that nmcli is still present in the version of the add-on available in Add-on Store, but it has been broken for at least two years, which is why it is being removed from future versions of the add-on.

No it doesn’t. It points to the ssh addon, not the advanced ssh addon.

Sorry you were right, that is the advanced ssh addon.