Giter Site home page Giter Site logo

hassio-addons / addon-zerotier Goto Github PK

View Code? Open in Web Editor NEW
131.0 6.0 12.0 422 KB

ZeroTier One - Home Assistant Community Add-ons

Home Page: https://addons.community

License: MIT License

Dockerfile 41.82% Jinja 58.18%
zerotier vpn peer-to-peer networking home-assistant homeassistant addon addons

addon-zerotier's Introduction

Home Assistant Community Add-on: ZeroTier One

GitHub Release Project Stage License

Supports aarch64 Architecture Supports amd64 Architecture Supports armhf Architecture Supports armv7 Architecture Supports i386 Architecture

Github Actions Project Maintenance GitHub Activity

Discord Community Forum

Sponsor Frenck via GitHub Sponsors

Support Frenck on Patreon

Radically simplify your network with a virtual networking layer that works the same everywhere.

About

ZeroTier delivers the capabilities of VPNs, SDN, and SD-WAN with a single system. Manage all your connected resources across both local and wide area networks as if the whole world is a single data center.

People use ZeroTier to seamlessly connect laptops, desktops, phones, embedded devices, cloud resources, and apps any way they want anywhere they go. It transforms the entire world into a single data center, to which you can now add your Home Assistant instance using this add-on.

๐Ÿ“š Read the full add-on documentation

Support

Got questions?

You have several options to get them answered:

You could also open an issue here GitHub.

Contributing

This is an active open-source project. We are always open to people who want to use the code or contribute to it.

We have set up a separate document containing our contribution guidelines.

Thank you for being involved! ๐Ÿ˜

Authors & contributors

The original setup of this repository is by Franck Nijhof.

For a full list of all authors and contributors, check the contributor's page.

We have got some Home Assistant add-ons for you

Want some more functionality to your Home Assistant instance?

We have created multiple add-ons for Home Assistant. For a full list, check out our GitHub Repository.

License

MIT License

Copyright (c) 2019-2024 Franck Nijhof

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

addon-zerotier's People

Contributors

dependabot[bot] avatar frenck avatar liju09 avatar renovate[bot] avatar timmo001 avatar wrt54g avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

addon-zerotier's Issues

mDNS / avahi / bonjour resolving of `homeassistant.local` does not work over zerotier

Problem/Motivation

I want to access my homeassistant instance via homeassistant.local.

Expected behavior

Any device from within the zerotier network that the HAOS VM is joined into can resolve homeassistant.local

Actual behavior

My HAOS instance is accessed using the homeassistant.local domain, which is resolved via mDNS. This works fine from the local network connected to HAOS, i.e. via mDNS I can resolve homeassistant.local. However, from the zerotier network, I can not resolve homeassistant.local at all. Resolving other devices within the zerotier network using mDNS does work just fine.

Steps to reproduce

  1. Install HAOS
  2. Add the zerotier add-on
  3. Join a zerotier network
  4. Resolve homeassistant.local from the local network of HAOS (should work)
  5. Resolve homeassistant.local from the zerotier network (should not work)

Proposed changes

Make sure that avahi (or whichever mDNS advertiser is used in HAOS) advertises as well in the zerotier network.

Mobile app can't connect after last update of add-on

Problem/Motivation

(Why the issue was filed)

Expected behavior

(What you expected to happen)

Actual behavior

(What actually happened)

Steps to reproduce

(How can someone else make/see it happen)

Proposed changes

(If you have a proposed change, workaround or fix,
describe the rationale behind it)

"connect: Connection refused"

Problem/Motivation

Just started using hass.io, tried the zerotier add-on. I think i've followed the steps, but the logs say "connection refused", even after a restart.

Expected behavior

no errors indicating it doesn't work

Actual behavior

"connection refused" in logs

Steps to reproduce

I've uninstalled the add-on, installed it again ... same result.

Proposed changes

(If you have a proposed change, workaround or fix,
describe the rationale behind it)

Info from the log:

Hass.io Add-on: ZeroTier One
Radically simplify your network with a virtual networking layer that works the same everywhere

Add-on version: 0.5.1
You are running the latest version of this add-on.
System: HassOS 3.7 (armv7 / raspberrypi4)
Home Assistant version: 0.103.4
Supervisor version: 193

Please, share the above information when looking for help
or support in, e.g., GitHub, forums or the Discord chat.

[cont-init.d] 00-banner.sh: exited 0.
[cont-init.d] 01-log-level.sh: executing...
[cont-init.d] 01-log-level.sh: exited 0.
[cont-init.d] zerotier.sh: executing...
[22:56:14] INFO: ZeroTier node address: <deleted assuming i shouldn't share this>
[22:56:15] INFO: Configuring network: <deleted assuming i shouldn't share this>
[cont-init.d] zerotier.sh: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
[22:56:15] INFO: Starting ZeroTier One...
connect: Connection refused
connect: Connection refused
connect: Connection refused
connect: Connection refused

Accessing local network over ZeroTier add-on not possible.....

Problem/Motivation

I have been utilizing ZeroTier in quite a few environments, and one thing I do on all of my anchoring points in a network (the device that I install in a client's network) is set up the networking on the device to allow me to access their network and its resources while connected via ZeroTier. I am putting this Add-on on my home assistant which is installed in my travel trailer. My travel trailer has a full time internet via Starlink (flat mounted on roof) and cellular backup.

Expected behavior

I expected to be able to modify the networking parameters of my end point like it is described here: https://zerotier.atlassian.net/wiki/spaces/SD/pages/224395274/Route+between+ZeroTier+and+Physical+Networks

Actual behavior

At present, I cannot seem to find on the terminal where this ZeroTier install is interacting with the local device to make the noted changes for IP Forwarding to/from ZeroTier and remote client

Steps to reproduce

(How can someone else make/see it happen)

Proposed changes

The way I see it, this could be done relatively easy from the coding stand-point, as an optional switched item to allow local network access via ZeroTier.

automation does not work / hmip / nuki

Hello dear community,

Iโ€™m new to the home assistant story and I need your help right away.

I have created an automation system that, when I switch on my hmip alarm system, should also lock my nuki front door lock at the same time.

However, the automation does not work as intended.

If I lock the nuki, for example using a lamp, the lock works perfectly.

The nuki lock works perfectly in all, but not with the automation of the arming of the alarm system.

Who maybe has a solution?

Screenshot_2020-10-03-10-49-27-793_io homeassistant companion android
Screenshot_2020-10-03-10-49-33-906_io homeassistant companion android

can I use my 'panlet' file?

I created a zerotier-one server and generated the 'planet' file, but I can't use it here.
Can you map the zerotier 'planet' configuration information to the homeassistant directory under config?
Thank you very much.

How to reset or force the ZT node address?

Problem/Motivation

After addon installation or re-installation, my ZT console doesn't show my server node address. I suspect it is a deleted node, so ZT has somehow blacklisted it.

Expected behavior

Reset the randomly generated ZT node address after addon re-installation.

Actual behavior

Deleting and reinstalling the addon the node address remains the same.

Steps to reproduce

Look at the addon log after re-installing it.

Proposed changes

It may be useful also to be able to force the ZT node address in the addon config.

No network connectivity / ping

Problem/Motivation

Zerotier one stopped working from my nginx cloud machine. Updated, then also no use.

Expected behavior

Hassio should be pingable

Actual behavior

there were frequent disconnectins / machine not reachable for some time. this evening, its just dead.

Steps to reproduce

  1. tried reinsalling the addon, rejoining,
  2. also added mobile to same network. Can ping nginx and mobile from each other.
  3. Mobile is occasionally able to ping hassio, but never from GCP vm.

Proposed changes

(If you have a proposed change, workaround or fix,
describe the rationale behind it)

Upgrading to current ZeroTier release

There seems to be a set of newer features that require at least ZeroTier 1.6.0... are you game to update things? I'm happy to send a PR if you want to point me in the right direction.

Error message - not a valid value for dictionary value

I created a free account and set the "Internal ID" in the "network ID" field of the add-on as well as the API token and when I press save I get the following error:

not a valid value for dictionary value @ data['options']. Got {'network_id': 'xxxxxxxxx', 'port': 9993, 'api_auth_token': 'xxxxxxxxx'}

Am I missing something here? Is the Network ID the same as the "Internal ID" on the ZeroTier account page?

Connection regularly drops, restarting addon fixes every time

Problem/Motivation

I have ZeroTier setup so that HA can talk to a remote Raspberry Pi. It works for a while and then seems to randomly stop working. After much testing, it seems the issue is on the HA end as the one things that resolves the issue every time is restarting the addon. Diagnostically, connectivity works between all nodes on the ZeroTier network except from HA.

Expected behavior

The connection remains up and stable.

Actual behavior

Connection drops regularly.

Steps to reproduce

  • Setup addon
  • setup Pi with Raspberry Pi OS Lite + ZeroTier 1 from their website

Proposed changes

No idea to what extent this would help, but this addon uses ZeroTier 1.4.6 and the current is 1.6.2 so updating would be my first thought. I know some significant changes went in in 1.6 to enable DNS... maybe this is also causing issues since HA has a notably older version.

Info from addon log:

-----------------------------------------------------------
 Add-on: ZeroTier One
 Radically simplify your network with a virtual networking layer that works the same everywhere
-----------------------------------------------------------
 Add-on version: 0.9.0
 You are running the latest version of this add-on.
 System: Home Assistant OS 5.10  (aarch64 / raspberrypi4-64)
 Home Assistant Core: 2021.1.4
 Home Assistant Supervisor: 2021.01.5

Unable to start add on

Problem/Motivation

Add on does not start

Log error

19-04-03 02:30:05 ERROR (SyncWorker_0) [hassio.docker] Can't start addon_a0d7b954_zerotier: 500 Server Error: Internal Server Error ("linux runtime spec devices: error gathering device information while adding custom device "/dev/net/tun": no such file or directory")

add a networkId input box so much better

Problem/Motivation

(Why the issue was filed)
When I first installed, I clicked on the Configuration page and there was only one api_auth_token input box. I thought it was to input the networkId, but there was no response after input,Until I looked at the documentation and found that there was a configuration for the networkId, but it needed to be edited with yaml

Expected behavior

(What you expected to happen)
I would like to have two input boxes, one for api_auth_token and one for networkId

Actual behavior

(What actually happened)
one input box is confusing , because the network id is necessary

Steps to reproduce

(How can someone else make/see it happen)
click Configuration tab

Proposed changes

I would like to have two input boxes, one for api_auth_token and one for networkId

(If you have a proposed change, workaround or fix,
describe the rationale behind it)

After activation Local IP is not reachable

Problem

Hi, i have some problems with my ZeroTier Addon. After the activation of ZeroTier, i have no access over the local ip adresse. Only over ZT or HostName

Expected behavior

ZeroTier is connected. HA is reachable over the Local IP.

Actual behavior

ZeroTier is connected. HA is not reachable over the Local IP. Only over HostName:8123 or ZeroTier

Useful Information

ZeroTier Addon Config:
api_auth_token: ''
networks:
- 9bee89xxxxxxxxxx

Terminal ifConfig:
Bildschirmfoto 2022-03-06 um 23 14 51

Enhancement Idea: Display node IP

First of thank you for this addon, it is well put together (as usual).

Enhancement Idea

Would it be possible to somehow log or display the zerotier interfaces IP address? I can see it in the zerotier dashboard online, but having it entered into the log messages would be great to help quickly troubleshoot any issues.

One method might be to grab the data from the zerotier command line tool. zerotier-cli listnetworks

image

Suddenly slow after update

Problem/Motivation

Until previous version (pre-0.11.2) it always was very fast. Now after updating to 0.11.2 I experience delay.

(Why the issue was filed)

Expected behavior

Normal loading times

(What you expected to happen)

Actual behavior

Lovelace dashboard, supervisor, etc. are very slow loading remotely via zerotier now.

(What actually happened)

Steps to reproduce

(How can someone else make/see it happen)

Proposed changes

(If you have a proposed change, workaround or fix,
describe the rationale behind it)

LOGGING:

[s6-init] making user provided files available at /var/run/s6/etc...exited 0.
[s6-init] ensuring user provided files have correct perms...exited 0.
[fix-attrs.d] applying ownership & permissions fixes...
[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts...
[cont-init.d] 00-banner.sh: executing... 
-----------------------------------------------------------
 Add-on: ZeroTier One
 Radically simplify your network with a virtual networking layer that works the same everywhere
-----------------------------------------------------------
 Add-on version: 0.11.2
 You are running the latest version of this add-on.
 System: Home Assistant OS 6.4  (amd64 / qemux86-64)
 Home Assistant Core: 2021.9.7
 Home Assistant Supervisor: 2021.09.6
-----------------------------------------------------------
 Please, share the above information when looking for help
 or support in, e.g., GitHub, forums or the Discord chat.
-----------------------------------------------------------
[cont-init.d] 00-banner.sh: exited 0.
[cont-init.d] 01-log-level.sh: executing... 
[cont-init.d] 01-log-level.sh: exited 0.
[cont-init.d] zerotier.sh: executing... 
[09:36:59] INFO: ZeroTier node address: xxxxxxxxx
[09:37:01] INFO: Configuring network: xxxxxxxxxxxxxxxx
[cont-init.d] zerotier.sh: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
[09:37:02] INFO: Starting ZeroTier One...
[10:34:45] INFO: Starting ZeroTier One...

Example configuration not working

Problem/Motivation

Trying to set up Zerotier network on a freshly installed add-on and got an error message. Even with the example YAML or adding network by hand.

Expected behavior

Network id should be saved.

Actual behavior

Got error message:
Failed to save add-on configuration, does not match regular expression ^!secret [a-zA-Z0-9_\-]+$|[0-9a-z]{16}. Got {'networks': ['wgfyiwe73747457', 'fhu3888892jjfdk'], 'api_auth_token': ''}

Steps to reproduce

Add add-on. Use example configuration.

Proposed changes

Probably needs some fixing.

Lost connection with shared LAN

I have a problem. The addon works, but very often it loses communication with the shared LAN in zerotier. I am using the add-on to read other devices from a different location. In this second location, I have a router with opewrt and zerotier. Evidently the problem is on the HA side. When the HA loses communication with the devices behind the router with opewrt, I can access them from another device that is connected to the zerotier. I can also get to HA via zerotier .. To access devices behind opewrt router again I need to reset addon. The log shows nothing special. It does not change

Home Assistant does not connect

Problem/Motivation

ZeroTier tells me that I am offline, but the log says that I am online.

[s6-init] making user provided files available at /var/run/s6/etc...exited 0.
[s6-init] ensuring user provided files have correct perms...exited 0.
[fix-attrs.d] applying ownership & permissions fixes...
[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts...
[cont-init.d] 00-banner.sh: executing...

Add-on: ZeroTier One
Radically simplify your network with a virtual networking layer that works the same everywhere

Add-on version: 0.7.3
You are running the latest version of this add-on.
System: HassOS 4.12 (armv7 / raspberrypi4)
Home Assistant Core: 0.114.4
Home Assistant Supervisor: 235

Please, share the above information when looking for help
or support in, e.g., GitHub, forums or the Discord chat.

[cont-init.d] 00-banner.sh: exited 0.
[cont-init.d] 01-log-level.sh: executing...
[cont-init.d] 01-log-level.sh: exited 0.
[cont-init.d] zerotier.sh: executing...
[09:46:44] INFO: ZeroTier node address: ********
[09:46:44] INFO: Configuring network: *******
[cont-init.d] zerotier.sh: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
[09:46:44] INFO: Starting ZeroTier One...

I've already tried installing ZeroTier, but it keeps saying I'm not online.

(Why the issue was filed)

Expected behavior

(What you expected to happen)

Actual behavior

(What actually happened)

Steps to reproduce

(How can someone else make/see it happen)

Proposed changes

(If you have a proposed change, workaround or fix,
describe the rationale behind it)

Supervisor page doesn't show

Problem/Motivation

Supervisor page on a Home Assistant OS instance doesn't show up when connected by ZeroTier address.
If I connect to the instance by using local lan ip, the page works flawlessly

Expected behavior

The Supervisor page works in the same way both connected via zerotier and in the local network.

Actual behavior

Supervisor page on a Home Assistant OS instance doesn't show up when connected by ZeroTier address.
If I connect to the instance by using local lan ip, the page works flawlessly.
No info on HA logs

image

Environment

Add-on version: 0.7.3
System: HassOS 4.13 (armv7l / raspberrypi4-32)
Home Assistant Core: 0.115.2
Home Assistant Supervisor: 245

Thanks

Unable to connect to HA via ZeroTierOne

Problem/Motivation

Hi;
I used zerotierone via Android with http:/10.243.82.79:8123 to external connect to HA from long time without any issue, until today where i have message :
Unable to connect to Home Assistant.
No issue with HA 2021.11.4 bevor upgrade to 2021.11.5.
Please provide some HINT how to repair this.

(Why the issue was filed)

Expected behavior

(What you expected to happen)

Actual behavior

Unable to connect to Home Assistant

(What actually happened)

Steps to reproduce

Updated to HA ver. 2021.11.5, downgrading to ver 2021.11.4 same error.

(How can someone else make/see it happen)

LOG ZeroTier One:

[s6-init] making user provided files available at /var/run/s6/etc...exited 0.
[s6-init] ensuring user provided files have correct perms...exited 0.
[fix-attrs.d] applying ownership & permissions fixes...
[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts...
[cont-init.d] 00-banner.sh: executing...

Add-on: ZeroTier One
Radically simplify your network with a virtual networking layer that works the same everywhere

Add-on version: 0.12.1
You are running the latest version of this add-on.
System: Home Assistant OS 6.6 (armv7 / raspberrypi3)
Home Assistant Core: 2021.11.5
Home Assistant Supervisor: 2021.10.8

Please, share the above information when looking for help
or support in, e.g., GitHub, forums or the Discord chat.

[cont-init.d] 00-banner.sh: exited 0.
[cont-init.d] 01-log-level.sh: executing...
Log level is set to DEBUG
[cont-init.d] 01-log-level.sh: exited 0.
[cont-init.d] zerotier.sh: executing...
[17:55:21] INFO: ZeroTier node address: XXXXXXXXXXXXX
[17:55:23] INFO: Configuring network: XXXXXXXXXXXXXX
[cont-init.d] zerotier.sh: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
[17:55:23] INFO: Starting ZeroTier One...

LOGS in HA:

Logger: aiohttp.server
Source: /usr/local/lib/python3.9/site-packages/aiohttp/web_protocol.py:393
First occurred: 6:01:05 PM (4 occurrences)
Last logged: 6:31:04 PM

Error handling request
Traceback (most recent call last):
File "/usr/local/lib/python3.9/site-packages/aiohttp/web_protocol.py", line 314, in data_received
messages, upgraded, tail = self._request_parser.feed_data(data)
File "aiohttp/_http_parser.pyx", line 546, in aiohttp._http_parser.HttpParser.feed_data
aiohttp.http_exceptions.BadStatusLine: 400, message="Bad status line 'invalid HTTP method'"

Proposed changes

(If you have a proposed change, workaround or fix,
describe the rationale behind it)

Not working?

Problem/Motivation

No device can access my Pi through ZeroTier

Expected behavior

To be ble to ping, and access my Home Assistant Pi through browser using the IP address provided by ZeroTier. http://xxx.xxx.xxx.xxx:8123

Actual behavior

Other devices on the ZeroTier VPN can access and ping each other, but cannot access HA. The ZeroTier management page shows it as being connected and reflects the correct network ID and MAC address of the Pi, but nothing can access it. I can't ping to/from the Pi

Steps to reproduce

not sure

Proposed changes

(If you have a proposed change, workaround or fix,
describe the rationale behind it)

Is anyone having this issue except me?

Fearure Request:

Problem/Motivation

Picture a home with LTE network connectivity, where the IP address granted from the mobile network is not routable. Zerotier is the only option. To make the home LAN available remotely, it is possible to configure a zerotier host as a NAT router, only there is no easy way to save iptables rules in the supervisor container.

Expected behavior

I'd like to configure the RPi running HassOS and the zerotier plugin to be a gateway into home LAN, as described in this paper https://zerotier.atlassian.net/wiki/spaces/SD/pages/224395274/Route+between+ZeroTier+and+Physical+Networks

Actual behavior

Following the instructions from the link above, I am able to create NAT in supervisor container, but I am not able to save the iptables rules to file, so after the HassOS restart the forwarding rules are lost.

Steps to reproduce

Install the HassOS + ZeroTier plugin and follow the link above to configure NAT with iptables. You are now able to connect to your home LAN with ZeroTier.

Proposed changes

I suggest adding an option to the configuration yaml like :
nat: true
alternatively, following these instructions https://zerotier.atlassian.net/wiki/spaces/SD/pages/193134593/Bridge+your+ZeroTier+and+local+network+with+a+RaspberryPi
bridge: true
but this might be an overkill. NAT might be enough as a starter.

Unable to connect to ZeroTierOne network.

Problem/Motivation

I was having my HA coming up online for past few days. Today on reaching on home checked the ZeroTierOne network it was showing online. However i was not able to ping from other clients on the same net. The other devices are able to ping each other successfully.
I tried updating HA to latest versions. Thereafter It is not even showing online in the zero tier one network page.

Expected behavior

it should connect and be pinged from other clients in same net

Actual behavior

Device showing as online but could not \be pinged. After host reboot, it is showing offline.

Steps to reproduce

Updated to latest version

Logs

[s6-init] ensuring user provided files have correct perms...exited 0.
[fix-attrs.d] applying ownership & permissions fixes...
[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts...
[cont-init.d] 00-banner.sh: executing... 
-----------------------------------------------------------
 Add-on: ZeroTier One
 Radically simplify your network with a virtual networking layer that works the same everywhere
-----------------------------------------------------------
 Add-on version: 0.11.2
 You are running the latest version of this add-on.
 System: Home Assistant OS 6.4  (aarch64 / raspberrypi4-64)
 Home Assistant Core: 2021.10.0
 Home Assistant Supervisor: 2021.09.6
-----------------------------------------------------------
 Please, share the above information when looking for help
 or support in, e.g., GitHub, forums or the Discord chat.
-----------------------------------------------------------
[cont-init.d] 00-banner.sh: exited 0.
[cont-init.d] 01-log-level.sh: executing... 
[cont-init.d] 01-log-level.sh: exited 0.
[cont-init.d] zerotier.sh: executing... 
[03:41:03] INFO: ZeroTier node address: 36xxxxxxxxxx. //obfuscated
[03:41:03] INFO: Configuring network: d5xxxxxxxxxxxx //obfuscated
[cont-init.d] zerotier.sh: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
[03:41:03] INFO: Starting ZeroTier One...

How to set Network Id

Problem/Motivation

Can't find clear instructions on how to set network id

Expected behavior

Obvious way to set network id

Actual behavior

Startup shows errors in log due to lack of configuration

Steps to reproduce

Install ZeroTier One. I have: Home Assistant 2023.3.3, Supervisor 2023.03.1, Operating System 9.5, Frontend 20230309.0

Proposed changes

Provide configuration parameter or clear instructions to set network id.

Although this has been raised before (e.g. in issue 164), the proposed solution "Needed to press 3 dots and edit via Yaml" unfortunately doesn't help me.

Which 3 dots? These appear on several HA pages (e.g. Overview, Settings, Add-on Store), and none I found are relevant.

I looked in /config for a relevant file I might edit but didn't find anything.

Actually, it's rather odd that I've installed ZeroTier One but it doesn't appear in the list of installed add-ons shown by Settings/Add-ons. I don't know if that means it's not installed properly.

ZeroTier loses connectivity forever after power cycling the Internet router (sometimes)

Problem/Motivation

ZeroTier loses connectivity forever after power cycling the Internet router (sometimes)

Expected behavior

To remain connected after temporary Internet loses

Actual behavior

Sometimes I power off and on the Internet Router of the operator to get a new IP address.
Usually, after the router gets reconnected, ZeroTier gets reconnected without problem, but sometimes, although I have access to the page of Home Assistant, ZeroTier disconnects forever. It is necessary to power cycle the Raspberry Pi 4B to restore connection. The error shown in the log is "sendto: Network unreachable" that repeats forever.

Steps to reproduce

Power off the Internet Router and power on again until Zerotier cannot longer reconnect.

(How can someone else make/see it happen)
Don't know

Proposed changes

Apart from solving this issue, It would be very interesting to have a Home Assistant variable that shows the connection state of ZeroTier.
It would be nice to see the connection status in the Dashboard, Isn't it?

(If you have a proposed change, workaround or fix,
describe the rationale behind it)

Thanks a lot for this wonderful plug-in

Dependency Dashboard

This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.

Open

These updates have all been created already. Click a checkbox below to force a retry/rebase of any.

Detected dependencies

dockerfile
zerotier/Dockerfile
  • ghcr.io/hassio-addons/base 15.0.7
github-actions
.github/workflows/ci.yaml
.github/workflows/deploy.yaml
.github/workflows/labels.yaml
.github/workflows/lock.yaml
.github/workflows/pr-labels.yaml
.github/workflows/release-drafter.yaml
.github/workflows/stale.yaml
regex
zerotier/Dockerfile
  • ghcr.io/hassio-addons/base 15.0.7
zerotier/build.yaml
  • ghcr.io/hassio-addons/base 15.0.7
  • ghcr.io/hassio-addons/base 15.0.7
  • ghcr.io/hassio-addons/base 15.0.7
zerotier/Dockerfile
  • alpine_3_19/build-base 0.5-r3
  • alpine_3_19/cargo 1.76.0-r0
  • alpine_3_19/git 2.43.0-r0
  • alpine_3_19/linux-headers 6.5-r0
  • alpine_3_19/openssl-dev 3.1.4-r6
  • alpine_3_19/pkgconf 2.1.0-r0
  • alpine_3_19/libgcc 13.2.1_git20231014-r0
zerotier/Dockerfile
  • zerotier/ZeroTierOne 1.12.2

  • Check this box to trigger a request for Renovate to run again on this repository

IPv4 forwarding to access local LAN

Problem/Motivation

I want to access my local LAN via ZeroTier, not only the Home Assistant OS host. It could be easily set up via managed routes and enabled ipv4 forwarding on Linux. I'm trying to figure out how to enable ipv4 forwarding on Home Assistant OS and/or ZeroTier extension.

Expected behavior

Creating a new managed route in ZeroTier Central creates access to local LAN.

Actual behavior

No access

Steps to reproduce

Install and set up ZeroTier extension. Join the network. Create a managed route that forwards the local LAN via ZeroTier address.

Proposed changes

Update documentation on how to enable ipv4 forwarding on Home Assistant OS and extension code if necessary.

zero tier - iphone

Problem/Motivation

home assistant + zero tier does not work on iphone phones

(Why the issue was filed)

I installed the zero tier addon on my home assistant

  • core version: 2021.3.3
  • supervisor version: 2021.02.11
    On my android phone it works perfect but on iphone phones it doesn't work. I tested with two browsers (safari and chrome) and it doesn't work
    I also installed it on an apple tablet and it works fine
    Someone can help me find the solution.
    Thanks a lot

Expected behavior

(What you expected to happen)

Actual behavior

(What actually happened)

Steps to reproduce

(How can someone else make/see it happen)

Proposed changes

(If you have a proposed change, workaround or fix,
describe the rationale behind it)

conflict with sonos

Problem/Motivation

when zerotier is started my sonos integration stops working

(Why the issue was filed)

Expected behavior

(What you expected to happen)

Actual behavior

(What actually happened)

Steps to reproduce

(How can someone else make/see it happen)

Proposed changes

(If you have a proposed change, workaround or fix,
describe the rationale behind it)

Connection reset by peer

Problem/Motivation

Noticed my HA instance was inaccessible via ZeroTier, but the host was still showing as ONLINE on the ZeroTier website. I locked in the logs for the addon and it was JUST solid: Connection reset by peer

Expected behavior

(What you expected to happen)

It would be accessible

my HA instance was inaccessible

Steps to reproduce

Don't know how you'd reproduce it reliably?

Proposed changes

Maybe the addon should have a watchdog function?

Enable IP forwarding

Problem/Motivation

It would be absolutely nice, if IP Forwarding could be enabled, that the addon can be used as VPN Endpoint

Expected behavior

Ip Forwarding being enabled. Perfect would be a switch to enable/disable IP forwarding for IPv4/IPv6

Actual behavior

IP Forwarding is not enabled in the docker container

Steps to reproduce

(How can someone else make/see it happen)

Proposed changes

Ip Forwarding being enabled. Perfect would be a switch to enable/disable IP forwarding for IPv4/IPv6

Cannot have more than one secret networks

Problem/Motivation

I tried to use more than one network with the !secret option, and it doesn't work.

Expected behavior

Use as many secret networks as you want.

Actual behavior

Only one secret network is supported.

Steps to reproduce

Use the following:

networks:
  - '!secret zerotier_net_one'
  - '!secret zerotier_net_two'

It errors with:

Failed to save addon configuration, not a valid value for dictionary value @ data['options'].
Got {'networks': ['!secret zerotier_net_one', '!secret zerotier_net_two'], 'api_auth_token': ''}

Proposed changes

I think it has to do with the secret regex in

"networks": ["match(^!secret [a-zA-Z0-9_\\-]+$|[0-9a-z]{16})"],
.

Unable to save network id

Problem/Motivation

I am unable to save my network id in zero-tier add-on configuration tab.

Expected behavior

it should save my network id in configuration.

Actual behavior

restores to default networks: [] api_auth_token: ''

Steps to reproduce

replace [] with network id and click save.

Proposed changes

anything to fix this behaviour.

ZeroTier not coming up after update 0.8.0

I'm having multiple remote home assistant instances which aren't coming online after upgrading zerotier to 0.8.0.
On my local instance, the zerotier log keeps showing the following:

[09:09:18] INFO: Starting ZeroTier One...
[09:09:19] INFO: Starting ZeroTier One...
[09:09:20] INFO: Starting ZeroTier One...
[09:09:21] INFO: Starting ZeroTier One...
[09:09:22] INFO: Starting ZeroTier One...
[09:09:23] INFO: Starting ZeroTier One...
[09:09:24] INFO: Starting ZeroTier One...
[09:09:25] INFO: Starting ZeroTier One...
[09:09:26] INFO: Starting ZeroTier One...
[09:09:27] INFO: Starting ZeroTier One...
[09:09:28] INFO: Starting ZeroTier One...
[09:09:29] INFO: Starting ZeroTier One...

Home Assistant's log shows this:

Logger: zeroconf
Source: /usr/local/lib/python3.8/site-packages/zeroconf/__init__.py:400
First occurred: 8:58:35 AM (2 occurrences)
Last logged: 8:58:42 AM

Error sending through socket 50
Traceback (most recent call last):
  File "/usr/local/lib/python3.8/site-packages/zeroconf/__init__.py", line 2914, in send
    bytes_sent = s.sendto(packet, 0, (real_addr, port))
OSError: [Errno 19] No such device

Any idea what's going on? I've updated Home Assistant to the latest version (0.118.3), but it also applies to 0.118.2.

Can't set network ID

Problem/Motivation

After adding network id, configuration can't be saved and the box is clearing itself

Expected behavior

Network id box should be savable

Actual behavior

No option to save network ID

Doesn't support secrets.yaml

Problem/Motivation

Configured secrets but it does not accept

(Why the issue was filed)

Expected behavior

Should accept secrets

(What you expected to happen)

Actual behavior

image

(What actually happened)
configure secrets

Steps to reproduce

(How can someone else make/see it happen)

Proposed changes

I am just not using !secret and it works

(If you have a proposed change, workaround or fix,
describe the rationale behind it)

Allow Ethernet Bridging?

Problem/Motivation

Id like to access my home network from my laptop so I can access a NAS that I can not install this software onto

Expected behavior

be able to mount the NAS drive remotly

Actual behavior

N/A

Steps to reproduce

N/A

Proposed changes

add the ability for "Allow Ethernet Bridging"

Node ID not cleared by a reset of configuration or a reinstall of plugin

Problem/Motivation

cannot change Node ID when needed for example when restoring a backup on another HA instance.

Expected behavior

According to the Zerotier documentation
Delete the files identity.public and identity.secret from ZeroTier's working directory.".
On Linux this is usually "/var/lib/zerotier-one".

Actual behavior

The old Node ID is kept even if you reinstall the plugin or reset the configuration

Steps to reproduce

reinstall or reset the configuration and look at the log

Proposed changes

delete node ID when reinstall or reset the configuration of the plugin or give the option to.

IP forwarding

hello friend!
I have free vps on cloud.google.com. I installed zerotier on my server (on cloud.google), on my android phone and addon on home assistant (on raspberry pi). I configured the network. I can connect to home assistant using my android via zerotier. I checked the ping from my server to the ip address(managed ip on zerotier) assigned to my raspberry with home assistant.
I want IP forwarding From my Public IP(server google cloud) to Managed IP zerotier. Its need for access on my home assistant via my Public IP(server google cloud). What i doing:

  1. Im add on Managed Routes Destination (my Public IP server google cloud) Via (managed ip on zerotier my raspberry pi)
  2. Configurate net.ipv4.ip_forward = 1 (/etc/sysctl.conf) on my server google cloud
  3. Use on my server google cloud sudo iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE and sudo iptables -A FORWARD -m conntrack --ctstate RELATED,ESTABLISHED -j ACCEPT and sudo iptables -A FORWARD -i ztr2qr4pmm -o eth0 -j ACCEPT
  4. On raspberry pi configurate net.ipv4.conf.all.rp_filter=2 (/etc/sysctl.conf)
  5. As i know need configurate allowDefault=1. I cant find on addon zerotieron home assistant option "allowDefault". How turn on "allowDefault" ?
    Sorry for my english and thanks for your work.

can not save network id

Capture

Problem/Motivation

19-04-03 03:00:37 ERROR (SyncWorker_1) [hassio.docker] Can't start addon_a0d7b954_zerotier: 500 Server Error: Internal Server Error ("linux runtime spec devices: error gathering device information while adding custom device "/dev/net/tun": no such file or directory")

(Why the issue was filed)

Expected behavior

(What you expected to happen)

Actual behavior

(What actually happened)

Steps to reproduce

(How can someone else make/see it happen)

Proposed changes

(If you have a proposed change, workaround or fix,
describe the rationale behind it)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.