mirror of https://github.com/apache/jclouds.git
Identity should be tenameName:accessKey
tenantId is something else. Tested against hpcloud.
This commit is contained in:
parent
27c07a507d
commit
191a4e7341
|
@ -88,7 +88,7 @@ public class NovaApiMetadata extends BaseRestApiMetadata {
|
|||
super(NovaClient.class, NovaAsyncClient.class);
|
||||
id("openstack-nova")
|
||||
.name("OpenStack Nova Diablo+ API")
|
||||
.identityName("tenantId:user")
|
||||
.identityName("tenantName:accessKey")
|
||||
.credentialName("password")
|
||||
.documentation(URI.create("http://api.openstack.org/"))
|
||||
.version("1.1")
|
||||
|
|
|
@ -41,7 +41,7 @@ public class AuthenticateApiAccessKeyCredentials implements Function<Credentials
|
|||
@Override
|
||||
public Access apply(Credentials input) {
|
||||
if (input.identity.indexOf(':') == -1) {
|
||||
throw new AuthorizationException(String.format("Identity %s does not match format tenantId:accesskey",
|
||||
throw new AuthorizationException(String.format("Identity %s does not match format tenantName:accessKey",
|
||||
input.identity), null);
|
||||
}
|
||||
|
||||
|
|
|
@ -79,7 +79,7 @@ public class HPCloudComputeProviderMetadata extends BaseProviderMetadata {
|
|||
id("hpcloud-compute")
|
||||
.name("HP Cloud Compute Services")
|
||||
.apiMetadata(new NovaApiMetadata().toBuilder()
|
||||
.identityName("tenantId:accessKey")
|
||||
.identityName("tenantName:accessKey")
|
||||
.credentialName("secretKey")
|
||||
.defaultModules(ImmutableSet.<Class<? extends Module>>of(NovaRestClientModule.class, HPCloudComputeServiceContextModule.class))
|
||||
.build())
|
||||
|
|
|
@ -83,7 +83,7 @@ public class HPCloudObjectStorageApiMetadata extends BaseRestApiMetadata {
|
|||
super(HPCloudObjectStorageClient.class, HPCloudObjectStorageAsyncClient.class);
|
||||
id("hpcloud-objectstorage")
|
||||
.name("HP Cloud Services Object Storage API")
|
||||
.identityName("tenantId:accessKey")
|
||||
.identityName("tenantName:accessKey")
|
||||
.credentialName("secretKey")
|
||||
.version("1.0")
|
||||
.documentation(URI.create("https://build.hpcloud.com/object-storage/api"))
|
||||
|
|
Loading…
Reference in New Issue