diff --git a/kork-secrets-aws/src/test/java/com/netflix/spinnaker/kork/secrets/engines/SecretsManagerSecretEngineIntegrationTest.java b/kork-secrets-aws/src/test/java/com/netflix/spinnaker/kork/secrets/engines/SecretsManagerSecretEngineIntegrationTest.java index 1add9dbc6..978bff97a 100644 --- a/kork-secrets-aws/src/test/java/com/netflix/spinnaker/kork/secrets/engines/SecretsManagerSecretEngineIntegrationTest.java +++ b/kork-secrets-aws/src/test/java/com/netflix/spinnaker/kork/secrets/engines/SecretsManagerSecretEngineIntegrationTest.java @@ -18,6 +18,9 @@ import static org.junit.jupiter.api.Assertions.assertEquals; +import com.amazonaws.auth.AWSStaticCredentialsProvider; +import com.amazonaws.auth.BasicAWSCredentials; +import com.amazonaws.client.builder.AwsClientBuilder; import com.amazonaws.services.secretsmanager.AWSSecretsManager; import com.amazonaws.services.secretsmanager.AWSSecretsManagerClientBuilder; import com.amazonaws.services.secretsmanager.model.CreateSecretRequest; @@ -60,8 +63,11 @@ public void canDecryptUserSecret() { AWSSecretsManager client = AWSSecretsManagerClientBuilder.standard() .withEndpointConfiguration( - container.getEndpointConfiguration(LocalStackContainer.Service.SECRETSMANAGER)) - .withCredentials(container.getDefaultCredentialsProvider()) + new AwsClientBuilder.EndpointConfiguration( + container.getEndpoint().toString(), container.getRegion())) + .withCredentials( + new AWSStaticCredentialsProvider( + new BasicAWSCredentials(container.getAccessKey(), container.getSecretKey()))) .build(); UserSecretMetadata metadata = @@ -121,8 +127,11 @@ public SecretsManagerClientProvider localstackClientProvider(LocalStackContainer return (params) -> AWSSecretsManagerClientBuilder.standard() .withEndpointConfiguration( - container.getEndpointConfiguration(LocalStackContainer.Service.SECRETSMANAGER)) - .withCredentials(container.getDefaultCredentialsProvider()) + new AwsClientBuilder.EndpointConfiguration( + container.getEndpoint().toString(), container.getRegion())) + .withCredentials( + new AWSStaticCredentialsProvider( + new BasicAWSCredentials(container.getAccessKey(), container.getSecretKey()))) .build(); } diff --git a/spinnaker-dependencies/spinnaker-dependencies.gradle b/spinnaker-dependencies/spinnaker-dependencies.gradle index 490031489..34d9fba10 100644 --- a/spinnaker-dependencies/spinnaker-dependencies.gradle +++ b/spinnaker-dependencies/spinnaker-dependencies.gradle @@ -70,7 +70,7 @@ dependencies { api(platform("io.strikt:strikt-bom:0.31.0")) api(platform("org.spockframework:spock-bom:2.0-groovy-3.0")) api(platform("com.oracle.oci.sdk:oci-java-sdk-bom:3.21.0")) - api(platform("org.testcontainers:testcontainers-bom:1.16.2")) + api(platform("org.testcontainers:testcontainers-bom:1.19.6")) api(platform("io.arrow-kt:arrow-stack:${versions.arrow}")) constraints {