Fix barbicanclient and swarm-ci
This squash of commits is required to fix gate Updated from global requirements Change-Id: Ib38a2fd3d2f46f8383e2a5245e58f2f03cdb657a swarm-ci: Assert against ConnectionError instead of SSLError tcp returns ConnectionError whereas https returns SSLError. The default protocol we use in magnum is tcp which works fine docker python SDK docker>=2.0.0. Change-Id: Ibd122d225ad0f0439abd185bd0846ddb3b22a63a Fixes: I32b58cf567f4ae5597d9207b81f8546d1062b8b9
This commit is contained in:
parent
769f0eea41
commit
761bc404f7
|
@ -65,9 +65,6 @@ class TestSwarmAPIs(ClusterTest):
|
|||
raise Exception(msg)
|
||||
|
||||
url = self.cs.clusters.get(self.cluster.uuid).api_address
|
||||
# FIXME (strigazi) until we upgrade to docker-py 1.8.0 use
|
||||
# only the https protocol instead of tcp.
|
||||
https_url = url.replace('tcp', 'https')
|
||||
|
||||
# Note(eliqiao): docker_utils.CONF.docker.default_timeout is 10,
|
||||
# tested this default configure option not works on gate, it will
|
||||
|
@ -77,7 +74,7 @@ class TestSwarmAPIs(ClusterTest):
|
|||
|
||||
docker_api_time_out = 180
|
||||
self.docker_client = docker_utils.DockerHTTPClient(
|
||||
https_url,
|
||||
url,
|
||||
CONF.docker.docker_remote_api_version,
|
||||
docker_api_time_out,
|
||||
client_key=self.key_file,
|
||||
|
@ -85,7 +82,7 @@ class TestSwarmAPIs(ClusterTest):
|
|||
ca_cert=self.ca_file)
|
||||
|
||||
self.docker_client_non_tls = docker_utils.DockerHTTPClient(
|
||||
https_url,
|
||||
url,
|
||||
CONF.docker.docker_remote_api_version,
|
||||
docker_api_time_out)
|
||||
|
||||
|
@ -145,5 +142,11 @@ class TestSwarmAPIs(ClusterTest):
|
|||
self.assertEqual([], resp)
|
||||
|
||||
def test_access_with_non_tls_client(self):
|
||||
self.assertRaises(req_exceptions.SSLError,
|
||||
"""Try to contact master's docker using the TCP protocol.
|
||||
|
||||
TCP returns ConnectionError whereas HTTPS returns SSLError. The
|
||||
default protocol we use in magnum is TCP which works fine docker
|
||||
python SDK docker>=2.0.0.
|
||||
"""
|
||||
self.assertRaises(req_exceptions.ConnectionError,
|
||||
self.docker_client_non_tls.containers)
|
||||
|
|
|
@ -18,9 +18,9 @@ enum34;python_version=='2.7' or python_version=='2.6' or python_version=='3.3' #
|
|||
eventlet!=0.18.3,!=0.20.1,<0.21.0,>=0.18.2 # MIT
|
||||
iso8601>=0.1.11 # MIT
|
||||
jsonpatch>=1.1 # BSD
|
||||
keystoneauth1>=3.0.1 # Apache-2.0
|
||||
keystoneauth1>=3.1.0 # Apache-2.0
|
||||
keystonemiddleware>=4.12.0 # Apache-2.0
|
||||
kubernetes>=1.0.0b1 # Apache-2.0
|
||||
kubernetes>=1.0.0 # Apache-2.0
|
||||
marathon>=0.8.6 # MIT
|
||||
netaddr!=0.7.16,>=0.7.13 # BSD
|
||||
oslo.concurrency>=3.8.0 # Apache-2.0
|
||||
|
@ -40,7 +40,7 @@ oslo.reports>=0.6.0 # Apache-2.0
|
|||
pbr!=2.1.0,>=2.0.0 # Apache-2.0
|
||||
pecan!=1.0.2,!=1.0.3,!=1.0.4,!=1.2,>=1.0.0 # BSD
|
||||
pycadf!=2.0.0,>=1.1.0 # Apache-2.0
|
||||
python-barbicanclient>=4.0.0 # Apache-2.0
|
||||
python-barbicanclient!=4.5.0,>=4.0.0 # Apache-2.0
|
||||
python-glanceclient>=2.7.0 # Apache-2.0
|
||||
python-heatclient>=1.6.1 # Apache-2.0
|
||||
python-neutronclient>=6.3.0 # Apache-2.0
|
||||
|
@ -51,5 +51,5 @@ setuptools!=24.0.0,!=34.0.0,!=34.0.1,!=34.0.2,!=34.0.3,!=34.1.0,!=34.1.1,!=34.2.
|
|||
six>=1.9.0 # MIT
|
||||
stevedore>=1.20.0 # Apache-2.0
|
||||
taskflow>=2.7.0 # Apache-2.0
|
||||
cryptography>=1.6 # BSD/Apache-2.0
|
||||
cryptography!=2.0,>=1.6 # BSD/Apache-2.0
|
||||
Werkzeug>=0.7 # BSD License
|
||||
|
|
|
@ -12,7 +12,7 @@ doc8 # Apache-2.0
|
|||
fixtures>=3.0.0 # Apache-2.0/BSD
|
||||
hacking!=0.13.0,<0.14,>=0.12.0 # Apache-2.0
|
||||
mock>=2.0 # BSD
|
||||
openstackdocstheme>=1.11.0 # Apache-2.0
|
||||
openstackdocstheme>=1.16.0 # Apache-2.0
|
||||
oslotest>=1.10.0 # Apache-2.0
|
||||
osprofiler>=1.4.0 # Apache-2.0
|
||||
os-api-ref>=1.0.0 # Apache-2.0
|
||||
|
|
Loading…
Reference in New Issue