Sharing my working settings for Zenoh with a workaround for it to work with two nodes that are not on same LAN (no multicast or broadcast).
{
mode: "peer",
connect: {
endpoints: ["tcp/zenoh-endpoint:7447", "udp/zenoh-endpoint:7447"],
},
listen: {
endpoints: ["tcp/[::]:7447", "udp/[::]:7447"]
},
scouting: {
gossip: {
enabled: true,
multihop: false,
autoconnect: { router: [], peer: ["router", "peer"] },
},
},
}
The workaround: as Stalwart has just one shared configuration for Zenoh and as it can’t have its own address on the connect endpoints because it crashes Zenoh, I added a zenoh-endpoint to the /etc/hosts point to the another host, after it connects it should grab extra nodes using gossip protocol (I didn’t tested it).
Please note that zenoh is not included in the default binary, you must compile it yourself with: cargo build --release --features=zenoh,other-features, where other-features is the features you need (eg.: s3, mysql, postgres, enterprise, etc)
I am looking forward regarding critique to this solution and possible improvements.