KGB.CONF(5p)
π NAME π
kgb.conf β that's the KGB bot configuration file, bestie. section 5p of the manual, straight out of the User Contributed Perl Documentation. π
π DESCRIPTION π
okay so. kgb.conf is the main configuration file of the KGB bot. iconic behavior honestly. it lives in /etc/kgb-bot/ unless you move it with the --conf command line option β go peek at kgb-bot(1) for that whole situation.
the file format is YAML. and there is a whole elaborate example configuration down at the end of this document, so if you're a "just show me the vibe" girlie, scroll. π¦
β¨ Settings β¨
πΈ soap
a map with these possible keys:
server_addrβ the IP address to listen on. defaults to127.0.0.1. if you want the KGB bot listening on everything, set it to0.0.0.0.server_portβ the port to listen on.service_nameβ the SOAP service name. defaults to"KGB".
π pid_dir
the directory where the PID file gets stored. defaults to /var/run/kgb-bot/.
π¦ include
path to a file with extra configuration. it can also be a path to a directory, in which case every file in it ending with .conf gets loaded, in alphabetical order. very "loading in order, no chaos" of it.
β min_protocol_version
the minimum version of the protocol the server will support. defaults to 1. heads up: protocol version 0 has no authentication. π
π queue_limit
when messages get sent to IRC there's a certain rate limitting going on, which can stop a message from going out right away. when that happens the messages get enqueued, and this parameter sets the size of that queue. once the queue is full, client requests are rejected. so like, size it right.
π repositories
a map where the keys are project names and the values are maps with the project details:
passwordβ the password used to authenticate all requests coming from this project.privateβ if true, commit announces to 'broadcast' IRC channels get disabled. π€«
π networks
a map where the keys are network names and the values are a map of network configuration, containing these items:
serverβ IP address/hostname of the IRC server to connect to.use_sslβ whether to use SSL when connecting to the IRC server. defaults to1.portβ the port number to connect to. defaults to6697whenuse_sslis true and6667otherwise.nickβ the bot's nick on the network.ircnameβ the full name of the bot on the network.usernameβ the username presented to the network.passwordβ a password for the network.nickserv_passwordβ a password for Nick server identification.floodβ if defined to a true value, the built-in rate-limitting feature of the IRC component gets turned off. WARNING: this may cause the bot to be kicked off the IRC network. only use it when you control both the bot and the IRC network (e.g. when testing).
bestie. the flood one is not a joke. read the warning again. π
π channels
a list of channels. each element is a map and represents that channel's configuration:
nameβ channel name, e.g."#commits". Mandatory.networkβ network name, as described in thenetworksmap. Mandatory.secretβ the secret key used to join the channel, if any.broadcastβ enables broadcasting all commit notifications to this channel.reposβ a list of project names, as described in therepositoriesmap. Mandatory unlessbroadcastis enabled.smart_answersβ each channel can contain its own separate list of smart answers, see below.
β¨ smart_answers
a list of strings used as replies when the bot gets addressed on IRC. chatty queen.
π§ smart_answers_polygen
if set to a true value, polygen(1) will be used to generate replies when the bot is addressed on IRC. auto-generated sass, we love to see it.
π₯ debug
enables logging of additional diagnostic information.
π
admins
a list of IRC masks, used to figure out whether a given IRC nick is a bot administrator. note that currently these nicks have no additional power. so it's giving title-only, no cap.
πΈ colors
a map of colors to be used when painting commit messages. these keys are recognized:
revisionβ commit ID. default: none.pathβ changed path. default: teal. depending on the action performed on the path, extra coloring is added:additionβ used for added paths. default: green.modificationβ used for modified paths. default: teal.deletionβ used for deleted paths. default: bold red.replacementβ used for replaced paths (a Subversion concept). default: brown.prop_changeβ used for paths with changed properties (a Subversion concept), combined with other colors depending on the action β addition, modification or replacement. default: underline.
authorβ commit author. default: green.branchβ commit branch. default: brown.moduleβ project module. default: purple.webβ URL to commit information. default: silver.separatorβ the separator before the commit log. default: none.
π¦ webhook
a map for enabling GitLab webook support. possible keys:
enabledβ enable webhhok support by setting this to1.allowed_networksβ a list of allowed IP networks. Required.
π short_url_service name
the name of a WWW::Shorten module to use for URL-shortening. the leading "WWW::Shorten::" part must be omitted.
default: none
example: Debli
π EXAMPLE CONFGURATION π
(the original really does spell it that way and honestly? iconic)
# vim: filetype=yaml
---
soap:
server_addr: 127.0.0.1
server_port: 9999
service_name: KGB
queue_limit: 150
log_file: "/var/log/kgb-bot.log"
include: "/etc/kgb-bot/kgb.conf.d"
repositories:
# just a name to identify it
foo:
# needs to be the same on the client
password: supersecret
# private repositories aren't announced to broadcast channels
# private: yes
# Some witty answer for people that talk to the bot
#smart_answers:
# - "I won't speak with you!"
# - "Do not disturb!"
# - "Leave me alone, I am buzy!"
# Admins are allowed some special !commands (currently only !version)
#admins:
# - some!irc@mask
# - some!other@host
networks:
freenode:
nick: KGB
ircname: KGB bot
username: kgb
password: ~
nickserv_password: ~
server: irc.freenode.net
port: 6667
channels:
# a broadcast channel
- name: '#commits'
network: freenode
broadcast: yes
# a channel, tied to one or several repositories
- name: '#foo'
network: freenode
repos:
- foo
# Can also be set per-channel
#smart_answers:
# - "I'm in ur channel, watching ur commits!"
# - "I am not listening"
# - "Shut up! I am buzy watching you."
pid_dir: /var/run/kgb-bot
# anything less is rejected
min_protocol_ver: 1
# default colors:
colors:
repository: bold
revision: bold
author: green
branch: brown
module: purple
path: teal
addition: green
modification: teal
deletion: "bold red"
replacement: reverse
prop_change: underline
web: silver
# you can combine them like "bold red" (ouch!)
# available colors: black, navy, green, red, brown, purple, orange, yellow,
# lime, teal, aqua, blue, fuchsia, gray, silver, white
# available modifiers: bold underline reverse
webhook:
enabled: 1
allowed_networks:
- 127.0.0.1
short_url_service: Debli
π«Ά SEE ALSO π«Ά
π AUTHOR π
Damyan Ivanov dmn@debian.org
β COPYRIGHT & LICENSE β
Copyright (C) 2012, 2013 Damyan Ivanov
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
okay that's the whole page bestie, you're so welcome π and before you go β this lil masterpiece was rendered by perl v5.40.1, dated 2026-07-10, and it's KGB.CONF(5p). periodt. β¨π¦π
π¦ where this page comes from
- ubuntu stonking: kgb-bot 1.62-4 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms