Skip to content

Commit 01f4a60

Browse files
committed
Add README.md and tutorial walkthrough for script-only tutorials
1 parent b764fed commit 01f4a60

10 files changed

Lines changed: 317 additions & 0 deletions

File tree

tuts/176-s3-encryption/README.md

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
# S3 Encryption
2+
3+
An AWS CLI tutorial that demonstrates S3 operations.
4+
5+
## Running
6+
7+
```bash
8+
bash s3-encryption.sh
9+
```
10+
11+
To auto-run with cleanup:
12+
13+
```bash
14+
echo 'y' | bash s3-encryption.sh
15+
```
16+
17+
## What it does
18+
19+
1. Creating bucket"; B="enc-tut-$(cat /dev/urandom | tr -dc 'a-z0-9' | fold -w 8 | head -n 1)-$(aws sts get-caller-identity --query Account --output text)"; aws s3api create-bucket --bucket "$B" > /dev/null; echo "Step 2: Enabling SSE-S3"; aws s3api put-bucket-encryption --bucket "$B" --server-side-encryption-configuration '{"Rules":[{"ApplyServerSideEncryptionByDefault":{"SSEAlgorithm":"AES256"}}]}'; echo "Step 3: Checking encryption"; aws s3api get-bucket-encryption --bucket "$B" --query "ServerSideEncryptionConfiguration.Rules[0].ApplyServerSideEncryptionByDefault" --output table; echo "Step 4: Uploading encrypted object"; echo test > /tmp/enc.txt; aws s3 cp /tmp/enc.txt "s3://$B/test.txt" --quiet; aws s3api head-object --bucket "$B" --key test.txt --query "{Encryption:ServerSideEncryption}" --output table; echo "Do you want to clean up? (y/n): "; read -r C; [[ "$C" =~ ^[Yy]$ ]] && { aws s3 rm "s3://$B" --recursive --quiet; aws s3 rb "s3://$B
20+
21+
## Resources created
22+
23+
- Bucket
24+
- Bucket Encryption
25+
26+
The script prompts you to clean up resources when it finishes.
27+
28+
## Cost
29+
30+
Free tier eligible for most operations. Clean up resources after use to avoid charges.
31+
32+
## Related docs
33+
34+
- [AWS CLI s3 reference](https://docs.aws.amazon.com/cli/latest/reference/s3/index.html)
35+
- [AWS CLI s3api reference](https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html)
36+
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# S3 Encryption
2+
3+
## Prerequisites
4+
5+
1. AWS CLI installed and configured (`aws configure`)
6+
2. Appropriate IAM permissions for the AWS services used
7+
8+
## Step 1: Creating bucket"; B="enc-tut-$(cat /dev/urandom | tr -dc 'a-z0-9' | fold -w 8 | head -n 1)-$(aws sts get-caller-identity --query Account --output text)"; aws s3api create-bucket --bucket "$B" > /dev/null; echo "Step 2: Enabling SSE-S3"; aws s3api put-bucket-encryption --bucket "$B" --server-side-encryption-configuration '{"Rules":[{"ApplyServerSideEncryptionByDefault":{"SSEAlgorithm":"AES256"}}]}'; echo "Step 3: Checking encryption"; aws s3api get-bucket-encryption --bucket "$B" --query "ServerSideEncryptionConfiguration.Rules[0].ApplyServerSideEncryptionByDefault" --output table; echo "Step 4: Uploading encrypted object"; echo test > /tmp/enc.txt; aws s3 cp /tmp/enc.txt "s3://$B/test.txt" --quiet; aws s3api head-object --bucket "$B" --key test.txt --query "{Encryption:ServerSideEncryption}" --output table; echo "Do you want to clean up? (y/n): "; read -r C; [[ "$C" =~ ^[Yy]$ ]] && { aws s3 rm "s3://$B" --recursive --quiet; aws s3 rb "s3://$B
9+
10+
The script handles this step automatically. See `s3-encryption.sh` for the exact CLI commands.
11+
12+
## Cleanup
13+
14+
The script prompts you to clean up all created resources. If you need to clean up manually, check the script log for the resource names that were created.
15+
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
# S3 Access Points
2+
3+
An AWS CLI tutorial that demonstrates S3 operations.
4+
5+
## Running
6+
7+
```bash
8+
bash s3-access-points.sh
9+
```
10+
11+
To auto-run with cleanup:
12+
13+
```bash
14+
echo 'y' | bash s3-access-points.sh
15+
```
16+
17+
## What it does
18+
19+
1. Creating bucket
20+
2. Creating access point: $AP_NAME
21+
3. Getting access point details
22+
4. Listing access points
23+
24+
## Resources created
25+
26+
- Access Point
27+
- Bucket
28+
29+
The script prompts you to clean up resources when it finishes.
30+
31+
## Cost
32+
33+
Free tier eligible for most operations. Clean up resources after use to avoid charges.
34+
35+
## Related docs
36+
37+
- [AWS CLI s3 reference](https://docs.aws.amazon.com/cli/latest/reference/s3/index.html)
38+
- [AWS CLI s3api reference](https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html)
39+
- [AWS CLI s3control reference](https://docs.aws.amazon.com/cli/latest/reference/s3control/index.html)
40+
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# S3 Access Points
2+
3+
## Prerequisites
4+
5+
1. AWS CLI installed and configured (`aws configure`)
6+
2. Appropriate IAM permissions for the AWS services used
7+
8+
## Step 1: Creating bucket
9+
10+
The script handles this step automatically. See `s3-access-points.sh` for the exact CLI commands.
11+
12+
## Step 2: Creating access point: $AP_NAME
13+
14+
The script handles this step automatically. See `s3-access-points.sh` for the exact CLI commands.
15+
16+
## Step 3: Getting access point details
17+
18+
The script handles this step automatically. See `s3-access-points.sh` for the exact CLI commands.
19+
20+
## Step 4: Listing access points
21+
22+
The script handles this step automatically. See `s3-access-points.sh` for the exact CLI commands.
23+
24+
## Cleanup
25+
26+
The script prompts you to clean up all created resources. If you need to clean up manually, check the script log for the resource names that were created.
27+

tuts/186-s3-object-lock/README.md

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
# S3 Object Lock
2+
3+
An AWS CLI tutorial that demonstrates S3 operations.
4+
5+
## Running
6+
7+
```bash
8+
bash s3-object-lock.sh
9+
```
10+
11+
To auto-run with cleanup:
12+
13+
```bash
14+
echo 'y' | bash s3-object-lock.sh
15+
```
16+
17+
## What it does
18+
19+
1. Creating bucket with Object Lock
20+
2. Setting default retention (1 day governance mode)
21+
3. Getting lock configuration
22+
4. Uploading a locked object
23+
5. Verifying lock
24+
25+
## Resources created
26+
27+
- Bucket
28+
- Bucket Versioning
29+
- Object Lock Configuration
30+
31+
The script prompts you to clean up resources when it finishes.
32+
33+
## Cost
34+
35+
Free tier eligible for most operations. Clean up resources after use to avoid charges.
36+
37+
## Related docs
38+
39+
- [AWS CLI s3 reference](https://docs.aws.amazon.com/cli/latest/reference/s3/index.html)
40+
- [AWS CLI s3api reference](https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html)
41+
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
# S3 Object Lock
2+
3+
## Prerequisites
4+
5+
1. AWS CLI installed and configured (`aws configure`)
6+
2. Appropriate IAM permissions for the AWS services used
7+
8+
## Step 1: Creating bucket with Object Lock
9+
10+
The script handles this step automatically. See `s3-object-lock.sh` for the exact CLI commands.
11+
12+
## Step 2: Setting default retention (1 day governance mode)
13+
14+
The script handles this step automatically. See `s3-object-lock.sh` for the exact CLI commands.
15+
16+
## Step 3: Getting lock configuration
17+
18+
The script handles this step automatically. See `s3-object-lock.sh` for the exact CLI commands.
19+
20+
## Step 4: Uploading a locked object
21+
22+
The script handles this step automatically. See `s3-object-lock.sh` for the exact CLI commands.
23+
24+
## Step 5: Verifying lock
25+
26+
The script handles this step automatically. See `s3-object-lock.sh` for the exact CLI commands.
27+
28+
## Cleanup
29+
30+
The script prompts you to clean up all created resources. If you need to clean up manually, check the script log for the resource names that were created.
31+
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
# S3 Transfer Acceleration
2+
3+
An AWS CLI tutorial that demonstrates S3 operations.
4+
5+
## Running
6+
7+
```bash
8+
bash s3-transfer-acceleration.sh
9+
```
10+
11+
To auto-run with cleanup:
12+
13+
```bash
14+
echo 'y' | bash s3-transfer-acceleration.sh
15+
```
16+
17+
## What it does
18+
19+
1. Creating bucket
20+
2. Enabling Transfer Acceleration
21+
3. Getting acceleration status
22+
4. Accelerated endpoint
23+
24+
## Resources created
25+
26+
- Bucket
27+
- Bucket Accelerate Configuration
28+
29+
The script prompts you to clean up resources when it finishes.
30+
31+
## Cost
32+
33+
Free tier eligible for most operations. Clean up resources after use to avoid charges.
34+
35+
## Related docs
36+
37+
- [AWS CLI s3 reference](https://docs.aws.amazon.com/cli/latest/reference/s3/index.html)
38+
- [AWS CLI s3api reference](https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html)
39+
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# S3 Transfer Acceleration
2+
3+
## Prerequisites
4+
5+
1. AWS CLI installed and configured (`aws configure`)
6+
2. Appropriate IAM permissions for the AWS services used
7+
8+
## Step 1: Creating bucket
9+
10+
The script handles this step automatically. See `s3-transfer-acceleration.sh` for the exact CLI commands.
11+
12+
## Step 2: Enabling Transfer Acceleration
13+
14+
The script handles this step automatically. See `s3-transfer-acceleration.sh` for the exact CLI commands.
15+
16+
## Step 3: Getting acceleration status
17+
18+
The script handles this step automatically. See `s3-transfer-acceleration.sh` for the exact CLI commands.
19+
20+
## Step 4: Accelerated endpoint
21+
22+
The script handles this step automatically. See `s3-transfer-acceleration.sh` for the exact CLI commands.
23+
24+
## Cleanup
25+
26+
The script prompts you to clean up all created resources. If you need to clean up manually, check the script log for the resource names that were created.
27+

tuts/196-s3-inventory/README.md

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
# S3 Inventory
2+
3+
An AWS CLI tutorial that demonstrates S3 operations.
4+
5+
## Running
6+
7+
```bash
8+
bash s3-inventory.sh
9+
```
10+
11+
To auto-run with cleanup:
12+
13+
```bash
14+
echo 'y' | bash s3-inventory.sh
15+
```
16+
17+
## What it does
18+
19+
1. Creating source and destination buckets
20+
2. Configuring inventory
21+
3. Getting inventory configuration
22+
23+
## Resources created
24+
25+
- Bucket
26+
- Bucket Inventory Configuration
27+
28+
The script prompts you to clean up resources when it finishes.
29+
30+
## Cost
31+
32+
Free tier eligible for most operations. Clean up resources after use to avoid charges.
33+
34+
## Related docs
35+
36+
- [AWS CLI s3 reference](https://docs.aws.amazon.com/cli/latest/reference/s3/index.html)
37+
- [AWS CLI s3api reference](https://docs.aws.amazon.com/cli/latest/reference/s3api/index.html)
38+
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# S3 Inventory
2+
3+
## Prerequisites
4+
5+
1. AWS CLI installed and configured (`aws configure`)
6+
2. Appropriate IAM permissions for the AWS services used
7+
8+
## Step 1: Creating source and destination buckets
9+
10+
The script handles this step automatically. See `s3-inventory.sh` for the exact CLI commands.
11+
12+
## Step 2: Configuring inventory
13+
14+
The script handles this step automatically. See `s3-inventory.sh` for the exact CLI commands.
15+
16+
## Step 3: Getting inventory configuration
17+
18+
The script handles this step automatically. See `s3-inventory.sh` for the exact CLI commands.
19+
20+
## Cleanup
21+
22+
The script prompts you to clean up all created resources. If you need to clean up manually, check the script log for the resource names that were created.
23+

0 commit comments

Comments
 (0)