Message ID | 20161222095236.6504-1-ligs@dtdream.com |
---|---|
State | Accepted |
Headers | show |
On Thu, Dec 22, 2016 at 1:52 AM, Guoshuai Li <ligs@dtdream.com> wrote: > The directory "/usr/lib/ocf/resource.d/ovn/" is only removed on uninstall > and can not be removed while upgrading > > Signed-off-by: Guoshuai Li <ligs@dtdream.com> > Thanks, pushed to master.
diff --git a/rhel/openvswitch-fedora.spec.in b/rhel/openvswitch-fedora.spec.in index 6b2f910..3499d63 100644 --- a/rhel/openvswitch-fedora.spec.in +++ b/rhel/openvswitch-fedora.spec.in @@ -355,7 +355,10 @@ ln -sf %{_datadir}/openvswitch/scripts/ovndb-servers.ocf /usr/lib/ocf/resource.d %endif %postun ovn-common -rm -rf /usr/lib/ocf/resource.d/ovn +if [ $1 -eq 0 ] ; then + # Package removal, not upgrade + rm -rf /usr/lib/ocf/resource.d/ovn +fi %postun ovn-central %if 0%{?systemd_postun_with_restart:1}
The directory "/usr/lib/ocf/resource.d/ovn/" is only removed on uninstall and can not be removed while upgrading Signed-off-by: Guoshuai Li <ligs@dtdream.com> --- rhel/openvswitch-fedora.spec.in | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)