From 3a620e8f201a2e974e8d786d231be44e49e289af Mon Sep 17 00:00:00 2001 From: Waldemar Hummer Date: Tue, 18 Aug 2026 15:59:17 +0200 Subject: [PATCH 1/2] Stop setup.sh from overwriting ~/.aws/credentials and ~/.aws/config The script truncated both files to write dummy LocalStack credentials into the default profile, wiping out any existing real AWS profiles. Switch the verification step to awslocal, which already sets dummy credentials via env vars per-invocation and never touches ~/.aws, consistent with how every other module in the workshop connects to LocalStack. Co-Authored-By: Claude Sonnet 5 --- 00-setup/setup.sh | 18 +----------------- 1 file changed, 1 insertion(+), 17 deletions(-) diff --git a/00-setup/setup.sh b/00-setup/setup.sh index 9cf4c3d..f83422e 100755 --- a/00-setup/setup.sh +++ b/00-setup/setup.sh @@ -16,22 +16,6 @@ else echo "Using existing LOCALSTACK_AUTH_TOKEN." fi -echo "" -echo "Configuring AWS CLI default profile for LocalStack..." -mkdir -p "${HOME}/.aws" -cat > "${HOME}/.aws/credentials" << 'EOF' -[default] -aws_access_key_id = test -aws_secret_access_key = test -EOF -cat > "${HOME}/.aws/config" << 'EOF' -[default] -region = us-east-1 -endpoint_url = http://localhost:4566 -output = json -EOF -echo "AWS CLI profile configured." - echo "" echo "Starting LocalStack..." localstack start -d @@ -42,7 +26,7 @@ localstack wait -t 60 echo "" echo "Verifying..." -aws s3 ls > /dev/null && echo "OK: aws CLI connected (via default profile)" +awslocal s3 ls > /dev/null && echo "OK: awslocal connected" curl -sf http://localhost:4566/_localstack/health | python3 -m json.tool | grep -q '"running"' && echo "OK: health check passed" echo "" From f12b55610de6e164d298bc31d02843c8824ff264 Mon Sep 17 00:00:00 2001 From: Waldemar Hummer Date: Tue, 18 Aug 2026 16:05:34 +0200 Subject: [PATCH 2/2] Drop awscli-local[ver1] extra in CI to fix broken awslocal invocation The ver1 extra pulls in the classic Python-importable awscli v1 package, which awslocal then calls in-process. That in-process path still imports botocore.vendored, a module removed from modern botocore, so it crashed with ModuleNotFoundError. Without the extra, awslocal shells out to the standalone aws CLI v2 binary already preinstalled on the runner instead. Co-Authored-By: Claude Sonnet 5 --- .github/workflows/build-test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-test.yml b/.github/workflows/build-test.yml index 48756de..0599e09 100644 --- a/.github/workflows/build-test.yml +++ b/.github/workflows/build-test.yml @@ -15,7 +15,7 @@ jobs: - name: Install tools run: | - pip install --pre localstack awscli-local[ver1] terraform-local pytest requests + pip install --pre localstack awscli-local terraform-local pytest requests # Terraform curl -fsSL https://apt.releases.hashicorp.com/gpg | sudo gpg --dearmor -o /usr/share/keyrings/hashicorp-archive-keyring.gpg