]> git.pld-linux.org Git - packages/Zope.git/commitdiff
- revert user changes
authorpascalek <pascalek@pld-linux.org>
Sat, 17 May 2003 06:36:35 +0000 (06:36 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    Zope.spec -> 1.18

Zope.spec

index 581ec8f87134587b5abd8d4fb342a593b5a9c713..7c31259f097c416c8338a49ee2a02b8a25218ef8 100644 (file)
--- a/Zope.spec
+++ b/Zope.spec
@@ -21,7 +21,12 @@ Source10:    http://www.zope.org/Documentation/Books/ZopeBook/current/ZopeBook.tgz
 URL:           http://www.zope.org/
 BuildRequires: python-devel >= 2.2
 PreReq:                rc-scripts
-Requires(pre): user-zope
+Requires(pre): /usr/bin/getgid
+Requires(pre): /bin/id
+Requires(pre): /usr/sbin/groupadd
+Requires(pre): /usr/sbin/useradd
+Requires(postun):      /usr/sbin/userdel
+Requires(postun):      /usr/sbin/groupdel
 Requires(post,preun):  /sbin/chkconfig
 Requires:      logrotate
 Requires:      python-modules >= 2.2
@@ -113,6 +118,16 @@ touch $RPM_BUILD_ROOT/var/log/zope
 %clean
 rm -rf $RPM_BUILD_ROOT
 
+%pre
+if [ -z "`getgid zope`" ]; then
+       echo "Making group zope"
+       /usr/sbin/groupadd -r -f zope
+fi
+if [ -z "`id -u zope 2>/dev/null`" ]; then
+       echo "Making user zope"
+       /usr/sbin/useradd -r -d /var/lib/zope -s /bin/false -c "Zope User" -g zope zope
+fi
+
 %post
 /sbin/chkconfig --add zope
 if [ -f /var/lock/subsys/zope ]; then
@@ -130,6 +145,14 @@ if [ "$1" = "0" ]; then
        /sbin/chkconfig --del zope
 fi
 
+%postun
+if [ "$1" = "0" ] ; then
+       echo "Removing user zope"
+       /usr/sbin/userdel zope >/dev/null 2>&1 || :
+       echo "Removing group zope"
+       /usr/sbin/groupdel zope >/dev/null 2>&1 || :    
+fi
+
 %files
 %defattr(644,root,root,755)
 %doc doc/*.txt *.txt ZopeContentManagersGuide GuideToZSQL Tutorial ZopeDevelopersGuide ZopeAdminGuide ZopeBook
This page took 0.053122 seconds and 4 git commands to generate.