*/
RestContext<CloudStackClient, CloudStackAsyncClient> newCloudStackClient(Provider provider) {
checkArgument(provider.getEndpoint().isPresent(), "please specify an endpoint for this provider");
Properties overrides = new Properties();
overrides.setProperty(Constants.PROPERTY_TRUST_ALL_CERTS, "true");
return ContextBuilder.newBuilder(new CloudStackApiMetadata())
.endpoint(provider.getEndpoint().get())
.modules(ImmutableSet.<Module>of(new SLF4JLoggingModule()))
.credentials(provider.getAccessKey(), provider.getSecretKey())
.overrides(overrides)
.build(CloudStackApiMetadata.CONTEXT_TOKEN);