AWS CLI Endpoint

This guide is so you can set Storj as the default endpoint so you can avoid having to repeatedly use the --endpoint option.

These features can be achieved by installing the awscli-plugin-endpoint plugin.

Install plugin

  1. Install the AWS CLI v2.x

  2. Install awscli-plugin-endpoint plugin:

    pip3 install --no-deps awscli-plugin-endpoint
    pip3 install --no-deps awscli-plugin-endpoint
  3. Configure the path in your ~/.aws/config file (replace the site-packages-path to your path from a previous step):

    aws configure set plugins.cli_legacy_plugin_path site-packages-path
    aws configure set plugins.cli_legacy_plugin_path site-packages-path
  4. Configure plugin in your ~/.aws/config file:

    aws configure set plugins.endpoint awscli_plugin_endpoint
    aws configure set plugins.endpoint awscli_plugin_endpoint
aws configure set default.s3.endpoint_url https://gateway.storjshare.io
aws configure set default.s3.endpoint_url https://gateway.storjshare.io

The resulting file would look like:

[default]
aws_access_key_id = access_key # replace me
aws_secret_access_key = secret_key # replace me
s3 =
endpoint_url = https://gateway.storjshare.io
[default]
aws_access_key_id = access_key # replace me
aws_secret_access_key = secret_key # replace me
s3 =
endpoint_url = https://gateway.storjshare.io

You can now use the AWS CLI without specifying an endpoint:

aws s3 ls
aws s3 ls

s3api

To configure s3api endpoint you can use this command:

aws configure set default.s3api.endpoint_url https://gateway.storjshare.io
aws configure set default.s3api.endpoint_url https://gateway.storjshare.io

Set a Storj profile

You can also use a different profile for Storj:

aws configure set profile.storj.s3.endpoint_url https://gateway.storjshare.io
aws configure set profile.storj.s3.multipart_threshold 1TB
aws configure set profile.storj.s3.endpoint_url https://gateway.storjshare.io
aws configure set profile.storj.s3.multipart_threshold 1TB

To use AWS CLI with a separate profile storj:

aws s3 --profile storj ls
aws s3 --profile storj ls
Previous
Access