- Rebase and add fence-virt subpackages
Resolves: rhbz#1965988
This commit is contained in:
parent
fdb09b4649
commit
1e647dc3e6
@ -1,6 +1,6 @@
|
||||
diff --color -uNr a/agents/azure_arm/fence_azure_arm.py b/agents/azure_arm/fence_azure_arm.py
|
||||
--- a/agents/azure_arm/fence_azure_arm.py 2020-06-30 11:26:43.000000000 +0200
|
||||
+++ b/agents/azure_arm/fence_azure_arm.py 2021-05-19 11:27:45.861202774 +0200
|
||||
+++ b/agents/azure_arm/fence_azure_arm.py 2021-06-03 13:16:16.547120822 +0200
|
||||
@@ -1,6 +1,11 @@
|
||||
#!@PYTHON@ -tt
|
||||
|
||||
@ -16,7 +16,7 @@ diff --color -uNr a/agents/azure_arm/fence_azure_arm.py b/agents/azure_arm/fence
|
||||
import xml.etree.ElementTree as ET
|
||||
diff --color -uNr a/agents/hpblade/fence_hpblade.py b/agents/hpblade/fence_hpblade.py
|
||||
--- a/agents/hpblade/fence_hpblade.py 2019-08-16 10:55:11.000000000 +0200
|
||||
+++ b/agents/hpblade/fence_hpblade.py 2021-05-19 11:28:04.683250655 +0200
|
||||
+++ b/agents/hpblade/fence_hpblade.py 2021-06-03 13:16:16.547120822 +0200
|
||||
@@ -8,7 +8,11 @@
|
||||
#####
|
||||
|
||||
@ -32,7 +32,7 @@ diff --color -uNr a/agents/hpblade/fence_hpblade.py b/agents/hpblade/fence_hpbla
|
||||
from fencing import *
|
||||
diff --color -uNr a/agents/ilo/fence_ilo.py b/agents/ilo/fence_ilo.py
|
||||
--- a/agents/ilo/fence_ilo.py 2019-02-04 09:45:05.000000000 +0100
|
||||
+++ b/agents/ilo/fence_ilo.py 2021-05-19 11:28:11.081266930 +0200
|
||||
+++ b/agents/ilo/fence_ilo.py 2021-06-03 13:16:16.547120822 +0200
|
||||
@@ -11,7 +11,12 @@
|
||||
## iLO2 / firmware 1.50 / RIBCL 2.22
|
||||
#####
|
||||
@ -49,7 +49,7 @@ diff --color -uNr a/agents/ilo/fence_ilo.py b/agents/ilo/fence_ilo.py
|
||||
sys.path.append("@FENCEAGENTSLIBDIR@")
|
||||
diff --color -uNr a/agents/ldom/fence_ldom.py b/agents/ldom/fence_ldom.py
|
||||
--- a/agents/ldom/fence_ldom.py 2019-02-04 09:45:05.000000000 +0100
|
||||
+++ b/agents/ldom/fence_ldom.py 2021-05-19 11:28:25.345303213 +0200
|
||||
+++ b/agents/ldom/fence_ldom.py 2021-06-03 13:16:16.547120822 +0200
|
||||
@@ -7,7 +7,12 @@
|
||||
##
|
||||
#####
|
||||
@ -65,9 +65,9 @@ diff --color -uNr a/agents/ldom/fence_ldom.py b/agents/ldom/fence_ldom.py
|
||||
sys.path.append("@FENCEAGENTSLIBDIR@")
|
||||
from fencing import *
|
||||
diff --color -uNr a/agents/Makefile.am b/agents/Makefile.am
|
||||
--- a/agents/Makefile.am 2019-10-18 17:18:32.000000000 +0200
|
||||
+++ b/agents/Makefile.am 2021-05-19 11:26:46.202051020 +0200
|
||||
@@ -108,10 +108,10 @@
|
||||
--- a/agents/Makefile.am 2021-03-16 12:26:37.000000000 +0100
|
||||
+++ b/agents/Makefile.am 2021-06-03 13:16:16.547120822 +0200
|
||||
@@ -112,10 +112,10 @@
|
||||
cisco_mds/fence_cisco_mds.delay-check: cisco_mds/fence_cisco_mds
|
||||
$(eval INPUT=$(subst .delay-check,,$@))
|
||||
FENCE_TEST_ARGS_CISCO_MDS=$$(printf '$(FENCE_TEST_ARGS)' | sed 's#port=1#port=fc1/1#'); \
|
||||
@ -82,7 +82,7 @@ diff --color -uNr a/agents/Makefile.am b/agents/Makefile.am
|
||||
include $(top_srcdir)/make/fencebuild.mk
|
||||
diff --color -uNr a/agents/netio/fence_netio.py b/agents/netio/fence_netio.py
|
||||
--- a/agents/netio/fence_netio.py 2019-02-04 09:45:05.000000000 +0100
|
||||
+++ b/agents/netio/fence_netio.py 2021-05-19 11:28:30.244315675 +0200
|
||||
+++ b/agents/netio/fence_netio.py 2021-06-03 13:16:16.547120822 +0200
|
||||
@@ -1,6 +1,11 @@
|
||||
#!@PYTHON@ -tt
|
||||
|
||||
@ -98,7 +98,7 @@ diff --color -uNr a/agents/netio/fence_netio.py b/agents/netio/fence_netio.py
|
||||
from fencing import *
|
||||
diff --color -uNr a/agents/raritan/fence_raritan.py b/agents/raritan/fence_raritan.py
|
||||
--- a/agents/raritan/fence_raritan.py 2019-08-16 10:55:11.000000000 +0200
|
||||
+++ b/agents/raritan/fence_raritan.py 2021-05-19 11:28:35.849329933 +0200
|
||||
+++ b/agents/raritan/fence_raritan.py 2021-06-03 13:16:16.547120822 +0200
|
||||
@@ -1,6 +1,11 @@
|
||||
#!@PYTHON@ -tt
|
||||
|
||||
@ -114,7 +114,7 @@ diff --color -uNr a/agents/raritan/fence_raritan.py b/agents/raritan/fence_rarit
|
||||
from fencing import *
|
||||
diff --color -uNr a/agents/sanbox2/fence_sanbox2.py b/agents/sanbox2/fence_sanbox2.py
|
||||
--- a/agents/sanbox2/fence_sanbox2.py 2019-02-11 13:05:48.000000000 +0100
|
||||
+++ b/agents/sanbox2/fence_sanbox2.py 2021-05-19 11:28:40.731342352 +0200
|
||||
+++ b/agents/sanbox2/fence_sanbox2.py 2021-06-03 13:16:16.547120822 +0200
|
||||
@@ -8,7 +8,12 @@
|
||||
## +-----------------+---------------------------+
|
||||
#####
|
||||
@ -131,7 +131,7 @@ diff --color -uNr a/agents/sanbox2/fence_sanbox2.py b/agents/sanbox2/fence_sanbo
|
||||
sys.path.append("@FENCEAGENTSLIBDIR@")
|
||||
diff --color -uNr a/agents/vmware/fence_vmware.py b/agents/vmware/fence_vmware.py
|
||||
--- a/agents/vmware/fence_vmware.py 2019-02-04 09:45:05.000000000 +0100
|
||||
+++ b/agents/vmware/fence_vmware.py 2021-05-19 11:28:47.502359575 +0200
|
||||
+++ b/agents/vmware/fence_vmware.py 2021-06-03 13:16:16.547120822 +0200
|
||||
@@ -22,7 +22,12 @@
|
||||
# VMware vCenter 4.0.0
|
||||
#
|
||||
@ -148,8 +148,8 @@ diff --color -uNr a/agents/vmware/fence_vmware.py b/agents/vmware/fence_vmware.p
|
||||
sys.path.append("@FENCEAGENTSLIBDIR@")
|
||||
diff --color -uNr a/agents/wti/fence_wti.py b/agents/wti/fence_wti.py
|
||||
--- a/agents/wti/fence_wti.py 2019-02-04 09:45:05.000000000 +0100
|
||||
+++ b/agents/wti/fence_wti.py 2021-05-19 11:28:52.741372903 +0200
|
||||
@@ -11,7 +11,12 @@
|
||||
+++ b/agents/wti/fence_wti.py 2021-06-03 13:17:33.435380703 +0200
|
||||
@@ -11,12 +11,21 @@
|
||||
## WTI IPS-800-CE v1.40h (no username) ('list' tested)
|
||||
#####
|
||||
|
||||
@ -163,9 +163,19 @@ diff --color -uNr a/agents/wti/fence_wti.py b/agents/wti/fence_wti.py
|
||||
import atexit
|
||||
import time
|
||||
sys.path.append("@FENCEAGENTSLIBDIR@")
|
||||
from fencing import *
|
||||
-from fencing import fspawn, fail, fail_usage, EC_LOGIN_DENIED
|
||||
+from fencing import fail, fail_usage, EC_LOGIN_DENIED
|
||||
+try:
|
||||
+ from fencing import fspawn
|
||||
+except ImportError:
|
||||
+ pass
|
||||
|
||||
def get_listing(conn, options, listing_command):
|
||||
listing = ""
|
||||
diff --color -uNr a/lib/fencing.py.py b/lib/fencing.py.py
|
||||
--- a/lib/fencing.py.py 2020-11-05 14:58:07.000000000 +0100
|
||||
+++ b/lib/fencing.py.py 2021-05-19 11:59:36.679118542 +0200
|
||||
--- a/lib/fencing.py.py 2021-06-03 10:34:00.000000000 +0200
|
||||
+++ b/lib/fencing.py.py 2021-06-03 13:16:16.548120826 +0200
|
||||
@@ -1,7 +1,12 @@
|
||||
#!@PYTHON@ -tt
|
||||
|
||||
@ -238,7 +248,7 @@ diff --color -uNr a/lib/fencing.py.py b/lib/fencing.py.py
|
||||
extra_args=None, logfile=None, cwd=None, env=None, **kwargs):
|
||||
diff --color -uNr a/lib/fencing_snmp.py.py b/lib/fencing_snmp.py.py
|
||||
--- a/lib/fencing_snmp.py.py 2019-02-04 09:45:05.000000000 +0100
|
||||
+++ b/lib/fencing_snmp.py.py 2021-05-19 11:37:59.446734969 +0200
|
||||
+++ b/lib/fencing_snmp.py.py 2021-06-03 13:16:16.548120826 +0200
|
||||
@@ -2,7 +2,13 @@
|
||||
|
||||
# For example of use please see fence_cisco_mds
|
||||
@ -256,7 +266,7 @@ diff --color -uNr a/lib/fencing_snmp.py.py b/lib/fencing_snmp.py.py
|
||||
from fencing import fail, fail_usage, EC_TIMED_OUT, run_delay, frun
|
||||
diff --color -uNr a/make/agentpycheck.mk b/make/agentpycheck.mk
|
||||
--- a/make/agentpycheck.mk 2020-06-30 11:26:43.000000000 +0200
|
||||
+++ b/make/agentpycheck.mk 2021-05-19 11:26:46.203051022 +0200
|
||||
+++ b/make/agentpycheck.mk 2021-06-03 13:16:16.548120826 +0200
|
||||
@@ -9,34 +9,34 @@
|
||||
|
||||
%.xml-check: %.8
|
||||
@ -302,8 +312,8 @@ diff --color -uNr a/make/agentpycheck.mk b/make/agentpycheck.mk
|
||||
sed -e 's/ rha:description=/ description=/g' -e 's/ rha:name=/ name=/g' | \
|
||||
xmllint --nsclean --noout -; \
|
||||
diff --color -uNr a/make/fencebuild.mk b/make/fencebuild.mk
|
||||
--- a/make/fencebuild.mk 2020-11-25 19:41:40.000000000 +0100
|
||||
+++ b/make/fencebuild.mk 2021-05-19 11:26:46.203051022 +0200
|
||||
--- a/make/fencebuild.mk 2021-03-16 09:32:22.000000000 +0100
|
||||
+++ b/make/fencebuild.mk 2021-06-03 13:16:16.548120826 +0200
|
||||
@@ -34,10 +34,10 @@
|
||||
> $@
|
||||
|
||||
@ -317,7 +327,7 @@ diff --color -uNr a/make/fencebuild.mk b/make/fencebuild.mk
|
||||
cp -f $(@) $(@D)/$$x; \
|
||||
$(MAKE) $(@D)/$$x.8; \
|
||||
done
|
||||
@@ -66,7 +66,7 @@
|
||||
@@ -64,7 +64,7 @@
|
||||
fi
|
||||
for p in $(TARGET); do \
|
||||
dir=`dirname $$p`; \
|
||||
@ -326,7 +336,7 @@ diff --color -uNr a/make/fencebuild.mk b/make/fencebuild.mk
|
||||
echo " $(INSTALL_SCRIPT) $$dir/$$x '$(DESTDIR)$(sbindir)'"; \
|
||||
$(INSTALL_SCRIPT) $$dir/$$x "$(DESTDIR)$(sbindir)" || exit $$?; \
|
||||
echo " $(INSTALL_DATA) '$$dir/$$x.8' '$(DESTDIR)$(man8dir)'"; \
|
||||
@@ -76,7 +76,7 @@
|
||||
@@ -74,7 +74,7 @@
|
||||
|
||||
uninstall-hook: $(TARGET)
|
||||
files=`for p in $(TARGET); do \
|
||||
@ -336,8 +346,8 @@ diff --color -uNr a/make/fencebuild.mk b/make/fencebuild.mk
|
||||
rm -f "$(DESTDIR)$(sbindir)/$$x"; \
|
||||
echo " rm -f '$(DESTDIR)$(man8dir)/$$x.8'"; \
|
||||
diff --color -uNr a/make/fenceman.mk b/make/fenceman.mk
|
||||
--- a/make/fenceman.mk 2019-02-04 09:45:05.000000000 +0100
|
||||
+++ b/make/fenceman.mk 2021-05-19 11:26:46.203051022 +0200
|
||||
--- a/make/fenceman.mk 2021-03-11 16:10:15.000000000 +0100
|
||||
+++ b/make/fenceman.mk 2021-06-03 13:16:16.548120826 +0200
|
||||
@@ -1,6 +1,6 @@
|
||||
%.8: % $(top_srcdir)/lib/fence2man.xsl
|
||||
set -e && \
|
||||
|
@ -8,8 +8,8 @@
|
||||
|
||||
Name: fence-agents
|
||||
Summary: Set of unified programs capable of host isolation ("fencing")
|
||||
Version: 4.7.1
|
||||
Release: 11%{?alphatag:.%{alphatag}}%{?dist}
|
||||
Version: 4.9.0
|
||||
Release: 1%{?alphatag:.%{alphatag}}%{?dist}
|
||||
License: GPLv2+ and LGPLv2+
|
||||
URL: https://github.com/ClusterLabs/fence-agents
|
||||
Source0: https://fedorahosted.org/releases/f/e/fence-agents/%{name}-%{version}.tar.gz
|
||||
@ -106,15 +106,14 @@ Source1073: pexpect-4.8.0-py2.py3-none-any.whl
|
||||
Source1074: ptyprocess-0.7.0-py2.py3-none-any.whl
|
||||
### END ###
|
||||
|
||||
Patch0: fence_gce-google-auth-oauthlib-support.patch
|
||||
Patch1: ha-cloud-support-aliyun.patch
|
||||
Patch2: ha-cloud-support-aws.patch
|
||||
Patch3: ha-cloud-support-azure.patch
|
||||
Patch4: ha-cloud-support-google.patch
|
||||
Patch5: ha-cloud-support-openstack.patch
|
||||
Patch6: bundled-pexpect.patch
|
||||
Patch0: ha-cloud-support-aliyun.patch
|
||||
Patch1: ha-cloud-support-aws.patch
|
||||
Patch2: ha-cloud-support-azure.patch
|
||||
Patch3: ha-cloud-support-google.patch
|
||||
Patch4: ha-cloud-support-openstack.patch
|
||||
Patch5: bundled-pexpect.patch
|
||||
|
||||
%global supportedagents amt_ws apc apc_snmp bladecenter brocade cisco_mds cisco_ucs compute drac5 eaton_snmp emerson eps evacuate hpblade ibmblade ifmib ilo ilo_moonshot ilo_mp ilo_ssh intelmodular ipdu ipmilan kdump lpar mpath redfish rhevm rsa rsb sbd scsi vmware_rest vmware_soap wti
|
||||
%global supportedagents amt_ws apc apc_snmp bladecenter brocade cisco_mds cisco_ucs compute drac5 eaton_snmp emerson eps evacuate hpblade ibmblade ifmib ilo ilo_moonshot ilo_mp ilo_ssh intelmodular ipdu ipmilan kdump lpar mpath redfish rhevm rsa rsb sbd scsi virt vmware_rest vmware_soap wti
|
||||
%ifarch x86_64
|
||||
%global testagents virsh heuristics_ping aliyun aws azure_arm gce
|
||||
%endif
|
||||
@ -160,6 +159,7 @@ fence-agents-rsa \\
|
||||
fence-agents-rsb \\
|
||||
fence-agents-sbd \\
|
||||
fence-agents-scsi \\
|
||||
fence-virt \\
|
||||
fence-agents-vmware-rest \\
|
||||
fence-agents-vmware-soap \\
|
||||
fence-agents-wti \\
|
||||
@ -176,8 +176,7 @@ EOF)
|
||||
|
||||
# Build dependencies
|
||||
## general
|
||||
BuildRequires: autoconf automake libtool
|
||||
BuildRequires: make
|
||||
BuildRequires: autoconf automake libtool make
|
||||
## compiled code (-kdump)
|
||||
BuildRequires: gcc
|
||||
## man pages generating
|
||||
@ -201,13 +200,31 @@ BuildRequires: python-pycurl python-requests
|
||||
BuildRequires: python-suds openwsman-python
|
||||
%endif
|
||||
|
||||
# fence-virt
|
||||
%if 0%{?suse_version}
|
||||
%define nss_devel mozilla-nss-devel
|
||||
%define nspr_devel mozilla-nspr-devel
|
||||
%define systemd_units systemd
|
||||
%else
|
||||
%define nss_devel nss-devel
|
||||
%define nspr_devel nspr-devel
|
||||
%define systemd_units systemd-units
|
||||
%endif
|
||||
|
||||
BuildRequires: corosynclib-devel libvirt-devel
|
||||
BuildRequires: libxml2-devel %{nss_devel} %{nspr_devel}
|
||||
BuildRequires: flex bison libuuid-devel
|
||||
BuildRequires: %{systemd_units}
|
||||
|
||||
|
||||
# turn off the brp-python-bytecompile script
|
||||
# (for F28+ or equivalent, the latter is the preferred form)
|
||||
%global __os_install_post %(echo '%{__os_install_post}' | sed -e 's!/usr/lib[^[:space:]]*/brp-python-bytecompilespace:.*$!!g')
|
||||
#undefine __brp_python_bytecompile
|
||||
|
||||
%prep
|
||||
%autosetup -b0 -p1
|
||||
%setup -q -n %{name}-%{version}%{?rcver:%{rcver}}%{?numcomm:.%{numcomm}}%{?alphatag:-%{alphatag}}%{?dirty:-%{dirty}}
|
||||
%autopatch -p1
|
||||
# prevent compilation of something that won't get used anyway
|
||||
sed -i.orig 's|FENCE_ZVM=1|FENCE_ZVM=0|' configure.ac
|
||||
|
||||
@ -226,21 +243,25 @@ done
|
||||
sed -i -e "/^import awscli.clidriver/isys.path.insert(0, '/usr/lib/%{name}/support/aws')" support/aws/bin/aws
|
||||
%endif
|
||||
|
||||
if [ -z "$PYTHON " ]; then
|
||||
%if 0%{?fedora} || 0%{?centos} > 7 || 0%{?rhel} > 7 || 0%{?suse_version}
|
||||
PYTHON="%{__python3}"
|
||||
fi
|
||||
%endif
|
||||
|
||||
./autogen.sh
|
||||
%{configure} PYTHONPATH="support/aliyun:support/aws:support/azure:support/google:support/openstack:support/pexpect" --with-agents='%{supportedagents} %{testagents}'
|
||||
%{configure} --disable-libvirt-qmf-plugin PYTHONPATH="support/aliyun:support/aws:support/azure:support/google:support/openstack:support/pexpect" --with-agents='%{supportedagents} %{testagents}'
|
||||
CFLAGS="$(echo '%{optflags}')" make %{_smp_mflags}
|
||||
|
||||
%install
|
||||
rm -rf %{buildroot}
|
||||
|
||||
# support libs
|
||||
mkdir -p %{buildroot}%{_usr}/lib/%{name}
|
||||
mv support %{buildroot}%{_usr}/lib/%{name}
|
||||
|
||||
export PYTHONPATH=%{buildroot}%{_usr}/lib/%{name}/support
|
||||
make install DESTDIR=%{buildroot}
|
||||
mkdir -p %{buildroot}/%{_unitdir}/
|
||||
install -m 0644 agents/virt/fence_virtd.service %{buildroot}/%{_unitdir}/
|
||||
# bytecompile Python source code in a non-standard location
|
||||
%if 0%{?fedora} || 0%{?centos} > 7 || 0%{?rhel} > 7
|
||||
%py_byte_compile %{__python3} %{buildroot}%{_datadir}/fence
|
||||
@ -252,9 +273,40 @@ make install DESTDIR=%{buildroot}
|
||||
chmod 0755 %{buildroot}%{_datadir}/fence/*.py
|
||||
# remove docs
|
||||
rm -rf %{buildroot}/usr/share/doc/fence-agents
|
||||
# remove .a files
|
||||
rm -f %{buildroot}/%{_libdir}/%{name}/*.*a
|
||||
rm -f %{buildroot}/%{_libdir}/fence-virt/*.*a
|
||||
|
||||
%post
|
||||
ccs_update_schema > /dev/null 2>&1 ||:
|
||||
# https://fedoraproject.org/wiki/Packaging:ScriptletSnippets#Systemd
|
||||
if [ $1 -eq 1 ] ; then
|
||||
# Initial installation
|
||||
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
|
||||
fi
|
||||
|
||||
%preun
|
||||
# https://fedoraproject.org/wiki/Packaging:ScriptletSnippets#Systemd
|
||||
if [ $1 -eq 0 ] ; then
|
||||
# Package removal, not upgrade
|
||||
/bin/systemctl --no-reload disable fence_virtd.service &> /dev/null || :
|
||||
/bin/systemctl stop fence_virtd.service &> /dev/null || :
|
||||
fi
|
||||
|
||||
%postun
|
||||
# https://fedoraproject.org/wiki/Packaging:ScriptletSnippets#Systemd
|
||||
/bin/systemctl daemon-reload &> /dev/null || :
|
||||
if [ $1 -ge 1 ] ; then
|
||||
# Package upgrade, not uninstall
|
||||
/bin/systemctl try-restart fence_virtd.service &> /dev/null || :
|
||||
fi
|
||||
|
||||
%triggerun -- fence_virtd < 0.3.0-1
|
||||
# https://fedoraproject.org/wiki/Packaging:ScriptletSnippets#Packages_migrating_to_a_systemd_unit_file_from_a_SysV_initscript
|
||||
/usr/bin/systemd-sysv-convert --save fence_virtd &> /dev/null || :
|
||||
/sbin/chkconfig --del fence_virtd &> /dev/null || :
|
||||
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
|
||||
/bin/systemctl try-restart fence_virtd.service &> /dev/null || :
|
||||
|
||||
%description
|
||||
A collection of executables to handle isolation ("fencing") of possibly
|
||||
@ -322,23 +374,6 @@ Requires: fence-agents-zvm >= %{version}-%{release}
|
||||
%endif
|
||||
Provides: fence-agents = %{version}-%{release}
|
||||
Obsoletes: fence-agents < 3.1.13
|
||||
# tmp Provide/Obsolete until fence-virt can be built as part of the packagge
|
||||
Provides: fence-virt >= %{version}-%{release}
|
||||
Obsoletes: fence-virt < %{version}-%{release}
|
||||
Provides: fence-virtd >= %{version}-%{release}
|
||||
Obsoletes: fence-virtd < %{version}-%{release}
|
||||
Provides: fence-virtd-multicast >= %{version}-%{release}
|
||||
Obsoletes: fence-virtd-multicast < %{version}-%{release}
|
||||
Provides: fence-virtd-serial >= %{version}-%{release}
|
||||
Obsoletes: fence-virtd-serial < %{version}-%{release}
|
||||
Provides: fence-virtd-tcp >= %{version}-%{release}
|
||||
Obsoletes: fence-virtd-tcp < %{version}-%{release}
|
||||
Provides: fence-virtd-libvirt >= %{version}-%{release}
|
||||
Obsoletes: fence-virtd-libvirt < %{version}-%{release}
|
||||
Provides: fence-virtd-cpg >= %{version}-%{release}
|
||||
Obsoletes: fence-virtd-cpg < %{version}-%{release}
|
||||
# end
|
||||
|
||||
%description all
|
||||
A collection of executables to handle isolation ("fencing") of possibly
|
||||
misbehaving hosts by the means of remote power management, blocking
|
||||
@ -1006,9 +1041,89 @@ Fence agent for IBM z/VM over IP.
|
||||
%{_mandir}/man8/fence_zvmip.8*
|
||||
%endif
|
||||
|
||||
# fence-virt
|
||||
|
||||
%package -n fence-virt
|
||||
Summary: A pluggable fencing framework for virtual machines
|
||||
Requires(post): systemd-sysv %{systemd_units}
|
||||
Requires(preun): %{systemd_units}
|
||||
Requires(postun): %{systemd_units}
|
||||
%description -n fence-virt
|
||||
Fencing agent for virtual machines.
|
||||
%files -n fence-virt
|
||||
%doc agents/virt/docs/*
|
||||
%{_sbindir}/fence_virt
|
||||
%{_sbindir}/fence_xvm
|
||||
%{_mandir}/man8/fence_virt.*
|
||||
%{_mandir}/man8/fence_xvm.*
|
||||
|
||||
%package -n fence-virtd
|
||||
Summary: Daemon which handles requests from fence-virt
|
||||
%description -n fence-virtd
|
||||
This package provides the host server framework, fence_virtd,
|
||||
for fence_virt. The fence_virtd host daemon is resposible for
|
||||
processing fencing requests from virtual machines and routing
|
||||
the requests to the appropriate physical machine for action.
|
||||
%files -n fence-virtd
|
||||
%{_sbindir}/fence_virtd
|
||||
%{_unitdir}/fence_virtd.service
|
||||
%config(noreplace) %{_sysconfdir}/fence_virt.conf
|
||||
%dir %{_libdir}/fence-virt
|
||||
%{_libdir}/fence-virt/vsock.so
|
||||
%{_mandir}/man5/fence_virt.conf.*
|
||||
%{_mandir}/man8/fence_virtd.*
|
||||
|
||||
%package -n fence-virtd-multicast
|
||||
Summary: Multicast listener for fence-virtd
|
||||
Requires: fence-virtd
|
||||
%description -n fence-virtd-multicast
|
||||
Provides multicast listener capability for fence-virtd.
|
||||
%files -n fence-virtd-multicast
|
||||
%{_libdir}/fence-virt/multicast.so
|
||||
|
||||
%package -n fence-virtd-serial
|
||||
Summary: Serial VMChannel listener for fence-virtd
|
||||
Requires: libvirt >= 0.6.2
|
||||
Requires: fence-virtd
|
||||
%description -n fence-virtd-serial
|
||||
Provides serial VMChannel listener capability for fence-virtd.
|
||||
%files -n fence-virtd-serial
|
||||
%{_libdir}/fence-virt/serial.so
|
||||
|
||||
%package -n fence-virtd-tcp
|
||||
Summary: TCP listener for fence-virtd
|
||||
Requires: fence-virtd
|
||||
%description -n fence-virtd-tcp
|
||||
Provides TCP listener capability for fence-virtd.
|
||||
%files -n fence-virtd-tcp
|
||||
%{_libdir}/fence-virt/tcp.so
|
||||
|
||||
%package -n fence-virtd-libvirt
|
||||
Summary: Libvirt backend for fence-virtd
|
||||
Requires: libvirt >= 0.6.0
|
||||
Requires: fence-virtd
|
||||
%description -n fence-virtd-libvirt
|
||||
Provides fence_virtd with a connection to libvirt to fence
|
||||
virtual machines. Useful for running a cluster of virtual
|
||||
machines on a desktop.
|
||||
%files -n fence-virtd-libvirt
|
||||
%{_libdir}/fence-virt/virt.so
|
||||
|
||||
%package -n fence-virtd-cpg
|
||||
Summary: CPG/libvirt backend for fence-virtd
|
||||
Requires: corosynclib
|
||||
Requires: fence-virtd
|
||||
%description -n fence-virtd-cpg
|
||||
Provides fence_virtd with a connection to libvirt to fence
|
||||
virtual machines. Uses corosync CPG to keep track of VM
|
||||
locations to allow for non-local VMs to be fenced when VMs
|
||||
are located on corosync cluster nodes.
|
||||
%files -n fence-virtd-cpg
|
||||
%{_libdir}/fence-virt/cpg.so
|
||||
|
||||
%changelog
|
||||
* Mon May 31 2021 Oyvind Albrigtsen <oalbrigt@redhat.com> - 4.7.1-11
|
||||
- Set Provides/Obsoletes before making fence-virt part of the package
|
||||
* Fri Jun 4 2021 Oyvind Albrigtsen <oalbrigt@redhat.com> - 4.9.0-1
|
||||
- Rebase and add fence-virt subpackages
|
||||
|
||||
Resolves: rhbz#1965988
|
||||
|
||||
|
@ -1,43 +0,0 @@
|
||||
From a06a83566e11b0bdf197b16beb022b4cece11d5f Mon Sep 17 00:00:00 2001
|
||||
From: Oyvind Albrigtsen <oalbrigt@redhat.com>
|
||||
Date: Wed, 10 Feb 2021 15:37:27 +0100
|
||||
Subject: [PATCH] fence_gce: support google-auth and oauthlib and fallback to
|
||||
deprecated libs when not available
|
||||
|
||||
oauth2client deprecated info: https://pypi.org/project/oauth2client/
|
||||
---
|
||||
agents/gce/fence_gce.py | 14 +++++++++++---
|
||||
1 file changed, 11 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/agents/gce/fence_gce.py b/agents/gce/fence_gce.py
|
||||
index d69acf4e..04318744 100644
|
||||
--- a/agents/gce/fence_gce.py
|
||||
+++ b/agents/gce/fence_gce.py
|
||||
@@ -29,8 +29,12 @@
|
||||
from fencing import fail_usage, run_delay, all_opt, atexit_handler, check_input, process_input, show_docs, fence_action
|
||||
try:
|
||||
import googleapiclient.discovery
|
||||
- from oauth2client.client import GoogleCredentials
|
||||
- from oauth2client.service_account import ServiceAccountCredentials
|
||||
+ try:
|
||||
+ from google.oauth2.credentials import Credentials as GoogleCredentials
|
||||
+ from google.oauth2.service_account import Credentials as ServiceAccountCredentials
|
||||
+ except:
|
||||
+ from oauth2client.client import GoogleCredentials
|
||||
+ from oauth2client.service_account import ServiceAccountCredentials
|
||||
except:
|
||||
pass
|
||||
|
||||
@@ -380,7 +384,11 @@ def main():
|
||||
credentials = ServiceAccountCredentials.from_json_keyfile_name(options.get("--serviceaccount"))
|
||||
logging.debug("using credentials from service account")
|
||||
else:
|
||||
- credentials = GoogleCredentials.get_application_default()
|
||||
+ try:
|
||||
+ from googleapiclient import _auth
|
||||
+ credentials = _auth.default_credentials();
|
||||
+ except:
|
||||
+ credentials = GoogleCredentials.get_application_default()
|
||||
logging.debug("using application default credentials")
|
||||
conn = googleapiclient.discovery.build(
|
||||
'compute', 'v1', credentials=credentials, cache_discovery=False)
|
@ -1,10 +1,21 @@
|
||||
--- a/agents/gce/fence_gce.py 2021-02-10 16:13:16.156356744 +0100
|
||||
+++ b/agents/gce/fence_gce.py 2021-02-10 16:13:29.346383884 +0100
|
||||
@@ -28,6 +28,7 @@
|
||||
diff --color -uNr a/agents/gce/fence_gce.py b/agents/gce/fence_gce.py
|
||||
--- a/agents/gce/fence_gce.py 2021-06-03 13:10:44.752999470 +0200
|
||||
+++ b/agents/gce/fence_gce.py 2021-06-03 13:10:36.512971619 +0200
|
||||
@@ -9,7 +9,6 @@
|
||||
#
|
||||
|
||||
import atexit
|
||||
-import httplib2
|
||||
import logging
|
||||
import json
|
||||
import re
|
||||
@@ -30,6 +29,8 @@
|
||||
|
||||
from fencing import fail_usage, run_delay, all_opt, atexit_handler, check_input, process_input, show_docs, fence_action
|
||||
try:
|
||||
+ sys.path.insert(0, '/usr/lib/fence-agents/support/google')
|
||||
+ import httplib2
|
||||
import googleapiclient.discovery
|
||||
import socks
|
||||
try:
|
||||
from google.oauth2.credentials import Credentials as GoogleCredentials
|
||||
Binary files a/agents/gce/.fence_gce.py.swp and b/agents/gce/.fence_gce.py.swp differ
|
||||
|
2
sources
2
sources
@ -1,4 +1,4 @@
|
||||
SHA512 (fence-agents-4.7.1.tar.gz) = 9973d80fa9545f44d0202e6841eeadaf9facdaca2a4a67827369b5fe63a58bc830a5fb91dc94c5a90dc1f8cf4a07198fd52eb46f3974b4730f69013154493527
|
||||
SHA512 (fence-agents-4.9.0.tar.gz) = 4df897f32e8d272cf27bfd2501ce2e91f8a91726a066df89f6bea668960919a5bc069e1e71c5ec2ced0512291a2e28eb365daee8362e47a8a72be4bfac1e4ec6
|
||||
SHA512 (requirements-aliyun.txt) = 0c4f89de63246c406535ee73310232f3986b37dedbeed52f25000386d73af6735e1bf8e7ecaa97419df98f55058d76e4ff289d856b815afaaaf69744c5924f7e
|
||||
SHA512 (requirements-aws.txt) = 3fccf8c386dd21dcb738f89020dd728e76dee347accfdf7bef5b7493d22ac1090340f76187f19a6822777fe939ffc50f1ec84c1dbe328be5d435d5ad56714a99
|
||||
SHA512 (requirements-azure.txt) = a176aeaba7f13ca126bc6b41de1237148480787e4fe56cd9969b843d7102b24cbef2c9f9bd5e4460c603da96ba588639a77dfb376f9ab4ff6f7c2a29013edc31
|
||||
|
Loading…
Reference in New Issue
Block a user