|
|
145e87 |
diff -uNr a/fence/agents/compute/fence_compute.py b/fence/agents/compute/fence_compute.py
|
|
|
145e87 |
--- a/fence/agents/compute/fence_compute.py 2018-07-16 12:34:24.982643862 +0200
|
|
|
145e87 |
+++ b/fence/agents/compute/fence_compute.py 2018-07-16 12:42:16.965667752 +0200
|
|
|
145e87 |
@@ -353,7 +353,7 @@
|
|
|
145e87 |
"default" : "",
|
|
|
145e87 |
"order": 1,
|
|
|
145e87 |
}
|
|
|
145e87 |
- all_opt["user_domain"] = {
|
|
|
145e87 |
+ all_opt["user-domain"] = {
|
|
|
145e87 |
"getopt" : "u:",
|
|
|
145e87 |
"longopt" : "user-domain",
|
|
|
145e87 |
"help" : "-u, --user-domain=[name] Keystone v3 User Domain",
|
|
|
145e87 |
@@ -362,7 +362,7 @@
|
|
|
145e87 |
"default" : "Default",
|
|
|
145e87 |
"order": 2,
|
|
|
145e87 |
}
|
|
|
145e87 |
- all_opt["project_domain"] = {
|
|
|
145e87 |
+ all_opt["project-domain"] = {
|
|
|
145e87 |
"getopt" : "P:",
|
|
|
145e87 |
"longopt" : "project-domain",
|
|
|
145e87 |
"help" : "-d, --project-domain=[name] Keystone v3 Project Domain",
|
|
|
145e87 |
@@ -433,6 +433,14 @@
|
|
|
145e87 |
"default" : "False",
|
|
|
145e87 |
"order": 5,
|
|
|
145e87 |
}
|
|
|
145e87 |
+ all_opt["compute-domain"] = {
|
|
|
145e87 |
+ "getopt" : ":",
|
|
|
145e87 |
+ "longopt" : "compute-domain",
|
|
|
145e87 |
+ "help" : "--compute-domain=[string] Replaced by --domain",
|
|
|
145e87 |
+ "required" : "0",
|
|
|
145e87 |
+ "shortdesc" : "Replaced by domain",
|
|
|
145e87 |
+ "order": 6,
|
|
|
145e87 |
+ }
|
|
|
145e87 |
|
|
|
145e87 |
def set_multi_power_fn(connection, options, set_power_fn, get_power_fn, retry_attempts=1):
|
|
|
145e87 |
for _ in range(retry_attempts):
|
|
|
145e87 |
@@ -450,9 +458,10 @@
|
|
|
145e87 |
global override_status
|
|
|
145e87 |
atexit.register(atexit_handler)
|
|
|
145e87 |
|
|
|
145e87 |
- device_opt = ["login", "passwd", "tenant_name", "auth_url", "fabric_fencing",
|
|
|
145e87 |
- "no_login", "no_password", "port", "domain", "project_domain", "user_domain",
|
|
|
145e87 |
- "no_shared_storage", "endpoint_type", "record_only", "instance_filtering", "insecure", "region_name"]
|
|
|
145e87 |
+ device_opt = ["login", "passwd", "tenant_name", "auth_url", "fabric_fencing", "no_login",
|
|
|
145e87 |
+ "no_password", "port", "domain", "compute-domain", "project-domain",
|
|
|
145e87 |
+ "user-domain", "no_shared_storage", "endpoint_type", "record_only",
|
|
|
145e87 |
+ "instance_filtering", "insecure", "region_name"]
|
|
|
145e87 |
define_new_opts()
|
|
|
145e87 |
all_opt["shell_timeout"]["default"] = "180"
|
|
|
145e87 |
|
|
|
145e87 |
@@ -470,6 +479,11 @@
|
|
|
145e87 |
|
|
|
145e87 |
run_delay(options)
|
|
|
145e87 |
|
|
|
145e87 |
+ # workaround to avoid regressions
|
|
|
145e87 |
+ if "--compute-domain" in options and options["--compute-domain"]:
|
|
|
145e87 |
+ options["--domain"] = options["--compute-domain"]
|
|
|
145e87 |
+ del options["--domain"]
|
|
|
145e87 |
+
|
|
|
145e87 |
logging.debug("Running "+options["--action"])
|
|
|
145e87 |
connection = create_nova_connection(options)
|
|
|
145e87 |
|
|
|
145e87 |
diff -uNr a/fence/agents/compute/fence_evacuate.py b/fence/agents/compute/fence_evacuate.py
|
|
|
145e87 |
--- a/fence/agents/compute/fence_evacuate.py 2018-07-16 12:34:24.982643862 +0200
|
|
|
145e87 |
+++ b/fence/agents/compute/fence_evacuate.py 2018-07-16 12:42:16.966667739 +0200
|
|
|
145e87 |
@@ -290,7 +290,7 @@
|
|
|
145e87 |
"default" : "",
|
|
|
145e87 |
"order": 1,
|
|
|
145e87 |
}
|
|
|
145e87 |
- all_opt["user_domain"] = {
|
|
|
145e87 |
+ all_opt["user-domain"] = {
|
|
|
145e87 |
"getopt" : "u:",
|
|
|
145e87 |
"longopt" : "user-domain",
|
|
|
145e87 |
"help" : "-u, --user-domain=[name] Keystone v3 User Domain",
|
|
|
145e87 |
@@ -299,7 +299,7 @@
|
|
|
145e87 |
"default" : "Default",
|
|
|
145e87 |
"order": 2,
|
|
|
145e87 |
}
|
|
|
145e87 |
- all_opt["project_domain"] = {
|
|
|
145e87 |
+ all_opt["project-domain"] = {
|
|
|
145e87 |
"getopt" : "P:",
|
|
|
145e87 |
"longopt" : "project-domain",
|
|
|
145e87 |
"help" : "-d, --project-domain=[name] Keystone v3 Project Domain",
|
|
|
145e87 |
@@ -361,14 +361,22 @@
|
|
|
145e87 |
"default" : "False",
|
|
|
145e87 |
"order": 5,
|
|
|
145e87 |
}
|
|
|
145e87 |
+ all_opt["compute-domain"] = {
|
|
|
145e87 |
+ "getopt" : ":",
|
|
|
145e87 |
+ "longopt" : "compute-domain",
|
|
|
145e87 |
+ "help" : "--compute-domain=[string] Replaced by --domain",
|
|
|
145e87 |
+ "required" : "0",
|
|
|
145e87 |
+ "shortdesc" : "Replaced by domain",
|
|
|
145e87 |
+ "order": 6,
|
|
|
145e87 |
+ }
|
|
|
145e87 |
|
|
|
145e87 |
def main():
|
|
|
145e87 |
atexit.register(atexit_handler)
|
|
|
145e87 |
|
|
|
145e87 |
device_opt = ["login", "passwd", "tenant_name", "auth_url",
|
|
|
145e87 |
- "no_login", "no_password", "port", "domain", "project_domain",
|
|
|
145e87 |
- "user_domain", "no_shared_storage", "endpoint_type",
|
|
|
145e87 |
- "instance_filtering", "insecure", "region_name"]
|
|
|
145e87 |
+ "no_login", "no_password", "port", "domain", "compute-domain",
|
|
|
145e87 |
+ "project-domain", "user-domain", "no_shared_storage",
|
|
|
145e87 |
+ "endpoint_type", "instance_filtering", "insecure", "region_name"]
|
|
|
145e87 |
define_new_opts()
|
|
|
145e87 |
all_opt["shell_timeout"]["default"] = "180"
|
|
|
145e87 |
|
|
|
145e87 |
@@ -383,6 +391,12 @@
|
|
|
145e87 |
|
|
|
145e87 |
run_delay(options)
|
|
|
145e87 |
|
|
|
145e87 |
+ # workaround to avoid regressions
|
|
|
145e87 |
+ if "--compute-domain" in options and options["--compute-domain"]:
|
|
|
145e87 |
+ options["--domain"] = options["--compute-domain"]
|
|
|
145e87 |
+ del options["--domain"]
|
|
|
145e87 |
+
|
|
|
145e87 |
+
|
|
|
145e87 |
connection = create_nova_connection(options)
|
|
|
145e87 |
|
|
|
145e87 |
# Un-evacuating a server doesn't make sense
|