/usr/sbin/webapp register %1 %2\
fi\
# reload webserver if the config symlink is there and skip reload if webserver is upgraded\
-if [ -L /etc/%1/webapps.d/%2.conf ] && [ "$2" -lt "2" ] && [ -f /var/lock/subsys/%1 ]; then\
- /etc/rc.d/init.d/%1 reload 1>&2\
+if [ -L /etc/%1/webapps.d/%2.conf ] && [ "$2" -lt "2" ]; then\
+ %{expand:%service %%1 reload}\
fi\
%{nil}
# remove link if either of the packages are gone \
if [ -n "%{-f:1}" ] || [ "$1" = "0" ] || [ "$2" = "0" ] && [ -L /etc/%1/webapps.d/%2.conf ]; then \
/usr/sbin/webapp unregister %1 %2\
- if [ -f /var/lock/subsys/%1 ]; then \
- /etc/rc.d/init.d/%1 reload 1>&2 \
- fi \
+ %{expand:%service %%1 reload}\
fi \
%{nil}