blob: 6500ca5893b6a8dfd20e4c77099dc9c739fd8bbf (
plain) (
tree)
|
|
{ lib, pkgs, config, myconfig, mylibs, ... }:
{
options = {
services.irc.enable = lib.mkOption {
type = lib.types.bool;
default = false;
description = ''
Whether to enable irc stuff.
'';
};
};
config = lib.mkIf config.services.irc.enable {
security.acme.certs."irc" = config.services.myCertificates.certConfig // {
domain = "irc.immae.eu";
postRun = ''
systemctl restart stunnel.service
'';
};
networking.firewall.allowedTCPPorts = [ 6697 ];
services.bitlbee = {
enable = true;
authMode = "Registered";
libpurple_plugins = [
pkgs.purple-hangouts
pkgs.purple-matrix
];
plugins = [
pkgs.bitlbee-mastodon
pkgs.bitlbee-facebook
pkgs.bitlbee-discord
pkgs.bitlbee-steam
];
};
services.stunnel = {
enable = true;
servers = {
bitlbee = {
accept = 6697;
connect = 6667;
cert = "/var/lib/acme/irc/full.pem";
};
};
};
};
}
|