2008-02-18 10:15:10 +01:00
|
|
|
args: with args;
|
2008-03-26 17:42:57 +01:00
|
|
|
|
|
|
|
let
|
|
|
|
bitlbeeUid = (import ../system/ids.nix).uids.bitlbee;
|
|
|
|
in
|
2008-02-18 10:15:10 +01:00
|
|
|
{
|
|
|
|
name = "bitlbee";
|
|
|
|
|
|
|
|
users = [
|
|
|
|
{ name = "bitlbee";
|
2008-03-26 17:42:57 +01:00
|
|
|
uid = bitlbeeUid;
|
2008-02-18 10:15:10 +01:00
|
|
|
description = "BitlBee user";
|
|
|
|
home = "/var/empty";
|
|
|
|
}
|
|
|
|
];
|
|
|
|
|
2008-03-26 17:42:57 +01:00
|
|
|
groups = [
|
|
|
|
{ name = "bitlbee";
|
|
|
|
gid = (import ../system/ids.nix).gids.bitlbee;
|
|
|
|
}
|
|
|
|
];
|
|
|
|
|
|
|
|
job = ''
|
|
|
|
description "BitlBee IRC to other chat networks gateway"
|
2008-02-18 10:15:10 +01:00
|
|
|
|
|
|
|
start on network-interfaces/started
|
|
|
|
stop on network-interfaces/stop
|
|
|
|
|
|
|
|
start script
|
|
|
|
if ! test -d /var/lib/bitlbee
|
|
|
|
then
|
|
|
|
mkdir -p /var/lib/bitlbee
|
|
|
|
fi
|
|
|
|
end script
|
|
|
|
|
2008-03-26 17:42:57 +01:00
|
|
|
respawn ${bitlbee}/sbin/bitlbee -F -p ${toString portNumber} \
|
|
|
|
-i ${interface} -u bitlbee
|
|
|
|
'';
|
2008-02-18 10:15:10 +01:00
|
|
|
|
|
|
|
}
|