Skip to content

Commit 76df3c1

Browse files
committed
Apply technical requirements (R1, R2, R9, R10, R13)
- R1: Add AWS_REGION to region fallback chain - R2: Replace openssl rand with /dev/urandom - R9: Remove Appendix/Generation details from READMEs - R10: Remove internal references - R13: Add REVISION-HISTORY.md
1 parent e198f7c commit 76df3c1

11 files changed

Lines changed: 45 additions & 17 deletions

File tree

tuts/114-amazon-transcribe-gs/README.md

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -40,15 +40,3 @@ Transcribe pricing is per second of audio transcribed. This tutorial transcribes
4040
- [Amazon Transcribe API reference](https://docs.aws.amazon.com/transcribe/latest/APIReference/Welcome.html)
4141
- [Supported languages](https://docs.aws.amazon.com/transcribe/latest/dg/supported-languages.html)
4242
- [Amazon Transcribe pricing](https://aws.amazon.com/transcribe/pricing/)
43-
44-
---
45-
46-
## Appendix: Generation details
47-
48-
| Field | Value |
49-
|-------|-------|
50-
| Generation date | 2026-04-14 |
51-
| Source script | New, 106 lines |
52-
| Script test result | EXIT 0, 16s, 6 steps, no issues |
53-
| Issues encountered | None |
54-
| Iterations | v1 |
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# Revision History: 114-amazon-transcribe-gs
2+
3+
## Shell (CLI script)
4+
5+
### 2026-04-14 v1 published
6+
- Type: functional
7+
- Initial version
8+

tuts/114-amazon-transcribe-gs/amazon-transcribe-gs.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ export AWS_DEFAULT_REGION="$REGION"
1515
ACCOUNT_ID=$(aws sts get-caller-identity --query 'Account' --output text)
1616
echo "Region: $REGION"
1717

18-
RANDOM_ID=$(openssl rand -hex 4)
18+
RANDOM_ID=$(cat /dev/urandom | tr -dc 'a-z0-9' | fold -w 8 | head -n 1)
1919
BUCKET_NAME="transcribe-tut-${RANDOM_ID}-${ACCOUNT_ID}"
2020
JOB_NAME="tut-job-${RANDOM_ID}"
2121

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# Revision History: 118-amazon-lex-gs
2+
3+
## Shell (CLI script)
4+
5+
### 2026-04-14 v1 published
6+
- Type: functional
7+
- Initial version
8+

tuts/118-amazon-lex-gs/amazon-lex-gs.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ fi
1414
export AWS_DEFAULT_REGION="$REGION"
1515
echo "Region: $REGION"
1616

17-
RANDOM_ID=$(openssl rand -hex 4)
17+
RANDOM_ID=$(cat /dev/urandom | tr -dc 'a-z0-9' | fold -w 8 | head -n 1)
1818
BOT_NAME="tut-bot-${RANDOM_ID}"
1919
ROLE_NAME="lex-tut-role-${RANDOM_ID}"
2020

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# Revision History: 123-amazon-bedrock-gs
2+
3+
## Shell (CLI script)
4+
5+
### 2026-04-14 v1 published
6+
- Type: functional
7+
- Initial version
8+

tuts/123-amazon-bedrock-gs/amazon-bedrock-gs.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#!/bin/bash
22
WORK_DIR=$(mktemp -d)
33
exec > >(tee -a "$WORK_DIR/bedrock-$(date +%Y%m%d-%H%M%S).log") 2>&1
4-
REGION=${AWS_DEFAULT_REGION:-$(aws configure get region 2>/dev/null)}
4+
REGION=${AWS_DEFAULT_REGION:-${AWS_REGION:-$(aws configure get region 2>/dev/null))}
55
[ -z "$REGION" ] && echo "ERROR: No region" && exit 1
66
export AWS_DEFAULT_REGION="$REGION"
77
echo "Region: $REGION"
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# Revision History: 149-aws-lakeformation-gs
2+
3+
## Shell (CLI script)
4+
5+
### 2026-04-14 v1 published
6+
- Type: functional
7+
- Initial version
8+

tuts/149-aws-lakeformation-gs/aws-lakeformation-gs.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/bash
22
WORK_DIR=$(mktemp -d); exec > >(tee -a "$WORK_DIR/lf.log") 2>&1
3-
REGION=${AWS_DEFAULT_REGION:-$(aws configure get region 2>/dev/null)}; [ -z "$REGION" ] && echo "ERROR: No region" && exit 1; export AWS_DEFAULT_REGION="$REGION"; echo "Region: $REGION"
3+
REGION=${AWS_DEFAULT_REGION:-${AWS_REGION:-$(aws configure get region 2>/dev/null))}; [ -z "$REGION" ] && echo "ERROR: No region" && exit 1; export AWS_DEFAULT_REGION="$REGION"; echo "Region: $REGION"
44
echo "Step 1: Getting data lake settings"
55
aws lakeformation get-data-lake-settings --query 'DataLakeSettings.{Admins:DataLakeAdmins|length(@),CreateDBDefault:CreateDatabaseDefaultPermissions|length(@)}' --output table
66
echo "Step 2: Listing resources"
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# Revision History: 212-cloudwatch-list-alarms
2+
3+
## Shell (CLI script)
4+
5+
### 2026-04-14 v1 published
6+
- Type: functional
7+
- Initial version
8+

0 commit comments

Comments
 (0)