rackspace / gophercloud

A Go SDK for OpenStack. IN FEATURE FREEZE. See Issue #592
http://gophercloud.io
Other
456 stars 181 forks source link

IdentityBase #577

Open suonto opened 8 years ago

suonto commented 8 years ago

File: github.com/rackspace/gophercloud/openstack/client.go Function: NewClient

Issue: endpoint given is https://example.com/api/keystone/v3 IdentityBase resolves to https://example.com It seems like IdentityBase should resolve to https://example.com/api/keystone, as endpoints are reconstructed like this: v3Endpoint := client.IdentityBase + "v3/"

Problem in action: I'm running kubernetes with openstack provider and after an hour I'm starting to get errors like this:

openstack.go:284] Failed to find compute flavors: Error trying to re-authenticate: Expected HTTP response code [201 202] when accessing [POST https://example.com/v3/auth/tokens], but got 404 instead

I'm guessing the re-authentication is reconstructing identity endpoint from IdentityBase and fails because the path will be missing /api/keystone.