Download an entire AWS S3 bucket or file
Writing by shivdev on Tuesday, 24 of March , 2015 at 5:32 am
AWS CLI to the rescue. It’s really quick and easy. Install AWS CLI, add your keys to the credentials and then fire away.
- AWS CLI Reference (pip install awscli) of course you have Python
- Configuring AWS CLI (~/.aws/credentials) use profiles for qa, dev etc.
- AWS ls command (aws s3 ls s3://mybucket)
- AWS cp command (aws s3 cp s3://mybucket/test.txt .) create all your aliases
Here are some of mine
alias s3ls=’function _s3ls(){ aws s3 ls s3://”$@” ; }; _s3ls’
alias s3get=’function _s3get(){ aws s3 cp s3://”$@” . ; }; _s3get’
alias s3getdir=’function _s3getdir(){ aws s3 cp s3://”$@” . –recursive ; }; _s3getdir’
Leave a comment
Category: Tips and Tricks
- Add this post to
- Del.icio.us -
- Digg -
- -
- Tweet -
-
-
No comments yet.
You must be logged in to post a comment.