summaryrefslogtreecommitdiffstats
path: root/modules/opnfv/deployment/apex
diff options
context:
space:
mode:
Diffstat (limited to 'modules/opnfv/deployment/apex')
-rw-r--r--modules/opnfv/deployment/apex/adapter.py14
1 files changed, 7 insertions, 7 deletions
diff --git a/modules/opnfv/deployment/apex/adapter.py b/modules/opnfv/deployment/apex/adapter.py
index 1b81e781b..cb827d886 100644
--- a/modules/opnfv/deployment/apex/adapter.py
+++ b/modules/opnfv/deployment/apex/adapter.py
@@ -25,9 +25,9 @@ class ApexAdapter(manager.DeploymentHandler):
installer_pwd=None,
pkey_file=pkey_file)
- def nodes(self):
+ def get_nodes(self):
nodes = []
- cmd = "source /home/stack/stackrc;nova list 2>/dev/null"
+ cmd = "source /home/stack/stackrc;openstack server list"
output = self.installer_node.run_cmd(cmd)
lines = output.rsplit('\n')
if len(lines) < 4:
@@ -44,12 +44,12 @@ class ApexAdapter(manager.DeploymentHandler):
if 'Daylight' in line:
roles += ", OpenDaylight"
fields = line.split('|')
- id = re.sub('[!| ]', '', fields[1])
- name = re.sub('[!| ]', '', fields[2])
- status_node = re.sub('[!| ]', '', fields[3])
- ip = re.sub('[!| ctlplane=]', '', fields[6])
+ id = re.sub('[!| ]', '', fields[1]).encode()
+ name = re.sub('[!| ]', '', fields[2]).encode()
+ status_node = re.sub('[!| ]', '', fields[3]).encode()
+ ip = re.sub('[!| ctlplane=]', '', fields[4]).encode()
- if status_node == 'ACTIVE':
+ if status_node.lower() == 'active':
status = manager.Node.STATUS_OK
ssh_client = ssh_utils.get_ssh_client(hostname=ip,
username='heat-admin',