diff options
author | Szilard Cserey <szilard.cserey@gmail.com> | 2016-03-09 17:52:18 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@172.30.200.206> | 2016-03-09 17:52:19 +0000 |
commit | 735dc3a58e599f89e1e214ba41f2a023f97085fb (patch) | |
tree | b3c56ea959b24acbb645a0fdce329ba92a63f47e /deploy/dha_adapters | |
parent | bdf4ad5d52b8094bc2f99195ae46f6904e3d42e2 (diff) | |
parent | 1ef2a5abcdacf3274e4ed17c612835ae10cb34d8 (diff) |
Merge "Make number of cpus configurable in dha file"
Diffstat (limited to 'deploy/dha_adapters')
-rw-r--r-- | deploy/dha_adapters/hardware_adapter.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/deploy/dha_adapters/hardware_adapter.py b/deploy/dha_adapters/hardware_adapter.py index 2cd5ab842..55bb4002e 100644 --- a/deploy/dha_adapters/hardware_adapter.py +++ b/deploy/dha_adapters/hardware_adapter.py @@ -58,3 +58,8 @@ class HardwareAdapter(object): def get_disks(self): return self.dha_struct['disks'] + + def get_number_cpus(self, role): + role_cpus_dict = self.dha_struct.get('number_cpus') + if role_cpus_dict: + return role_cpus_dict.get(role) |