Create Private S3 Bucket via AWS CLI
How to Use AWS CLI for Creating Private S3 Buckets

Infosec Poet and CAP-certified DevOps/SecOps Engineer, passionate about security, creativity, and continuous learning.
Tasks
Create a S3 bucket through aws-cli with the following details:
The name of the S3 bucket must be
xfusion-s3-29022.The S3 bucket must block all
publicaccess, i.e., it must be aprivatebucket.
Steps
Create the S3 bucket named
xfusion-s3-29022in theus-east-1region:aws s3api create-bucket --bucket xfusion-s3-29022 --region us-east-1Block all public access to the bucket to make it private:
aws s3api put-public-access-block \ --bucket xfusion-s3-29022 \ --public-access-block-configuration BlockPublicAcls=true,IgnorePublicAcls=true,BlockPublicPolicy=true,RestrictPublicBuckets=trueAWS CLI

Verify now.

#aws #cloudcomputing #happylearning





