AWS




S3 CLI Commands

aws s3 ls: It will show all s3 buckets.

AWS S3 CLI

aws s3 mb s3://Bucket-Name: It will create a bucket with the provided name.

AWS S3 CLI

aws s3 ls s3://Bucket-Name: It will show all objects of the S3 bucket.

AWS S3 CLI

aws s3 ls s3://Bucket-Name --recursive: It will show all objects of the S3 bucket including which is present inside folders.

AWS S3 CLI

aws s3 cp s3://Source-Bucket-Name s3://Destination-Bucket-Name --recursive: It will copy all data from source bucket to destination bucket.

AWS S3 CLI

aws s3 sync . s3://Bucket-Name: It will sync the current working directory to provided bucket name. Here 1.jpg file is not available to S3 bucket so it will upload to S3 bucket.

AWS S3 CLI

aws s3 rm s3://Bucket-Name --recursive: It will delete all objects of the S3 bucket.

AWS S3 CLI

aws s3 mv . s3://Bucket-Name --recursive: It will move all data from the current working directory to provided S3 bucket.

AWS S3 CLI

aws s3 mv s3://Bucket-Name . --recursive: It will move all data from provided S3 bucket to the current working directory.

AWS S3 CLI

aws s3 rb s3://Bucket-Name: It will delete provided S3 bucket.

AWS S3 CLI

aws s3 sync s3://Bucket-Name . : It will sync provided S3 bucket to the current working directory.

AWS S3 CLI