Skip to content

Commit cdac869

Browse files
committed
Honor endpoint override from config for volume
I'm guessing we should do this for everyone, but we have volume on the brain right now. Rackspace is in the weird situation where they do support v2 but only have v1 in the catalog (wut) So we need to override the block-storage enpdoint by config. To do that, we need to actually honor the config setting over here in OSC. NOTE: We need to systemically overhaul how we're injesting config over here - because there's too much variation. But we can leave that for another day. Story: 2007459 Task: 39137 Change-Id: Ifddf1ddd5abaa768ab18049c09d18bc269f3a4f5
1 parent fc12033 commit cdac869

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

openstackclient/volume/client.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,11 +67,15 @@ def make_client(instance):
6767
# Remember interface only if it is set
6868
kwargs = utils.build_kwargs_dict('endpoint_type', instance.interface)
6969

70+
endpoint_override = instance.sdk_connection.config.get_endpoint(
71+
'block-storage')
72+
7073
client = volume_client(
7174
session=instance.session,
7275
extensions=extensions,
7376
http_log_debug=http_log_debug,
7477
region_name=instance.region_name,
78+
endpoint_override=endpoint_override,
7579
**kwargs
7680
)
7781

0 commit comments

Comments
 (0)