Author: rmeggins
Update of /cvs/dirsec/adminserver/pkg
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv1107/adminserver/pkg
Modified Files:
fedora-ds-admin.spec
Log Message:
for the 1.1.7 release
Index: fedora-ds-admin.spec
===================================================================
RCS file: /cvs/dirsec/adminserver/pkg/fedora-ds-admin.spec,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- fedora-ds-admin.spec 4 Sep 2008 14:44:45 -0000 1.4
+++ fedora-ds-admin.spec 31 Mar 2009 17:59:48 -0000 1.5
@@ -3,7 +3,7 @@
Summary: Fedora Administration Server (admin)
Name: fedora-ds-admin
-Version: 1.1.6
+Version: 1.1.7
Release: 1%{?dist}
License: GPLv2
URL:
http://directory.fedoraproject.org/
@@ -76,10 +76,54 @@
%clean
rm -rf $RPM_BUILD_ROOT
+%pre
+# save permission info in temp file
+# if upgrading
+if [ "$1" -gt 1 ] ; then
+ set -x
+ mydt=`date +%Y%m%d`
+ mytmpfile=${TMPDIR:-/tmp}/$mydt.$PPID
+ perm1=`stat --format=%%a %{_sysconfdir}/%{pkgname}/admin-serv 2> /dev/null`
+ if [ -z "$perm1" ] ; then
+ perm1=0
+ fi
+ own1=`stat --format=%%U:%%G %{_sysconfdir}/%{pkgname}/admin-serv 2> /dev/null`
+ if [ -z "$own1" ] ; then
+ own1=0
+ fi
+ perm2=`stat --format=%%a %{_sysconfdir}/%{pkgname}/admin-serv/console.conf 2>
/dev/null`
+ if [ -z "$perm2" ] ; then
+ perm2=0
+ fi
+ own2=`stat --format=%%U:%%G %{_sysconfdir}/%{pkgname}/admin-serv/console.conf 2>
/dev/null`
+ if [ -z "$own2" ] ; then
+ own2=0
+ fi
+ echo $perm1 $own1 $perm2 $own2 > $mytmpfile
+fi
+
%post
/sbin/chkconfig --add %{pkgname}-admin
/sbin/ldconfig
-
+# if installing for the first time, make sure the config
+# directory and file have the correct permissions
+# the setup script is used to "fix" these
+if [ "$1" -gt 1 ]; then
+ set -x
+ mydt=`date +%Y%m%d`
+ mytmpfile=${TMPDIR:-/tmp}/$mydt.$PPID
+ if [ ! -f $mytmpfile ] ; then
+ echo Error: upgrade temp file $mytmpfile not found
+ exit 1
+ fi
+ cat $mytmpfile | while read perm1 own1 perm2 own2 ; do
+ chmod $perm1 %{_sysconfdir}/%{pkgname}/admin-serv
+ chown $own1 %{_sysconfdir}/%{pkgname}/admin-serv
+ chmod $perm2 %{_sysconfdir}/%{pkgname}/admin-serv/console.conf
+ chown $own2 %{_sysconfdir}/%{pkgname}/admin-serv/console.conf
+ done
+ rm -f $mytmpfile
+fi
%preun
if [ $1 = 0 ]; then
@@ -100,8 +144,18 @@
%{_sbindir}/*
%{_libdir}/*.so.*
%{_libdir}/%{pkgname}
+%{_mandir}/man8/*
%changelog
+* Tue Mar 31 2009 Rich Megginson <rmeggins(a)redhat.com> - 1.1.7-1
+- this is the 1.1.7 release
+- added man pages for setup, migration, remove commands
+- better error handling for command line utilities
+- fixed remove from console
+- added remove-ds-admin.pl
+- added pre and post sections in order to preserve the permissions and ownerships
+- CVS tag FedoraDirSrvAdmin_1_1_7_RC1 FedoraDirSrvAdmin_1_1_7_RC1_20090331
+
* Mon Jul 14 2008 Rich Megginson <rmeggins(a)redhat.com> - 1.1.6-1
- This is for the fedora ds 1.1.2 release