diff options
author | Harry Huang <huangxiangyu5@huawei.com> | 2018-09-03 11:20:59 +0800 |
---|---|---|
committer | Harry Huang <huangxiangyu5@huawei.com> | 2018-09-03 11:25:21 +0800 |
commit | 0634fd53e4b8b9519574449ee35a40edfcf6a9d2 (patch) | |
tree | 66109b5198336c4b34d6ef399e311b49d65a8248 /compass-tasks-base | |
parent | 20e229822b31b03e1120c3e5efd4ba131261617e (diff) |
Passing ipmi credentials to cobbler
JIRA: COMPASS-616
Add host ipmi credentials into cobbler system
to manage host power.
Change-Id: I6ffbb390f920fe146887513d3f7e48f05630a25f
Signed-off-by: Harry Huang <huangxiangyu5@huawei.com>
Diffstat (limited to 'compass-tasks-base')
-rw-r--r-- | compass-tasks-base/db/api/cluster.py | 2 | ||||
-rw-r--r-- | compass-tasks-base/deployment/installers/config_manager.py | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/compass-tasks-base/db/api/cluster.py b/compass-tasks-base/db/api/cluster.py index 7a7022c..9a0b8f0 100644 --- a/compass-tasks-base/db/api/cluster.py +++ b/compass-tasks-base/db/api/cluster.py @@ -50,7 +50,7 @@ RESP_CLUSTERHOST_FIELDS = [ 'os_installed', 'distributed_system_installed', 'os_name', 'os_id', 'ip', 'reinstall_os', 'reinstall_distributed_system', - 'owner', 'cluster_id', + 'owner', 'cluster_id', 'ipmi_credentials', 'created_at', 'updated_at', 'patched_roles' ] diff --git a/compass-tasks-base/deployment/installers/config_manager.py b/compass-tasks-base/deployment/installers/config_manager.py index 597c3a6..d3b28e0 100644 --- a/compass-tasks-base/deployment/installers/config_manager.py +++ b/compass-tasks-base/deployment/installers/config_manager.py @@ -170,6 +170,7 @@ class HostInfo(object): self.roles = self.host_info.setdefault(const.ROLES, []) self.patched_roles = self.host_info.setdefault(const.PATCHED_ROLES, []) self.ipmi = deepcopy(self.host_info.setdefault(const.IPMI, {})) + self.ipmi_credentials = deepcopy(self.host_info.setdefault(const.IPMI_CREDS, {})) self.reinstall_os_flag = self.host_info.get(const.REINSTALL_OS_FLAG) self.deployed_os_config = self.host_info.setdefault( const.DEPLOYED_OS_CONFIG, {} @@ -275,6 +276,7 @@ class HostInfo(object): def baseinfo(self): return { const.REINSTALL_OS_FLAG: self.reinstall_os_flag, + const.IPMI_CREDS: self.ipmi_credentials, const.MAC_ADDR: self.mac, const.NAME: self.name, const.HOSTNAME: self.hostname, |