Skip to main content

Rclone

Intro

Rclone is a command-line tool for managing files on cloud storage, offering an alternative to web storage interfaces. It supports over 40 cloud storage products, including S3 object stores and various file storage services, and provides cloud equivalents to popular Unix commands. It offers shell pipeline support, --dry-run protection, and can be used at the command line, in scripts, or via its API.

Read along to learn how to configure Rclone to perform a backup on your Cubbit Account.

tip

This guide refers to Rclone v1.72.0.

Please note that the Rclone options listed below may vary depending on the version you use.

Prerequisites

First, you need to get your access key and secret key, from the Cubbit Web Console or https://console.[your-tenant].cubbit.eu. Please follow these instructions on how to get started with a Cubbit account and generate these keys.

Installation

There are multiple ways of installing Rclone on your machine; please follow the instructions on the official website.

Configuration

This approach is also reported in the official rclone documentation support for Cubbit.

caution

The following instruction should work on any Unix machine capable of running Rclone.

For any doubts, you can check the official configuration guide.

Once installed, you should be able to run the command to add a configuration.

rclone config

It will start an interactive session to guide you through the configuration process of a remote.

Each prompt should be answered as shown below:

name> cubbit (or any name you like)
Storage> s3
provider> Cubbit
env_auth> false
access_key_id> YOUR_ACCESS_KEY
secret_access_key> YOUR_SECRET_KEY
region> eu-west-1 (or leave empty)
endpoint> s3.cubbit.eu (or s3.[your-tenant].cubbit.eu for custom tenants)
acl>

The resulting configuration file should look like:

[cubbit]
type = s3
provider = Cubbit
access_key_id = ACCESS_KEY
secret_access_key = SECRET_KEY
region = eu-west-1
endpoint = s3.cubbit.eu
warning

Remember to replace the endpoint s3.cubbit.eu with s3.[your-tenant].cubbit.eu if you have a custom tenant.

How to

The following operation assumes you have already created a bucket called bucket-name on your account.

List files

rclone ls cubbit:bucket-name

Sync folder

rclone sync -P ./backup-folder cubbit:bucket-name

Delete a bucket either with enabled or disabled S3 Versioning and its contents

rclone purge -P -vvv cubbit:bucket-name

For more information on Rclone, please refer to the official documentation.