Use the cinder v1 apis until client bug fixed.
Change-Id: Ie0fa4444d926516b61eb5b636b4986f1607521f1
This commit is contained in:
@@ -16,20 +16,25 @@
|
|||||||
|
|
||||||
from anvil import utils
|
from anvil import utils
|
||||||
|
|
||||||
|
# v1 seems correct until bug 1190331 is fixed
|
||||||
|
# where the cinderclient doesn't seem to know anything
|
||||||
|
# beyond v1 unless told.
|
||||||
|
VERSION = "v1"
|
||||||
|
|
||||||
|
|
||||||
def get_shared_params(ip, api_host, api_port=8776, protocol='http', **kwargs):
|
def get_shared_params(ip, api_host, api_port=8776, protocol='http', **kwargs):
|
||||||
mp = {}
|
mp = {}
|
||||||
mp['service_host'] = ip
|
mp['service_host'] = ip
|
||||||
|
|
||||||
# Uri's of the various cinder endpoints
|
# Uri's of the various cinder endpoints
|
||||||
mp['endpoints'] = {
|
mp['endpoints'] = {
|
||||||
'volume': {
|
'admin': {
|
||||||
'uri': utils.make_url(protocol, api_host, api_port, "v2"),
|
'uri': utils.make_url(protocol, api_host, api_port, VERSION),
|
||||||
'port': api_port,
|
'port': api_port,
|
||||||
'host': api_host,
|
'host': api_host,
|
||||||
'protocol': protocol,
|
'protocol': protocol,
|
||||||
},
|
},
|
||||||
'internal': {
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
mp['endpoints']['internal'] = dict(mp['endpoints']['admin'])
|
||||||
|
mp['endpoints']['public'] = dict(mp['endpoints']['admin'])
|
||||||
return mp
|
return mp
|
||||||
|
@@ -25,9 +25,9 @@ endpoints:
|
|||||||
public_url: "$glance.endpoints.public.uri"
|
public_url: "$glance.endpoints.public.uri"
|
||||||
region: RegionOne
|
region: RegionOne
|
||||||
- service: volume
|
- service: volume
|
||||||
admin_url: "${cinder.endpoints.volume.uri}/%(tenant_id)s"
|
admin_url: "${cinder.endpoints.admin.uri}/%(tenant_id)s"
|
||||||
internal_url: "${cinder.endpoints.volume.uri}/%(tenant_id)s"
|
internal_url: "${cinder.endpoints.internal.uri}/%(tenant_id)s"
|
||||||
public_url: "${cinder.endpoints.volume.uri}/%(tenant_id)s"
|
public_url: "${cinder.endpoints.public.uri}/%(tenant_id)s"
|
||||||
region: RegionOne
|
region: RegionOne
|
||||||
- service: s3
|
- service: s3
|
||||||
admin_url: "$nova.endpoints.s3.uri"
|
admin_url: "$nova.endpoints.s3.uri"
|
||||||
|
Reference in New Issue
Block a user