...
Some of the CLI libraries that can be used to access s3 buckets are described below:
...
Info |
---|
it works for public and private buckets after configuration |
1. Run rclone config
and follow the interactive configuration for a new remote
Then insert n and follow the instructions:
name
: s3
storage option
: 5
s3 provider
: 22
env_auth
: leave default
access_key_id
: your access key
secret_key_id
: your secret key
region
: leave default
endpoint
: s3 bucket endpint URL https://s3.waw3-1.cloudferro.com
location_constraint
: leave default
acl
: select the one that best fits your use case
Finalize it and save
2. Run the following command with your 'bucket_name':
Code Block |
---|
rclone ls s3://bucket_name/ |
s3cmd
Warning |
---|
It works only for private buckets |
1. Run s3cmd --
configure
and follow the interactive configuration for a new remote
2. Run the following command with your 'bucket_name'
Code Block |
---|
s3cmd ls s3://bucket_name/ |
awscli
Access private bucket
1. Run
and follow the interactive configuration for a new remote to setup the access_key and the secret_key to be used by the CLI.aws configure
2. Run the following command with your 'bucket_name' for a private bucket:
Code Block |
---|
aws s3 ls --endpoint-url s3_endpoint_url s3://bucket_name/ |
Access public bucket
Run the following command with your 'bucket_name' for a public bucket:
...
- → Rclone is a command-line program to manage files on cloud storage. Rclone mounts any local, cloud or virtual filesystem as a disk on Windows, macOS, linux and FreeBSD, and also serves these over SFTP, HTTP, WebDAV, FTP and DLNA. Rclone is mature, open-source software originally inspired by rsync and written in Go.
- s3cmd → S3cmd is afree command line tool and client for uploading, retrieving and managing data in cloud storage service providers that use the S3 protocol. It is best suited for power users who are familiar with command line programs. It is also ideal for batch scripts and automated backup to S3, triggered from cron, etc.
- awscli → command-line for s3 buckets.