rpms/fetch-crl/EL-4 fetch-crl-randomwait.patch, NONE, 1.1 fetch-crl.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2
stevetraylen
stevetraylen at fedoraproject.org
Mon Feb 22 20:58:12 UTC 2010
- Previous message: rpms/evince/F-13 evince.spec,1.177,1.178 sources,1.69,1.70
- Next message: rpms/fetch-crl/EL-5 fetch-crl-randomwait.patch, NONE, 1.1 fetch-crl.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Author: stevetraylen
Update of /cvs/pkgs/rpms/fetch-crl/EL-4
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv24256/EL-4
Modified Files:
.cvsignore sources
Added Files:
fetch-crl-randomwait.patch fetch-crl.spec
Log Message:
Import all branches with 2.8.1-4.
fetch-crl-randomwait.patch:
edg-fetch-crl | 23 ++++++++++++++++++++++-
fetch-crl-cron.cron | 2 +-
2 files changed, 23 insertions(+), 2 deletions(-)
--- NEW FILE fetch-crl-randomwait.patch ---
diff -uNr fetch-crl-2.8.1.ORIG/edg-fetch-crl fetch-crl-2.8.1/edg-fetch-crl
--- fetch-crl-2.8.1.ORIG/edg-fetch-crl 2010-02-08 09:52:21.000000000 +0100
+++ fetch-crl-2.8.1/edg-fetch-crl 2010-02-11 22:59:59.182371636 +0100
@@ -19,6 +19,7 @@
# edg-fetch-crl [-l|--loc locationDirectory] #
# [-o|--out outputDirectory] [-q|--quiet] #
# [-a|--agingtolerance hours ] #
+# [-r|--randomwait #minutes ] #
# #
# Author: Fabio Hernandez #
# fabio at in2p3.fr #
@@ -40,6 +41,7 @@
# Jan 2009 - DG - new error codes (1=download error, 2=setup err #
# drop text in output, DEFAULTPATH support, &c. #
# Sep 2009 - DG/ST - new packaging and init scripts #
+# Feb 2010 - ST - Add --randomwait #minutes option.
# #
###############################################################################
@@ -270,6 +272,10 @@
echo " Also log messages and errors to syslog facility <fac>"
echo " Messages are logged at level DEBUG, errors at level ERR."
echo
+ echo " -r|--randomwait #minutes"
+ echo " Specifies maximum time in minutes the command will sleep"
+ echo " for before executing. Allows execution start to randomized"
+ echo
echo " Defaults can be set in the fetch-crl system configuration file"
echo " $FETCH_CRL_SYSCONFIG (resettable via the FETCH_CRL_SYSCONFIG environment"
echo " variable, see manual for details)."
@@ -536,7 +542,7 @@
#
# Parse the command line
#
-getoptResult=`${getopt} -o hl:o:qva:nf -a -l help,loc:,out:,quiet,verbose,agingtolerance,no-check-certificate,syslog-facility,check-server-certificate -n ${programName} -- "$@"`
+getoptResult=`${getopt} -o hl:o:qva:nfr: -a -l help,loc:,out:,quiet,verbose,agingtolerance,no-check-certificate,syslog-facility,check-server-certificate,randomwait -n ${programName} -- "$@"`
if [ $? != 0 ] ; then
ShowUsage
exit 2
@@ -554,6 +560,7 @@
-q|--quiet) verboseMode=0; shift ;;
-v|--verbose) verboseMode=1; shift ;;
-a|--agingtolerance) cRLAgingThreshold="$2"; shift 2 ;;
+ -r|--randomwait) RandomWait="$2"; shift 2 ;;
--) shift; break;;
*) echo ${programName}": internal error!" ; exit 2 ;;
esac
@@ -576,6 +583,20 @@
exit 0
fi
+#
+# Sleep for a random wait within a maximum if requested.
+#
+if [ "X${RandomWait}" != "X" ] ; then
+ timeStamp=`${date} +%Y%m%dT%H%M%S%z`
+ PrintInformation "Sleeping CRL retrieval process at ${timeStamp} for up to ${RandomWait} minutes"
+ sleep `expr ${RANDOM} % ${RandomWait}`m
+ if [ $? != 0 ] ; then
+ PrintError "Sleep of up to ${RandomWait} minutes failed..."
+ exit 2
+ fi
+fi
+
+
# give hint to syslog that we started, if syslog is enabled
timeStamp=`${date} +%Y%m%dT%H%M%S%z`
diff -uNr fetch-crl-2.8.1.ORIG/fetch-crl-cron.cron fetch-crl-2.8.1/fetch-crl-cron.cron
--- fetch-crl-2.8.1.ORIG/fetch-crl-cron.cron 2010-02-08 09:52:21.000000000 +0100
+++ fetch-crl-2.8.1/fetch-crl-cron.cron 2010-02-11 22:53:45.012352529 +0100
@@ -6,5 +6,5 @@
# Note the lock file not existing is success hence the the slightly odd logic
# below.
-22 */6 * * * root [ ! -f /var/lock/subsys/fetch-crl-cron ] || /usr/sbin/fetch-crl -a 24 --quiet
+22 */6 * * * root [ ! -f /var/lock/subsys/fetch-crl-cron ] || /usr/sbin/fetch-crl -r 20 -a 24 --quiet
--- NEW FILE fetch-crl.spec ---
%if %{?rhel}%{!?rhel:0} <= 5
%global _initddir %{_initrddir}
%endif
Name: fetch-crl
Version: 2.8.1
Release: 4%{?dist}
Summary: Downloads Certificate Revocation Lists
Group: Applications/System
License: EU Datagrid
URL: https://dist.eugridpma.info/distribution/util/%{name}
Source: https://dist.eugridpma.info/distribution/tests/%{name}-%{version}/%{name}-%{version}.tar.gz
# Adds a --randomwait option to command.
# Patch emailed upstream Feb 2010.
Patch0: %{name}-randomwait.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch: noarch
Requires: openssl
Requires: wget
Requires(post): chkconfig
Requires(preun): chkconfig
%description
This tool and associated cron entry ensure that Certificate Revocation
Lists (CRLs) are periodically retrieved from the web sites of the respective
Certification Authorities.
It assumes that the installed CA files follow the hash.crl_url convention.
%prep
%setup -q
%patch0 -p1
%build
%clean
rm -rf $RPM_BUILD_ROOT
%install
rm -rf $RPM_BUILD_ROOT
make install PREFIX=$RPM_BUILD_ROOT%{_usr} ETC=$RPM_BUILD_ROOT%{_sysconfdir}
mkdir -p $RPM_BUILD_ROOT%{_initddir}
install -p -m 755 $RPM_BUILD_ROOT%{_usr}/share/doc/%{name}-%{version}/%{name}-cron.init $RPM_BUILD_ROOT%{_initddir}/%{name}-cron
install -p -m 755 $RPM_BUILD_ROOT%{_usr}/share/doc/%{name}-%{version}/%{name}-boot.init $RPM_BUILD_ROOT%{_initddir}/%{name}-boot
mkdir $RPM_BUILD_ROOT%{_sysconfdir}/cron.d
install -p -m 644 $RPM_BUILD_ROOT%{_usr}/share/doc/%{name}-%{version}/%{name}-cron.cron $RPM_BUILD_ROOT%{_sysconfdir}/cron.d/%{name}
# Remove some files that have been duplicated as docs.
rm $RPM_BUILD_ROOT%{_defaultdocdir}/%{name}-%{version}/%{name}-boot.init
rm $RPM_BUILD_ROOT%{_defaultdocdir}/%{name}-%{version}/%{name}-cron.cron
rm $RPM_BUILD_ROOT%{_defaultdocdir}/%{name}-%{version}/%{name}-cron.init
rm $RPM_BUILD_ROOT%{_defaultdocdir}/%{name}-%{version}/%{name}.cron
rm $RPM_BUILD_ROOT%{_defaultdocdir}/%{name}-%{version}/%{name}.sysconfig
%post
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{name}-cron
/sbin/chkconfig --add %{name}-boot
%preun
if [ $1 = 0 ] ; then
/sbin/service %{name}-cron stop >/dev/null 2>&1
/sbin/service %{name}-boot stop >/dev/null 2>&1
/sbin/chkconfig --del %{name}-cron
/sbin/chkconfig --del %{name}-boot
fi
%files
%defattr(-,root,root,-)
%{_sbindir}/%{name}
%{_initddir}/%{name}-cron
%{_initddir}/%{name}-boot
%doc %{_mandir}/man8/%{name}.8.gz
%doc %{_defaultdocdir}/%{name}-%{version}
%config(noreplace) %{_sysconfdir}/%{name}.conf
%config(noreplace) %{_sysconfdir}/cron.d/%{name}
%changelog
* Mon Feb 22 2010 Steve Traylen <steve.traylen at cern.ch> - 2.8.1-4
- Correct URL again.
* Mon Feb 22 2010 Steve Traylen <steve.traylen at cern.ch> - 2.8.1-3
- Use consistant name macros throughout.
- Rename /etc/cron.d/fetch-crl.cron to /etc/cron.d/fetch-crl to
be compliant with some cron implentations.
- Remove dupicate files created in doc directory.
* Thu Feb 11 2010 Steve Traylen <steve.traylen at cern.ch> - 2.8.1-2
- Add patch to introduce --randomwait option.
- Make setup stage quiet.
- Change license string from EU DataGrid to EU Datagrid
- First version for Fedora/EPEL inclusion.
* Tue Sep 22 2009 David Groep <davidg at nikhef.nl>
Version 2.8.1 is more paranoid about the installed fetch-crl to catch OS faults
* Tue Sep 22 2009 David Groep <davidg at nikhef.nl>
Version 2.8.0 with new config file location, start-up scripts, and packaging
* Sun Jan 25 2009 David Groep <davidg at nikhef.nl>
Version 2.7.0 with new policies, download resiliancy, PATH support, etc
* Thu Oct 27 2005 David Groep <davidg at nikhef.nl>
Wget https downloads recognise our own trusted CA directory (by RomainW)
* Mon Feb 28 2005 David Groep <davidg at nikhef.nl>
Made into a relocatable RPM without the cronjob pre-installed
* Mon Dec 6 2004 David Groep <davidg at nikhef.nl>
Copied to EUGridPMA site
* Wed Jan 15 2003 Steve Traylen <s.m.traylen at rl.ac.uk>
Initial Build
Index: .cvsignore
===================================================================
RCS file: /cvs/pkgs/rpms/fetch-crl/EL-4/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -p -r1.1 -r1.2
--- .cvsignore 22 Feb 2010 20:14:01 -0000 1.1
+++ .cvsignore 22 Feb 2010 20:58:11 -0000 1.2
@@ -0,0 +1 @@
+fetch-crl-2.8.1.tar.gz
Index: sources
===================================================================
RCS file: /cvs/pkgs/rpms/fetch-crl/EL-4/sources,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -p -r1.1 -r1.2
--- sources 22 Feb 2010 20:14:01 -0000 1.1
+++ sources 22 Feb 2010 20:58:12 -0000 1.2
@@ -0,0 +1 @@
+2a74ac572e4a5079b07ed4c9507c27b4 fetch-crl-2.8.1.tar.gz
- Previous message: rpms/evince/F-13 evince.spec,1.177,1.178 sources,1.69,1.70
- Next message: rpms/fetch-crl/EL-5 fetch-crl-randomwait.patch, NONE, 1.1 fetch-crl.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the scm-commits
mailing list