2024-05-31 16:00:03 +00:00
|
|
|
{ pkgs, lib, config, ... }: {
|
2022-05-17 20:36:07 +00:00
|
|
|
services.matterbridge = {
|
|
|
|
enable = true;
|
|
|
|
configPath = let
|
2023-09-11 13:31:13 +00:00
|
|
|
bridgeBotToken = lib.strings.fileContents "${config.krebs.secret.directory}/telegram.token";
|
2022-05-17 20:36:07 +00:00
|
|
|
in
|
|
|
|
toString ((pkgs.formats.toml {}).generate "config.toml" {
|
|
|
|
general = {
|
|
|
|
RemoteNickFormat = "[{NICK}] ";
|
|
|
|
Charset = "utf-8";
|
|
|
|
};
|
|
|
|
telegram.krebs.Token = bridgeBotToken;
|
2022-11-21 22:31:46 +00:00
|
|
|
irc.hackint = {
|
|
|
|
Server = "irc.hackint.org:6697";
|
|
|
|
UseTLS = true;
|
2022-05-17 20:36:07 +00:00
|
|
|
Nick = "ponte";
|
|
|
|
};
|
|
|
|
gateway = [
|
|
|
|
{
|
|
|
|
name = "krebs-bridge";
|
|
|
|
enable = true;
|
|
|
|
inout = [
|
|
|
|
{
|
|
|
|
account = "irc.hackint";
|
|
|
|
channel = "#krebs";
|
|
|
|
}
|
|
|
|
{
|
|
|
|
account = "telegram.krebs";
|
|
|
|
channel = "-330372458";
|
|
|
|
}
|
|
|
|
];
|
|
|
|
}
|
|
|
|
];
|
|
|
|
});
|
|
|
|
};
|
|
|
|
}
|