mDNS/zeroconf entry has invalid service type; is formatted incorrectly
The foris-controller mDNS entry seems to be formatted incorrectly,
i.e. the Service Instance Name is 0000000E000035C0
, the type is empty, and the domain is foris-controller._mqtt._tcp.local
,
instead of instance name {app_info['controller_id']}.foris-controller
, type _mqtt._tcp
and domain local
.
The ssh service type entries in comparison seem correct.
Running commands from a client within the LAN, with a Turris Omnia running the following versions:
reForis version 1.1.2
Turris OS version 5.3.1
Turris OS branch HBT
Kernel version 4.14.254
[lorbus@fedora ~]$ avahi-browse --version
avahi-browse 0.8
[lorbus@fedora ~]$ avahi-browse -a -r -t
+ enp8s0u2u1u2 IPv6 turris _ssh._tcp local
+ enp8s0u2u1u2 IPv4 turris _ssh._tcp local
Failed to resolve service '0000000E000035C0' of type '' in domain 'foris-controller._mqtt._tcp.local': Invalid service type
+ enp8s0u2u1u2 IPv4 0000000E000035C0 foris-controller._mqtt._tcp.local
Failed to resolve service 'turris' of type '_ssh._tcp' in domain 'local': Timeout reached
Failed to resolve service 'turris' of type '_ssh._tcp' in domain 'local': Timeout reached
and with parsable output:
[lorbus@fedora ~]$ avahi-browse -a -r -p -t
+;enp8s0u2u1u2;IPv6;turris;_ssh._tcp;local
+;enp8s0u2u1u2;IPv4;turris;_ssh._tcp;local
Failed to resolve service '0000000E000035C0' of type '' in domain 'foris-controller._mqtt._tcp.local': Invalid service type
+;enp8s0u2u1u2;IPv4;0000000E000035C0;;foris-controller._mqtt._tcp.local
Failed to resolve service 'turris' of type '_ssh._tcp' in domain 'local': Timeout reached
Failed to resolve service 'turris' of type '_ssh._tcp' in domain 'local': Timeout reached
The code in question is here: https://gitlab.nic.cz/turris/foris-controller/foris-controller/-/blob/9ff58ed3895ed4e9bbf1786ab54bf9331d7ddd69/foris_controller/zconf.py#L58-65
It's not obvious to me what's going wrong there. Maybe the variables that are passed to zeroconf.ServiceInfo()
aren't initialized or copied properly, or the zeroconf python lib does the string splitting wrong?
Also, I'm not sure it's intended that all the mDNS entries aren't resolving, but that looks like a separate issue.