This is a follow-up to #27375, allowing ZMQ notifications to be published to a UNIX domain socket.
Fortunately, libzmq handles unix sockets already, all we really have to do to support it is allow the format in the actual option.
libzmq uses the prefix ipc://
as opposed to unix:
which is used by Tor and now also by bitcoind so we need to switch that internally.
As far as I can tell, LND supports ipc://
and unix://
(notice the double slashes).
With this patch, LND can connect to bitcoind using unix sockets:
Example:
bitcoin.conf:
0zmqpubrawblock=unix:/tmp/zmqsb
1zmqpubrawtx=unix:/tmp/zmqst
lnd.conf:
0bitcoind.zmqpubrawblock=ipc:///tmp/zmqsb
1bitcoind.zmqpubrawtx=ipc:///tmp/zmqst