summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlex Yang <yangyang1@zte.com.cn>2017-02-24 09:36:32 +0800
committerAlex Yang <yangyang1@zte.com.cn>2017-02-24 13:58:29 +0800
commitfc52a702ae6bd622d4fc9142b24ce76e4d7a3271 (patch)
tree54e7d661c016133cb00e25557e66eb6bda8e8651
parentcd585136acb636d6b13b173cf593c5f01c5f33a8 (diff)
Correct the type error of env CLI Option in tempest.py
Change-Id: Id7a4f567c7c81e17c33b5c3ba558fa1cc891b42d Signed-off-by: Alex Yang <yangyang1@zte.com.cn>
-rw-r--r--deploy/tempest.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/deploy/tempest.py b/deploy/tempest.py
index 34af9b5a..2b72cbc2 100644
--- a/deploy/tempest.py
+++ b/deploy/tempest.py
@@ -31,7 +31,7 @@ _CLI_OPTS = [
help='Config cluster'),
cfg.StrOpt('host',
help='Config host'),
- cfg.StrOpt('env',
+ cfg.IntOpt('env',
help='deploy environment'),
]
@@ -86,7 +86,7 @@ def prepare_install():
cluster_id = cluster_info.id
add_hosts_interface(cluster_id, hosts_info, hosts_name,
host_interface_map, vip)
- if conf['env'] and conf['env'] == 0:
+ if 'env' in conf and conf['env'] == 0:
build_pxe_for_os(cluster_id)
except Exception:
print("Deploy failed!!!.%s." % traceback.format_exc())