POSTIN
/bin/sh
if [ ! -f /etc/webapps/horde-forwards/conf.php.bak ]; then
install /dev/null -o root -g http -m660 /etc/webapps/horde-forwards/conf.php.bak
fi
# take uids with < 500 and update refused logins in default conf.xml
USERLIST=$(awk -F: '{ if ($3 < 500) print $1 }' < /etc/passwd | xargs | tr ' ' ',')
if [ "$USERLIST" ]; then
sed -i -e "
# primitive xml parser ;)
/configlist name=\"refused\"/s/>.*</>$USERLIST</
" /etc/webapps/horde-forwards/conf.xml
fi
Triggers
apache1 <
1.3.37-3
/bin/sh
if [ "$1" = "1" ] && [ "$2" = "1" ]; then
/usr/sbin/webapp register apache horde-forwards
fi
# reload webserver if the config symlink is there and skip reload if webserver is upgraded
if [ -L /etc/apache/webapps.d/horde-forwards.conf ] && [ "$2" -lt "2" ]; then
{
skip_auto_restart() {
[ -f /etc/sysconfig/rpm ] && . /etc/sysconfig/rpm
[ -f /etc/sysconfig/apache ] && . /etc/sysconfig/apache
echo ${RPM_SKIP_AUTO_RESTART:-no}
};
if [ $(skip_auto_restart) = no ]; then
if [ -f /var/lock/subsys/apache ]; then
/sbin/service apache reload 1>&2 || :;
fi
fi };
fi
apache1-base
/bin/sh
# remove link if either of the packages are gone
if [ -n "" ] || [ "$1" = "0" ] || [ "$2" = "0" ] && [ -L /etc/apache/webapps.d/horde-forwards.conf ]; then
/usr/sbin/webapp unregister apache horde-forwards
{
skip_auto_restart() {
[ -f /etc/sysconfig/rpm ] && . /etc/sysconfig/rpm
[ -f /etc/sysconfig/apache ] && . /etc/sysconfig/apache
echo ${RPM_SKIP_AUTO_RESTART:-no}
};
if [ $(skip_auto_restart) = no ]; then
if [ -f /var/lock/subsys/apache ]; then
/sbin/service apache reload 1>&2 || :;
fi
fi };
fi
apache1 <
1.3.37-3
/bin/sh
if [ "$1" = "1" ] && [ "$2" = "1" ]; then
/usr/sbin/webapp register httpd horde-forwards
fi
# reload webserver if the config symlink is there and skip reload if webserver is upgraded
if [ -L /etc/httpd/webapps.d/horde-forwards.conf ] && [ "$2" -lt "2" ]; then
{
skip_auto_restart() {
[ -f /etc/sysconfig/rpm ] && . /etc/sysconfig/rpm
[ -f /etc/sysconfig/httpd ] && . /etc/sysconfig/httpd
echo ${RPM_SKIP_AUTO_RESTART:-no}
};
if [ $(skip_auto_restart) = no ]; then
if [ -f /var/lock/subsys/httpd ]; then
/sbin/service httpd reload 1>&2 || :;
fi
fi };
fi
apache1-base
/bin/sh
# remove link if either of the packages are gone
if [ -n "" ] || [ "$1" = "0" ] || [ "$2" = "0" ] && [ -L /etc/httpd/webapps.d/horde-forwards.conf ]; then
/usr/sbin/webapp unregister httpd horde-forwards
{
skip_auto_restart() {
[ -f /etc/sysconfig/rpm ] && . /etc/sysconfig/rpm
[ -f /etc/sysconfig/httpd ] && . /etc/sysconfig/httpd
echo ${RPM_SKIP_AUTO_RESTART:-no}
};
if [ $(skip_auto_restart) = no ]; then
if [ -f /var/lock/subsys/httpd ]; then
/sbin/service httpd reload 1>&2 || :;
fi
fi };
fi
apache <
2.2.0
/bin/sh
if [ "$1" = "1" ] && [ "$2" = "1" ]; then
/usr/sbin/webapp register apache horde-forwards
fi
# reload webserver if the config symlink is there and skip reload if webserver is upgraded
if [ -L /etc/apache/webapps.d/horde-forwards.conf ] && [ "$2" -lt "2" ]; then
{
skip_auto_restart() {
[ -f /etc/sysconfig/rpm ] && . /etc/sysconfig/rpm
[ -f /etc/sysconfig/apache ] && . /etc/sysconfig/apache
echo ${RPM_SKIP_AUTO_RESTART:-no}
};
if [ $(skip_auto_restart) = no ]; then
if [ -f /var/lock/subsys/apache ]; then
/sbin/service apache reload 1>&2 || :;
fi
fi };
fi
apache-base
/bin/sh
# remove link if either of the packages are gone
if [ -n "" ] || [ "$1" = "0" ] || [ "$2" = "0" ] && [ -L /etc/apache/webapps.d/horde-forwards.conf ]; then
/usr/sbin/webapp unregister apache horde-forwards
{
skip_auto_restart() {
[ -f /etc/sysconfig/rpm ] && . /etc/sysconfig/rpm
[ -f /etc/sysconfig/apache ] && . /etc/sysconfig/apache
echo ${RPM_SKIP_AUTO_RESTART:-no}
};
if [ $(skip_auto_restart) = no ]; then
if [ -f /var/lock/subsys/apache ]; then
/sbin/service apache reload 1>&2 || :;
fi
fi };
fi
apache <
2.2.0
/bin/sh
if [ "$1" = "1" ] && [ "$2" = "1" ]; then
/usr/sbin/webapp register httpd horde-forwards
fi
# reload webserver if the config symlink is there and skip reload if webserver is upgraded
if [ -L /etc/httpd/webapps.d/horde-forwards.conf ] && [ "$2" -lt "2" ]; then
{
skip_auto_restart() {
[ -f /etc/sysconfig/rpm ] && . /etc/sysconfig/rpm
[ -f /etc/sysconfig/httpd ] && . /etc/sysconfig/httpd
echo ${RPM_SKIP_AUTO_RESTART:-no}
};
if [ $(skip_auto_restart) = no ]; then
if [ -f /var/lock/subsys/httpd ]; then
/sbin/service httpd reload 1>&2 || :;
fi
fi };
fi
apache-base
/bin/sh
# remove link if either of the packages are gone
if [ -n "" ] || [ "$1" = "0" ] || [ "$2" = "0" ] && [ -L /etc/httpd/webapps.d/horde-forwards.conf ]; then
/usr/sbin/webapp unregister httpd horde-forwards
{
skip_auto_restart() {
[ -f /etc/sysconfig/rpm ] && . /etc/sysconfig/rpm
[ -f /etc/sysconfig/httpd ] && . /etc/sysconfig/httpd
echo ${RPM_SKIP_AUTO_RESTART:-no}
};
if [ $(skip_auto_restart) = no ]; then
if [ -f /var/lock/subsys/httpd ]; then
/sbin/service httpd reload 1>&2 || :;
fi
fi };
fi