Add custom SSL CA Cert support for api.cinder.get_microversion

api.cinder.get_microversion function now supports OPENSTACK_SSL_NO_VERIFY
and OPENSTACK_SSL_CACERT config options.

This depends on commit 4a3a2c3c9a89ccff4e64d3da96de5b0af4303840 in
python-cinderclient, so the minimum version of python-cinderclient
is bumped to 5.0.0.

NOTE(amotoki): The stretegy of backporting to stable branches needs
a discussion with the requirements team as we cannot bump the
minimum version (at least the major version bump is surprising).

Change-Id: I22c6c60e10d8e9328f7f1e0c24d6c74496ec1a71
Closes-Bug: 1744670
This commit is contained in:
Ivan Kolodyazhny 2019-08-12 16:19:44 +03:00 committed by Akihiro Motoki
parent 85a1dddf12
commit 285c51f7e1
3 changed files with 8 additions and 3 deletions

View File

@ -93,7 +93,7 @@ pyOpenSSL==17.1.0
pyparsing==2.1.0
pyperclip==1.5.27
pyScss==1.3.4
python-cinderclient==4.0.1
python-cinderclient==5.0.0
python-dateutil==2.5.3
python-glanceclient==2.8.0
python-keystoneclient==3.15.0

View File

@ -274,7 +274,12 @@ def get_microversion(request, features):
continue
else:
return None
min_ver, max_ver = cinder_client.get_server_version(cinder_url)
insecure = settings.OPENSTACK_SSL_NO_VERIFY
cacert = settings.OPENSTACK_SSL_CACERT
min_ver, max_ver = cinder_client.get_server_version(cinder_url,
insecure, cacert)
return microversions.get_microversion_for_features(
'cinder', features, api_versions.APIVersion, min_ver, max_ver)

View File

@ -31,7 +31,7 @@ osprofiler>=2.3.0 # Apache-2.0
Pint>=0.5 # BSD
pymongo!=3.1,>=3.0.2 # Apache-2.0
pyScss!=1.3.5,>=1.3.4 # MIT License
python-cinderclient>=4.0.1 # Apache-2.0
python-cinderclient>=5.0.0 # Apache-2.0
python-glanceclient>=2.8.0 # Apache-2.0
python-keystoneclient>=3.15.0 # Apache-2.0
python-neutronclient>=6.7.0 # Apache-2.0