Ravi Sir's Cyber Security Cards › Revision Cards
Creating a Bucket and Uploading Objects
Creating a Bucket and Uploading Objects Making an S3 bucket and putting files in it. S3 → Create bucket . Name: lowercase, numbers and hyphens, 3–63 characters. Region: ap-south-1 (Mumbai). Keep ACLs disabled , so only policies control access. aws s3 cp file.txt s3://my-bucket/ uploads one file. aws

Read card text
What this card says
What it is
Making an S3 bucket and putting files in it.
Steps
S3 → Create bucket. Name: lowercase, numbers and hyphens, 3–63 characters.
Region: ap-south-1 (Mumbai). Keep ACLs disabled, so only policies control access.
CLI
aws s3 cp file.txt s3://my-bucket/ uploads one file. aws s3 sync ./site s3://my-bucket/ uploads a folder.
| Command | What it does |
|---|---|
| aws s3 mb / aws s3 rb | Make / remove a bucket (rb --force also deletes objects –… |
| aws s3 cp | Copy one file to/from S3 (--recursive for folders) |
| aws s3 sync | Copy only new/changed files; --delete removes extra files… |
| aws s3 ls | List buckets or objects |
| aws s3 mv / aws s3 rm | Move / delete objects |
Learn more in the lesson: 14.2 Creating a Bucket and Uploading Objects