SPECS: php-fcgi-init.spec - provide http user as lighttpd provides...

glen glen at pld-linux.org
Thu Jul 20 00:48:41 CEST 2006


Author: glen                         Date: Wed Jul 19 22:48:41 2006 GMT
Module: SPECS                         Tag: HEAD
---- Log message:
- provide http user as lighttpd provides only group

---- Files affected:
SPECS:
   php-fcgi-init.spec (1.6 -> 1.7) 

---- Diffs:

================================================================
Index: SPECS/php-fcgi-init.spec
diff -u SPECS/php-fcgi-init.spec:1.6 SPECS/php-fcgi-init.spec:1.7
--- SPECS/php-fcgi-init.spec:1.6	Tue Mar 14 17:44:18 2006
+++ SPECS/php-fcgi-init.spec	Thu Jul 20 00:48:36 2006
@@ -3,16 +3,20 @@
 Summary(pl):	Skrypt do uruchamiania i zatrzymywania procesów FastCGI PHP
 Name:		php-fcgi-init
 Version:	0.1
-Release:	2
+Release:	2.1
 License:	BSD-like
 Group:		Networking/Daemons
 Source0:	php-fcgi.init
 Source1:	php-fcgi.sysconfig
 BuildRequires:	rpmbuild(macros) >= 1.268
 Requires(post,preun):	/sbin/chkconfig
+Requires(postun):	/usr/sbin/userdel
+Requires(pre):	/bin/id
+Requires(pre):	/usr/sbin/useradd
 Requires:	php-fcgi
 Requires:	rc-scripts
 Requires:	spawn-fcgi
+Provides:	user(http)
 BuildArch:	noarch
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
@@ -34,6 +38,9 @@
 %clean
 rm -rf $RPM_BUILD_ROOT
 
+%pre
+%useradd -u 51 -r -s /bin/false -c "HTTP User" -g http http
+
 %post
 /sbin/chkconfig --add php-fcgi
 %service php-fcgi restart "PHP FastCGI"
@@ -44,6 +51,11 @@
 	/sbin/chkconfig --del php-fcgi
 fi
 
+%postun
+if [ "$1" = "0" ]; then
+	%userremove http
+fi
+
 %files
 %defattr(644,root,root,755)
 %attr(754,root,root) /etc/rc.d/init.d/php-fcgi
@@ -55,6 +67,9 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.7  2006/07/19 22:48:36  glen
+- provide http user as lighttpd provides only group
+
 Revision 1.6  2006/03/14 16:44:18  glen
 - use %service
 - updated init script and config
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/SPECS/php-fcgi-init.spec?r1=1.6&r2=1.7&f=u



More information about the pld-cvs-commit mailing list