[prev in list] [next in list] [prev in thread] [next in thread] 

List:       annvix-cvs
Subject:    [cvs] CVS commit in packages/samba on 2005/09/28 04:40:52
From:       cvsrep () annvix ! org
Date:       2005-09-28 4:40:54
Message-ID: E1EKTkU-0003F1-Pk () build ! annvix ! org
[Download RAW message or body]

Module name:   packages/samba
Changes by:    vdanen
Date:          2005/09/28 04:40:52

Commit log:
- add %post and %preun for swat
- execline run scripts
- simplify the winbindd script; admins need to know their stuff before
  they go adding daemons so don't baby them (aka get rid of the uid/gid
  checks)
- build peers.cdb in swat %post
- env dirs
- make smbd require nmbd; for now don't add a reverse require because it
  makes the new srv have fits

Index: nmbd.run
===================================================================
RCS file: /work/annvix/cvsroot/packages/samba/nmbd.run,v
retrieving revision 1.3.4.1
retrieving revision 1.3.4.2
diff -u -r1.3.4.1 -r1.3.4.2
--- nmbd.run	4 Sep 2005 05:02:49 -0000	1.3.4.1
+++ nmbd.run	28 Sep 2005 04:40:52 -0000	1.3.4.2
@@ -1,10 +1,11 @@
-#!/bin/sh
-PATH="/sbin:/usr/sbin:/bin:/usr/bin:$PATH"
+#!/bin/execlineb
 
-# this runs nmbd supervised
+/bin/fdmove -c 2 1
 
-. /usr/share/srv/functions
+/bin/export PATH "/sbin:/bin:/usr/sbin:/usr/bin"
 
-checkdepends smbd
+elglob -0 DEPENDS ./depends/*
 
-exec /usr/sbin/nmbd -F 2>&1
+/bin/if { /sbin/svwaitup -s 5 $DEPENDS }
+
+/usr/sbin/nmbd -F

Index: samba.spec
===================================================================
RCS file: /work/annvix/cvsroot/packages/samba/samba.spec,v
retrieving revision 1.3.4.6
retrieving revision 1.3.4.7
diff -u -r1.3.4.6 -r1.3.4.7
--- samba.spec	17 Sep 2005 06:36:08 -0000	1.3.4.6
+++ samba.spec	28 Sep 2005 04:40:52 -0000	1.3.4.7
@@ -9,7 +9,7 @@
 
 %define name		samba
 %define version		3.0.20
-%define release		3avx
+%define release		4avx
 
 %define smbldapver	0.8.8
 %define vscanver	0.3.6b
@@ -435,9 +435,14 @@
 ln -s %{_bindir}/smbspool %{buildroot}%{_libdir}/cups/backend/smb
 
 # ipsvd support
-mkdir -p %{buildroot}%{_srvdir}/swat/log
+mkdir -p %{buildroot}%{_srvdir}/swat/{log,env,peers}
 install -m 0740 %{SOURCE11} %{buildroot}%{_srvdir}/swat/run
 install -m 0740 %{SOURCE12} %{buildroot}%{_srvdir}/swat/log/run
+touch %{buildroot}%{_srvdir}/swat/peers/0
+chmod 0640 %{buildroot}%{_srvdir}/swat/peers/0
+
+
+echo "901" >%{buildroot}%{_srvdir}/swat/env/PORT
 
 bzcat %{SOURCE10}> %{buildroot}%{_datadir}/%{name}/scripts/print-pdf
 bzcat %{SOURCE20}> %{buildroot}%{_datadir}/%{name}/scripts/smb-migrate
@@ -482,6 +487,9 @@
 # (sb) leave a README.avx.conf to explain what has been done
 bzcat %{SOURCE21} >%{buildroot}%{_datadir}/%{name}/README.avx.conf
 
+mkdir -p %{buildroot}%{_srvdir}/smbd/depends
+%_mkdepends smbd nmbd
+
 
 %clean
 [ -n "%{buildroot}" -a "%{buildroot}" != / ] && rm -rf %{buildroot}
@@ -603,10 +611,21 @@
 fi
 
 %preun server
-
 %_preun_srv smbd
 %_preun_srv nmbd
 
+
+%post swat
+%_post_srv swat
+pushd %{_srvdir}/swat >/dev/null 2>&1
+    ipsvd-cdb peers.cdb peers.cdb.tmp peers/
+popd >/dev/null 2>&1
+
+
+%preun swat
+%_preun_srv swat
+
+
 %post -n %{libname} -p /sbin/ldconfig
 %postun -n %{libname} -p /sbin/ldconfig
 
@@ -654,10 +673,12 @@
 
 %dir %attr(0750,root,admin) %{_srvdir}/smbd
 %dir %attr(0750,root,admin) %{_srvdir}/smbd/log
+%dir %attr(0750,root,admin) %{_srvdir}/smbd/depends
 %dir %attr(0750,root,admin) %{_srvdir}/nmbd
 %dir %attr(0750,root,admin) %{_srvdir}/nmbd/log
 %config(noreplace) %attr(0740,root,admin) %{_srvdir}/smbd/run
 %config(noreplace) %attr(0740,root,admin) %{_srvdir}/smbd/log/run
+%config(noreplace) %attr(0740,root,admin) %{_srvdir}/smbd/depends/nmbd
 %config(noreplace) %attr(0740,root,admin) %{_srvdir}/nmbd/run
 %config(noreplace) %attr(0740,root,admin) %{_srvdir}/nmbd/log/run
 
@@ -665,8 +686,12 @@
 %defattr(-,root,root)
 %dir %attr(0750,root,admin) %{_srvdir}/swat
 %dir %attr(0750,root,admin) %{_srvdir}/swat/log
+%dir %attr(0750,root,admin) %{_srvdir}/swat/env
+%dir %attr(0750,root,admin) %{_srvdir}/swat/peers
 %config(noreplace) %attr(0740,root,admin) %{_srvdir}/swat/run
 %config(noreplace) %attr(0740,root,admin) %{_srvdir}/swat/log/run
+%config(noreplace) %attr(0740,root,admin) %{_srvdir}/swat/peers/0
+%config(noreplace) %attr(0740,root,admin) %{_srvdir}/swat/env/PORT
 %{_sbindir}/swat
 %attr(-,root,root) %{_datadir}/swat/help/
 %attr(-,root,root) %{_datadir}/swat/images/
@@ -813,6 +838,17 @@
 
 
 %changelog
+* Tue Sep 27 2005 Vincent Danen <vdanen@annvix.org> 3.0.20-4avx
+- add %%post and %%preun for swat
+- execline run scripts
+- simplify the winbindd script; admins need to know their stuff before
+  they go adding daemons so don't baby them (aka get rid of the uid/gid
+  checks)
+- build peers.cdb in swat %%post
+- env dirs
+- make smbd require nmbd; for now don't add a reverse require because it
+  makes the new srv have fits
+
 * Fri Sep 16 2005 Vincent Danen <vdanen@annvix.org> 3.0.20-3avx
 - really apply P16
 - P17 and P18: more post-3.0.20 fixes

Index: smbd.run
===================================================================
RCS file: /work/annvix/cvsroot/packages/samba/smbd.run,v
retrieving revision 1.3.4.1
retrieving revision 1.3.4.2
diff -u -r1.3.4.1 -r1.3.4.2
--- smbd.run	4 Sep 2005 05:02:49 -0000	1.3.4.1
+++ smbd.run	28 Sep 2005 04:40:52 -0000	1.3.4.2
@@ -1,10 +1,11 @@
-#!/bin/sh
-PATH="/sbin:/usr/sbin:/bin:/usr/bin:$PATH"
+#!/bin/execlineb
 
-# this runs smbd supervised
+/bin/fdmove -c 2 1
 
-. /usr/share/srv/functions
+/bin/export PATH "/sbin:/bin:/usr/sbin:/usr/bin"
 
-checkdepends nmbd
+elglob -0 DEPENDS ./depends/*
 
-exec /usr/sbin/smbd -F 2>&1
+/bin/if { /sbin/svwaitup -s 5 $DEPENDS }
+
+/usr/sbin/smbd -F

Index: swat.run
===================================================================
RCS file: /work/annvix/cvsroot/packages/samba/swat.run,v
retrieving revision 1.3
retrieving revision 1.3.4.1
diff -u -r1.3 -r1.3.4.1
--- swat.run	29 Mar 2005 03:50:25 -0000	1.3
+++ swat.run	28 Sep 2005 04:40:52 -0000	1.3.4.1
@@ -1,7 +1,18 @@
-#!/bin/sh
-PATH="/sbin:/usr/sbin:/bin:/usr/bin:$PATH"
+#!/bin/execlineb
 
-# this runs swat limiting the server to a maximum of 30 simultaneous 
-# connections. swat.cdb is not required for the service to run
+/bin/fdmove -c 2 1
 
-exec /sbin/tcpsvd -c30 -v -llocalhost -i./peers 0 901 /usr/sbin/swat 2>&1
+/sbin/chpst -e /etc/sysconfig/env/tcpsvd/
+/sbin/chpst -e ./env/
+
+/bin/multisubstitute {
+    import -D "localhost" HOSTNAME
+    import -D 0 IP
+    import -D 2401 PORT
+    import -D 20 MAX_CONN
+    import -D 5 MAX_PER_HOST
+    import -D 20 MAX_BACKLOG
+}
+                        
+/sbin/tcpsvd -v -l $HOSTNAME -x peers.cdb -c $MAX_CONN -C "$MAX_PER_HOST" -b \
$MAX_BACKLOG $IP $PORT +    /usr/sbin/swat

Index: winbindd.run
===================================================================
RCS file: /work/annvix/cvsroot/packages/samba/winbindd.run,v
retrieving revision 1.3.4.1
retrieving revision 1.3.4.2
diff -u -r1.3.4.1 -r1.3.4.2
--- winbindd.run	4 Sep 2005 05:02:49 -0000	1.3.4.1
+++ winbindd.run	28 Sep 2005 04:40:52 -0000	1.3.4.2
@@ -1,15 +1,7 @@
-#!/bin/sh
-PATH="/sbin:/usr/sbin:/bin:/usr/bin:$PATH"
+#!/bin/execlineb
 
-# this runs winbindd supervised
+/bin/fdmove -c 2 1
 
-. /usr/share/srv/functions
+/bin/export PATH "/sbin:/bin:/usr/sbin:/usr/bin"
 
-if [ "`grep -i -E '(idmap|winbind) uid' /etc/samba/smb.conf | egrep -v [\#\;]`" -a \
                "`grep -i -E '(idmap|winbind) gid' /etc/samba/smb.conf | egrep -v \
                [\#\;]`" ]; then
-	RUNME=1
-else
-	echo "Winbind is not configured in /etc/samba/smb.conf, not starting!"
-	godown
-fi
-
-exec /usr/sbin/winbindd -F 2>&1
+/usr/sbin/winbindd -F


_______________________________________________
cvs mailing list
cvs@annvix.org
http://annvix.org/mailman/listinfo/cvs


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic