[openstack-glance/el6: 3/3] restart the glance services on upgrade

Pádraig Brady pbrady at fedoraproject.org
Mon May 13 14:31:43 UTC 2013


commit b99af77485c7982b54f6d76a172948e0b417c112
Author: Pádraig Brady <P at draigBrady.com>
Date:   Mon May 13 15:27:40 2013 +0100

    restart the glance services on upgrade

 openstack-glance.spec |    9 +++++++++
 1 files changed, 9 insertions(+), 0 deletions(-)
---
diff --git a/openstack-glance.spec b/openstack-glance.spec
index 30aae26..3decb3a 100644
--- a/openstack-glance.spec
+++ b/openstack-glance.spec
@@ -238,6 +238,14 @@ if [ $1 = 0 ] ; then
     /sbin/chkconfig --del openstack-glance-scrubber
 fi
 
+%postun
+if [ $1 -ge 1 ] ; then
+    # Package upgrade, not uninstall
+    for svc in api registry scrubber; do
+        /sbin/service openstack-glance-${svc} condrestart > /dev/null 2>&1 || :
+    done
+fi
+
 %files
 %doc README.rst
 %{_bindir}/glance-api
@@ -285,6 +293,7 @@ fi
 * Mon May 13 2013 Pádraig Brady <P at draigBrady.com> 2012.2.4-2
 - Update to stable release 2012.2.4
 - Add the scrubber service for deferred image deletion
+- Restart the glance services on upgrade
 
 * Mon May 13 2013 Pádraig Brady <P at draigBrady.com> 2012.2.3-2
 - Avoid issue with crypto compat patch (#906051)


More information about the scm-commits mailing list