Skip to content

Rclone

Rclone is a CLI program for accessing S3 buckets.

Installation

On Ubuntu

apt install rclone

Configuration

Copy your keys from ICE Connect

Services -> S3 Storage -> Keys

Add the configuration file

~/.config/rclone/rclone.conf
[s3]
type = s3
provider = Ceph
env_auth = false
access_key_id = YOUR_ACCESS_KEY
secret_access_key = YOUR_SECRET_KEY
endpoint = s3.ice.ri.se
acl = private
bucket_acl = private
upload_cutoff = 1G

List objects

rclone ls s3:project-bucket/
120900442 go1.15.5.linux-amd64.tar.gz

Download

rclone copy s3:project-bucket/go1.15.5.linux-amd64.tar.gz ./
ls -al
total 118096
drwxrwxr-x  2 daniel daniel      4096 Oct 20 11:47 .
drwxrwxr-x 12 daniel daniel      4096 Oct 20 11:12 ..
-rw-rw-r--  1 daniel daniel 120900442 Oct  1 11:27 go1.15.5.linux-amd64.tar.gz

Upload

rclone copy testfile.txt s3:project-bucket/
rclone ls s3:project-bucket/
120900442 go1.15.5.linux-amd64.tar.gz
        5 testfile.txt

Sync bucket to folder

rclone sync s3:project-bucket/ localfolder/

Last update: 2023-04-10
Created: 2021-10-20