Blame SOURCES/bz2081235-fence_ibm_vpc-fix-parameters.patch

33dd94
From d0254345472c9415af1e06e9e8df2fe0ce464db0 Mon Sep 17 00:00:00 2001
33dd94
From: Oyvind Albrigtsen <oalbrigt@redhat.com>
33dd94
Date: Mon, 2 May 2022 11:14:42 +0200
33dd94
Subject: [PATCH] fence_ibm_vpc: remove unused instance parameter and make
33dd94
 limit optional
33dd94
33dd94
---
33dd94
 agents/ibm_vpc/fence_ibm_vpc.py       | 11 +----------
33dd94
 tests/data/metadata/fence_ibm_vpc.xml |  7 +------
33dd94
 2 files changed, 2 insertions(+), 16 deletions(-)
33dd94
33dd94
diff --git a/agents/ibm_vpc/fence_ibm_vpc.py b/agents/ibm_vpc/fence_ibm_vpc.py
33dd94
index 9f84f7b2d..9e38e8301 100755
33dd94
--- a/agents/ibm_vpc/fence_ibm_vpc.py
33dd94
+++ b/agents/ibm_vpc/fence_ibm_vpc.py
33dd94
@@ -161,14 +161,6 @@ def define_new_opts():
33dd94
 		"shortdesc" : "API Key",
33dd94
 		"order" : 0
33dd94
 	}
33dd94
-	all_opt["instance"] = {
33dd94
-		"getopt" : ":",
33dd94
-		"longopt" : "instance",
33dd94
-		"help" : "--instance=[instance]          Cloud Instance",
33dd94
-		"required" : "1",
33dd94
-		"shortdesc" : "Cloud Instance",
33dd94
-		"order" : 0
33dd94
-	}
33dd94
 	all_opt["region"] = {
33dd94
 		"getopt" : ":",
33dd94
 		"longopt" : "region",
33dd94
@@ -181,7 +173,7 @@ def define_new_opts():
33dd94
 		"getopt" : ":",
33dd94
 		"longopt" : "limit",
33dd94
 		"help" : "--limit=[number]               Limit number of nodes returned by API",
33dd94
-		"required" : "1",
33dd94
+		"required" : "0",
33dd94
 		"default": 50,
33dd94
 		"shortdesc" : "Number of nodes returned by API",
33dd94
 		"order" : 0
33dd94
@@ -191,7 +183,6 @@ def define_new_opts():
33dd94
 def main():
33dd94
 	device_opt = [
33dd94
 		"apikey",
33dd94
-		"instance",
33dd94
 		"region",
33dd94
 		"limit",
33dd94
 		"port",
33dd94
diff --git a/tests/data/metadata/fence_ibm_vpc.xml b/tests/data/metadata/fence_ibm_vpc.xml
33dd94
index 926efcaa0..ee7151673 100644
33dd94
--- a/tests/data/metadata/fence_ibm_vpc.xml
33dd94
+++ b/tests/data/metadata/fence_ibm_vpc.xml
33dd94
@@ -8,12 +8,7 @@
33dd94
 		<content type="string"  />
33dd94
 		<shortdesc lang="en">API Key</shortdesc>
33dd94
 	</parameter>
33dd94
-	<parameter name="instance" unique="0" required="1">
33dd94
-		<getopt mixed="--instance=[instance]" />
33dd94
-		<content type="string"  />
33dd94
-		<shortdesc lang="en">Cloud Instance</shortdesc>
33dd94
-	</parameter>
33dd94
-	<parameter name="limit" unique="0" required="1">
33dd94
+	<parameter name="limit" unique="0" required="0">
33dd94
 		<getopt mixed="--limit=[number]" />
33dd94
 		<content type="string" default="50"  />
33dd94
 		<shortdesc lang="en">Number of nodes returned by API</shortdesc>