From a4f7d6c684931d934ac0dce6fdf7dcdfd7fef8c2 Mon Sep 17 00:00:00 2001 From: Narinder Gupta Date: Mon, 27 Jun 2016 18:03:58 -0500 Subject: [PATCH] checking if parameter is no null. Change-Id: Id3d908903ddb4584e0c813aa6dc8f859c3004ba7 Signed-off-by: Narinder Gupta --- ci/deploy.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/ci/deploy.py b/ci/deploy.py index 3ec50dca..5f84da42 100644 --- a/ci/deploy.py +++ b/ci/deploy.py @@ -215,7 +215,10 @@ opnfvlabcfg["opnfv"]["floating-ip-range"]=labcfg["lab"]["racks"][0]["floating-ip opnfvlabcfg["opnfv"]["ext-port"]=labcfg["lab"]["racks"][0]["ext-port"] opnfvlabcfg["opnfv"]["ceph-disk"]=labcfg["opnfv"]["storage"][0]["disk"] opnfvlabcfg["opnfv"]["interface-enable"]=",".join(list(set(ifnamelist))) -opnfvlabcfg["opnfv"]["os-domain-name"] = labcfg["lab"]["racks"][0]["osdomainname"] + +osdomname = labcfg["lab"]["racks"][0]["osdomainname"] +if osdomname: + opnfvlabcfg["opnfv"]["os-domain-name"] = labcfg["lab"]["racks"][0]["osdomainname"] with open('deployment.yaml', 'wa') as opnfvf: yaml.dump(opnfvcfg, opnfvf, default_flow_style=False) -- 2.16.6