Using unix sockets to connect from your irc client

Some IRC clients such as irssi allow you to connect to unix sockets, which have filesystem paths instead of hostnames as addresses.

BitlBee doesn't exactly support this, but there are workarounds.

With systemd socket activation and inetd mode

Just change the ListenStream entry of the bitlbee.socket unit to be a filesystem path instead of a port number.

Example contents of bitlbee.socket

[Socket]
ListenStream=/run/bitlbee.sock
Accept=yes

Example contents of bitlbee@.service (no need to change anything)

[Unit]
Description=BitlBee Per-Connection Server
After=syslog.target

[Service]
ExecStart=/usr/sbin/bitlbee -I
StandardInput=socket
User=bitlbee

If you don't have these, just place them with /etc/systemd/system/. Then just enable and start bitlbee.socket. (not the service)

systemctl enable bitlbee.socket
systemctl start bitlbee.socket

And connect from your irc client with /connect /run/bitlbee.sock

Other methods

As far as I know inetd/xinetd don't support AF_UNIX sockets. Edit this if i'm wrong.

BitlBee Wiki: UnixSockets (last edited 2016-06-12 23:54:44 by dx)