]> git.pld-linux.org Git - packages/ApacheJServ.git/commitdiff
- cleanups, hacks to get -init package ran as different user
authorElan Ruusamäe <glen@pld-linux.org>
Sat, 22 Oct 2005 11:36:21 +0000 (11:36 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    ApacheJServ.spec -> 1.46

ApacheJServ.spec

index ce6ac458d4b17a98b6631934618bb54393e12faa..c323e9dd038eb03f93b02b0f7d58502018c831d7 100644 (file)
@@ -10,7 +10,7 @@ Summary:      Servlet engine with support for the leading web server
 Summary(pl):   Silnik serwletów ze wsparciem dla wiod±cego serwera WWW
 Name:          ApacheJServ
 Version:       1.1.2
-Release:       0.37
+Release:       0.52
 License:       freely distributable & usable (JServ), LGPL (JSDK)
 Group:         Networking/Daemons
 Source0:       http://java.apache.org/jserv/dist/%{name}-%{version}.tar.gz
@@ -88,6 +88,8 @@ Requires(pre):  /usr/bin/getgid
 Requires(pre):  /usr/sbin/useradd
 Requires(pre):  /usr/sbin/groupadd
 Requires(post,preun):  rc-scripts
+Requires(triggerin):   sed >= 4.0
+Requires:      rc-scripts
 
 %description init
 JServ initscript for standalone mode.
@@ -189,6 +191,7 @@ rm -rf jsdk-doc/{COPYING.LIB,CVS} jsdk-doc/apidoc/CVS
 
 # duplicate
 rm -f $RPM_BUILD_ROOT%{_sysconfdir}/jserv.conf
+rm -rf $RPM_BUILD_ROOT/usr/docs
 
 %clean
 rm -rf $RPM_BUILD_ROOT
@@ -228,6 +231,19 @@ if [ "$1" = "0" ]; then
        %groupremove jserv
 fi
 
+%triggerin init -- apache1-mod_jserv
+if [ "$2" != 1 ]; then
+       exit 0
+fi
+# so, we have initscript and apache module, it means we turn off
+# automatic mode and switch to manual mode, and change jserv config
+# groups to jserv user
+MODE=$(awk '/^[\t ]*ApJServManual (on|off)/{print $2}' %{httpdconf}/conf.d/??_mod_jserv.conf)
+if [ "$MODE" = off ]; then
+       chgrp jserv %{_sysconfdir}/{{jserv,zone}.properties,jserv.secret.key}
+       sed -i -e '/^[   ]*ApJServManual[        ]\+/s/off/on/i' %{httpdconf}/conf.d/??_mod_jserv.conf
+fi
+
 %files
 %defattr(644,root,root,755)
 %doc LICENSE README
This page took 0.096757 seconds and 4 git commands to generate.