Skip to content

Accessing the Arbutus object storage with AWS CLI

This page contains instructions on how to set up and access Arbutus object storage with the AWS Command Line Interface (CLI), one of the object storage clients available for this storage type.

AWS CLI for Arbutus Object Storage

The AWS CLI offers better support for large (>5GB) files and includes the useful sync command, distinguishing it from other object storage clients. However, please be aware that not all features have not been tested.

Installing AWS CLI

pip install awscli awscli-plugin-endpoint

Configuring AWS CLI

Generate an access key ID and secret key

openstack ec2 credentials create

Edit or create ~/.aws/credentials and add the credentials generated above

~/.aws/credentials
[default]
aws_access_key_id = <access_key>
aws_secret_access_key = <secret_key>

Edit ~/.aws/config and add the following configuration

~/.aws/config
[plugins]
endpoint = awscli_plugin_endpoint

[profile default]
s3 =
  endpoint_url = https://object-arbutus.alliancecan.ca
  signature_version = s3v4
s3api =
  endpoint_url = https://object-arbutus.alliancecan.ca

Using AWS CLI

export AWS_PROFILE=default
aws s3 ls <container-name>
aws s3 sync local_directory s3://container-name/prefix

More examples of using the AWS CLI can be found on this external site.