Traceback (most recent call last):
File "/tmp/k.py", line 5, in <module>
print keystone.tenants.list()
File "/home/sskripnick/code/python-keystoneclient/keystoneclient/v2_0/tenants.py", line 118, in list
tenant_list = self._list("/tenants%s" % query, "tenants")
File "/home/sskripnick/code/python-keystoneclient/keystoneclient/base.py", line 106, in _list
resp, body = self.client.get(url)
File "/home/sskripnick/code/python-keystoneclient/keystoneclient/httpclient.py", line 590, in get
return self._cs_request(url, 'GET', **kwargs)
File "/home/sskripnick/code/python-keystoneclient/keystoneclient/httpclient.py", line 582, in _cs_request
return self.request(url, method, **kwargs)
File "/home/sskripnick/code/python-keystoneclient/keystoneclient/httpclient.py", line 564, in request
resp = super(HTTPClient, self).request(url, method, **kwargs)
File "/home/sskripnick/code/python-keystoneclient/keystoneclient/baseclient.py", line 21, in request
return self.session.request(url, method, **kwargs)
File "/home/sskripnick/code/python-keystoneclient/keystoneclient/utils.py", line 318, in inner
return func(*args, **kwargs)
File "/home/sskripnick/code/python-keystoneclient/keystoneclient/session.py", line 257, in request
resp = self._send_request(url, method, redirect, **kwargs)
File "/home/sskripnick/code/python-keystoneclient/keystoneclient/session.py", line 286, in _send_request
raise exceptions.ConnectionRefused(msg)
keystoneclient.openstack.common.apiclient.exceptions.ConnectionRefused: Unable to establish connection to http://192.168.0.2:35357/v2.0/tenants
But all works fine when I add `endpoint' argument:
Exactly the same when I trying to use port 5000:
from keystoneclient.v2_0 import client 172.18. 200.196: 5000/v2. 0' Client( username= USERNAME, password=PASSWORD, tenant_name=TENANT, auth_url=AUTH_URL) authenticate( ) tenants. list()
USERNAME, PASSWORD, TENANT, AUTH_URL = 'rally', 'rally', 'rally', 'http://
keystone = client.
keystone.
print keystone.
Traceback (most recent call last): tenants. list() sskripnick/ code/python- keystoneclient/ keystoneclient/ v2_0/tenants. py", line 118, in list "/tenants% s" % query, "tenants") sskripnick/ code/python- keystoneclient/ keystoneclient/ base.py" , line 106, in _list get(url) sskripnick/ code/python- keystoneclient/ keystoneclient/ httpclient. py", line 590, in get request( url, 'GET', **kwargs) sskripnick/ code/python- keystoneclient/ keystoneclient/ httpclient. py", line 582, in _cs_request sskripnick/ code/python- keystoneclient/ keystoneclient/ httpclient. py", line 564, in request sskripnick/ code/python- keystoneclient/ keystoneclient/ baseclient. py", line 21, in request request( url, method, **kwargs) sskripnick/ code/python- keystoneclient/ keystoneclient/ utils.py" , line 318, in inner sskripnick/ code/python- keystoneclient/ keystoneclient/ session. py", line 257, in request request( url, method, redirect, **kwargs) sskripnick/ code/python- keystoneclient/ keystoneclient/ session. py", line 286, in _send_request ConnectionRefus ed(msg) openstack. common. apiclient. exceptions. ConnectionRefus ed: Unable to establish connection to http:// 192.168. 0.2:35357/ v2.0/tenants
File "/tmp/k.py", line 5, in <module>
print keystone.
File "/home/
tenant_list = self._list(
File "/home/
resp, body = self.client.
File "/home/
return self._cs_
File "/home/
return self.request(url, method, **kwargs)
File "/home/
resp = super(HTTPClient, self).request(url, method, **kwargs)
File "/home/
return self.session.
File "/home/
return func(*args, **kwargs)
File "/home/
resp = self._send_
File "/home/
raise exceptions.
keystoneclient.
But all works fine when I add `endpoint' argument:
from keystoneclient.v2_0 import client 172.18. 200.196: 5000/v2. 0' Client( username= USERNAME, password=PASSWORD, tenant_name=TENANT,
auth_ url=AUTH_ URL, endpoint=AUTH_URL) authenticate( ) tenants. list()
USERNAME, PASSWORD, TENANT, AUTH_URL = 'rally', 'rally', 'rally', 'http://
keystone = client.
keystone.
print keystone.
With `endpoint' it works even with port 35357