As we do not really generate ejabbred.cfg, allow at least overwriting it manually

svn path=/nixos/trunk/; revision=15006
This commit is contained in:
Michael Raskin 2009-04-13 09:35:03 +00:00
parent bec0e32034
commit 49bd768f99
3 changed files with 6 additions and 1 deletions

View File

@ -259,6 +259,7 @@ import ../helpers/make-etc.nix {
"kde"
"cups"
"ftp"
"ejabberd"
"common"
"common-console" # shared stuff for interactive local sessions
]

4
etc/pam.d/ejabberd Normal file
View File

@ -0,0 +1,4 @@
auth include common
account include common
password include common
session include common

View File

@ -24,7 +24,7 @@ in
fi
mkdir -p ${cfg.confDir}
sed -e 's|{hosts, \["localhost"\]}.|{hosts, \[${cfg.virtualHosts}\]}.|' ${pkgs.ejabberd}/etc/ejabberd/ejabberd.cfg > ${cfg.confDir}/ejabberd.cfg
test -f ${cfg.confDir}/ejabberd.cfg || sed -e 's|{hosts, \["localhost"\]}.|{hosts, \[${cfg.virtualHosts}\]}.|' ${pkgs.ejabberd}/etc/ejabberd/ejabberd.cfg > ${cfg.confDir}/ejabberd.cfg
end script
respawn ${pkgs.bash}/bin/sh -c 'export PATH=$PATH:${pkgs.ejabberd}/sbin; cd ~; ejabberdctl --logs ${cfg.logsDir} --spool ${cfg.spoolDir} --config ${cfg.confDir}/ejabberd.cfg start; sleep 1d'