Create S3 Bucket

Create S3 Bucket

In this section, we will use CloudFormation to create resources for the lab. The CloudFormation stack will create service resources such as an EC2 instance, SNS Topic, and Lambda Function.

  1. Download Template and Lambda Function

Download the CloudFormation template and Lambda Function.

  1. After downloading the CloudFormation template and Lambda Function from the link above:

    • We will create an S3 bucket to store the source files.
    • Access the AWS Management Console, find and select S3.

AWS Backup

  1. In the S3 interface, select Create bucket.

AWS Backup

  1. In the Create bucket interface:

    • Enter Bucket name aws-backup-plan-2026, it must be a unique name; you can choose any name you like (If duplicate, it will cause an error and the bucket cannot be created).

AWS Backup

Note: In this workshop, we will use the Singapore region (ap-southeast-1). If you want to use another region, make sure to switch to the region you want to use when creating workshop-related resources.

  1. Keep the default configuration.

AWS Backup AWS Backup

  1. In the Default encryption section. For Encryption type, select Server-side encryption with Amazon S3 managed keys (SSE-S3).

    In the Bucket Key section, select Enable and finally select Create bucket.

AWS Backup

  1. Complete creating the S3 bucket.

AWS Backup

  1. Create a storage folder.

    • Select Create folder.

AWS Backup

  1. In the folder creation interface:

    • Enter the folder name Backup Plan. In the Server-side encryption section, select Don’t specify an encryption key

    • Finally select Create folder

AWS Backup

AWS Backup

  1. Complete creating the folder.

AWS Backup

  1. In the newly created folder, Upload the downloaded and extracted files.

AWS Backup

  1. In the Upload section:

    • Select Add files.
    • Choose the files you want to upload.
    • Select Upload.

AWS Backup AWS Backup AWS Backup 13. Complete uploading the files. AWS Backup

  1. Configure Permissions for the S3 bucket:

    • For Block public access (bucket settings).

AWS Backup

  1. Uncheck Block all public access:

    • Then select Save changes.

AWS Backup

  1. Confirm by selecting confirm and then select Confirm.

AWS Backup

  1. Next, configure the Bucket policy:

    • Select Edit.

AWS Backup

  1. In the Edit bucket policy interface:

    • Enter the following code and replace with your Bucket ARN.
    {
        "Version": "2012-10-17",
        "Statement": [
            {
                "Sid": "PublicReadGetObject",
                "Effect": "Allow",
                "Principal": "*",
                "Action": [
                    "s3:GetObject"
                ],
                "Resource": [
                    "arn:aws:s3:::Bucket-Name/*"
                ]
            }
        ]
    }
    

AWS Backup

  1. Select Save changes.

AWS Backup

  1. Verify that Permissions are set to Public.

AWS Backup

  1. Copy the path information of lambda_function.zip.

AWS Backup

  1. Copy the Object URL information of the backup-lab.yaml file.

AWS Backup