From 58198e07de030682cb1dae9bb04c76b738465328 Mon Sep 17 00:00:00 2001 From: HVbajoria Date: Mon, 13 Oct 2025 16:49:53 +0530 Subject: [PATCH] Migrate from deprecated LOCALSTACK_API_KEY to LOCALSTACK_AUTH_TOKEN --- .github/workflows/makefile.yml | 2 +- emr-serverless-python-dependencies/docker-compose.yml | 1 - java-notification-app/README.md | 2 +- route53-dns-failover/README.md | 2 +- .../spring-cloud-function-microservice/.env.example | 2 +- .../LocalStackTestcontainers/src/test/java/TestRDS.java | 4 ++-- 6 files changed, 6 insertions(+), 7 deletions(-) diff --git a/.github/workflows/makefile.yml b/.github/workflows/makefile.yml index d2a2fb6..073b4ff 100644 --- a/.github/workflows/makefile.yml +++ b/.github/workflows/makefile.yml @@ -44,7 +44,7 @@ jobs: - name: Execute tests env: - LOCALSTACK_API_KEY: ${{ secrets.TEST_LOCALSTACK_API_KEY }} + LOCALSTACK_AUTH_TOKEN: ${{ secrets.TEST_LOCALSTACK_AUTH_TOKEN }} DNS_ADDRESS: 127.0.0.1 DEBUG: 1 timeout-minutes: 200 diff --git a/emr-serverless-python-dependencies/docker-compose.yml b/emr-serverless-python-dependencies/docker-compose.yml index b0ee95b..c4302bb 100644 --- a/emr-serverless-python-dependencies/docker-compose.yml +++ b/emr-serverless-python-dependencies/docker-compose.yml @@ -11,7 +11,6 @@ services: environment: # Activate LocalStack Pro: https://docs.localstack.cloud/getting-started/auth-token/ - LOCALSTACK_AUTH_TOKEN=${LOCALSTACK_AUTH_TOKEN:-} # required for Pro - - LOCALSTACK_API_KEY=${LOCALSTACK_API_KEY:-} # required for CI # LocalStack configuration: https://docs.localstack.cloud/references/configuration/ - DEBUG=${DEBUG:-0} - PERSISTENCE=${PERSISTENCE:-0} diff --git a/java-notification-app/README.md b/java-notification-app/README.md index dd0a1de..64e6839 100644 --- a/java-notification-app/README.md +++ b/java-notification-app/README.md @@ -29,7 +29,7 @@ Resources are deployed via a CloudFormation template in `src/main/resources/emai First, start LocalStack and the SMTP server with: - LOCALSTACK_AUTH_TOKEN= docker-compose up -d + LOCALSTACK_AUTH_TOKEN= docker-compose up -d Then deploy the cloudformation stack (can take a few seconds) diff --git a/route53-dns-failover/README.md b/route53-dns-failover/README.md index 987dd16..7d029d1 100644 --- a/route53-dns-failover/README.md +++ b/route53-dns-failover/README.md @@ -5,7 +5,7 @@ We suggest taking a look at [run.sh](run.sh) script to understand the setup. To run the demo: ``` -$ LOCALSTACK_AUTH_TOKEN= docker-compose up -d +$ LOCALSTACK_AUTH_TOKEN= docker-compose up -d ``` ``` diff --git a/sample-archive/spring-cloud-function-microservice/.env.example b/sample-archive/spring-cloud-function-microservice/.env.example index 25656e0..1d2f6aa 100644 --- a/sample-archive/spring-cloud-function-microservice/.env.example +++ b/sample-archive/spring-cloud-function-microservice/.env.example @@ -1 +1 @@ -LOCALSTACK_AUTH_TOKEN= +LOCALSTACK_AUTH_TOKEN= diff --git a/testcontainers-java-sample/LocalStackTestcontainers/src/test/java/TestRDS.java b/testcontainers-java-sample/LocalStackTestcontainers/src/test/java/TestRDS.java index 5d28fc0..ffab28d 100644 --- a/testcontainers-java-sample/LocalStackTestcontainers/src/test/java/TestRDS.java +++ b/testcontainers-java-sample/LocalStackTestcontainers/src/test/java/TestRDS.java @@ -22,7 +22,7 @@ public class TestRDS { private DockerImageName localstackImage = DockerImageName.parse("localstack/localstack-pro:latest"); - private String api_key = System.getenv("LOCALSTACK_AUTH_TOKEN"); + private String authToken = System.getenv("LOCALSTACK_AUTH_TOKEN"); /** * Start LocalStackContainer with exposed Ports. Those ports are used by services like RDS, where several databases can be started, running on different ports. @@ -31,7 +31,7 @@ public class TestRDS { @Rule public LocalStackContainer localstack = new LocalStackContainer(localstackImage) .withExposedPorts(4510, 4511, 4512, 4513, 4514) // TODO the port can have any value between 4510-4559, but LS starts from 4510 - .withEnv("LOCALSTACK_AUTH_TOKEN", api_key) // TODO add your Auth Token here + .withEnv("LOCALSTACK_AUTH_TOKEN", authToken) // TODO add your Auth Token here .withServices(LocalStackContainer.EnabledService.named("rds"));