Pass ironic microversion through from api_version

If someone sets baremetal_api_version to 1.29 right now, we don't really
do anything with that information. Pass it through to the constructor
for ironicclient in get_legacy_client().

Change-Id: I470fbb8852eac7d5cb35aef549ac591d63f3636f
This commit is contained in:
Monty Taylor 2017-02-28 11:22:30 -06:00
parent 81e04fcec6
commit d321a14ecb
No known key found for this signature in database
GPG Key ID: 7BAE94BC7141A594
2 changed files with 10 additions and 0 deletions

View File

@ -372,6 +372,12 @@ class CloudConfig(object):
constructor_kwargs['endpoint'] = endpoint
if service_key == 'network':
constructor_kwargs['api_version'] = version
elif service_key == 'baremetal':
if version != '1':
# Set Ironic Microversion
constructor_kwargs['os_ironic_api_version'] = version
# Version arg is the major version, not the full microstring
constructor_kwargs['version'] = version[0]
else:
constructor_kwargs['version'] = version
if service_key == 'database':

View File

@ -0,0 +1,4 @@
---
features:
- Add support for passing Ironic microversion to the ironicclient
constructor in get_legacy_client.