Quickstart - AWS CLI
Use the AWS CLI to upload, list and download objects in a Fil One bucket. You need a Fil One account and an API key. To create a key, open API Keys in the console, click Create new key, and pick the same region as your bucket. The secret is shown once.
1. Install the AWS CLI
Use AWS CLI v2, version 2.13 or later, so the CLI reads endpoint_url from your profile:
brew install awscli
# or follow the official installer:
# https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html
2. Configure credentials
Set up a named profile, so you don't overwrite your default AWS credentials and don't have to pass --endpoint-url on every command:
# ~/.aws/config
[profile filone]
endpoint_url = https://s3.eu-west-1.filonecontent.com
region = eu-west-1
s3 =
addressing_style = path
The addressing_style = path line is required — Fil One only supports path-style URLs, and the CLI otherwise defaults to virtual-hosted style, which fails.
The example above uses eu-west-1, the default region. If your bucket is in us-east-1, use https://s3.us-east-1.filonecontent.com and region = us-east-1 instead. The endpoint and the region must both match the bucket you are working with, and your access key has to belong to that region too.
If you use both regions, set up a profile per region ([profile filone-eu], [profile filone-us]) and pick with --profile.
# ~/.aws/credentials
[filone]
aws_access_key_id = YOUR_ACCESS_KEY
aws_secret_access_key = YOUR_SECRET_KEY
3. Create a bucket
Whether CreateBucket works through the S3 API depends on the region. It is not available in eu-west-1, the default region. There, create the bucket in the Fil One console: click New bucket, enter my-bucket (or your own name), and click Create bucket.
In us-east-1 you can create a bucket from the CLI, using a key that has the CreateBucket permission. This requires a us-east-1 profile — define one the same way as the filone profile above but with the us-east-1 endpoint and region (shown here as filone-us):
aws s3 mb s3://my-bucket --profile filone-us
Versioning and Object Lock can only be turned on when you create the bucket in the console. See Buckets.
The steps below use the filone profile (eu-west-1). If your bucket is in us-east-1, use --profile filone-us instead: the profile, the key and the bucket must all be in the same region.
4. Upload a file
echo "hello" > my-file.txt
aws s3 cp my-file.txt s3://my-bucket/ --profile filone
5. List objects
aws s3 ls s3://my-bucket/ --profile filone
6. Download the file
aws s3 cp s3://my-bucket/my-file.txt ./downloaded.txt --profile filone