Skip to content

Commit 4194ace

Browse files
committed
Fix 043-mq (AWS_REGION fallback), 015-vpc-peering (log path), 028-sagemaker (shared bucket skip)
Also: 053-config, 082-polly, 046-ssm, 066-cognito, 067-payment-crypto from earlier. 37/68 pass locally. 5 VPC limit, 14 service/prereq, 5 script bugs remaining.
1 parent 0445bc8 commit 4194ace

3 files changed

Lines changed: 8 additions & 4 deletions

File tree

tuts/015-vpc-peering/vpc-peering.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ set -euo pipefail
1111
umask 0077
1212

1313
# Initialize log file with restricted permissions
14-
LOG_FILE="vpc-peering-script-v6.log"
14+
LOG_FILE="./vpc-peering-script-v6.log"
1515
touch "$LOG_FILE"
1616
chmod 0600 "$LOG_FILE"
1717
echo "Starting VPC Peering script at $(date)" > "$LOG_FILE"

tuts/028-sagemaker-featurestore/sagemaker-featurestore.sh

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,8 @@ PREFIX="featurestore-tutorial"
216216
CURRENT_TIME=$(date +%s)
217217

218218
echo "Creating S3 bucket: $S3_BUCKET_NAME"
219-
# Create bucket in current region
219+
# Create bucket in current region (skip if using shared bucket)
220+
if [ "$BUCKET_IS_SHARED" = "false" ]; then
220221
if [ "$REGION" = "us-east-1" ]; then
221222
BUCKET_RESULT=$(aws s3api create-bucket --bucket "$S3_BUCKET_NAME" \
222223
--region "$REGION" 2>&1)
@@ -244,6 +245,9 @@ if echo "$BLOCK_RESULT" | grep -i "error" > /dev/null; then
244245
cleanup_resources
245246
exit 1
246247
fi
248+
else
249+
echo "Using shared bucket (skipping creation)"
250+
fi
247251

248252
# Create feature groups
249253
echo "Creating feature groups..."

tuts/043-amazon-mq-gs/amazon-mq-gs.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@ validate_aws_credentials() {
2424
fi
2525

2626
if [ -z "${AWS_REGION:-}" ]; then
27-
echo "ERROR: AWS_REGION environment variable not set"
28-
exit 1
27+
AWS_REGION=$(aws configure get region 2>/dev/null || echo "us-west-2")
28+
export AWS_REGION
2929
fi
3030
}
3131

0 commit comments

Comments
 (0)