Skip to content

Latest commit

 

History

History
34 lines (25 loc) · 1.39 KB

rclone.org

File metadata and controls

34 lines (25 loc) · 1.39 KB

Rclone

Rclone is a command line program to manage files on cloud storage. It supports lots of cloud providers and encryption. It’s often used by SysOps teams.

Use cases

There is a lot you can do with rclone so this is just a list of things that might be useful to you.

Encrypted backup

Create remote

The first thing you want to do is set up a remote (storage), run the following:

$ rclone config

It will present a wizard, press n to create a new one, then follow the steps to set up your storage.

Encrypted remote

To be able to use encryption we need to add another remote, follow the steps again but choose crypt as storage. I recommend using the same name as for the first remote but appending -secret.

It will ask you to enter a remote to encrypt/decrypt. Enter the name of the storage we created first. Then follow the wizard to completion.

The backup

You can run the following to run a backup right now:

$ rclone sync /local/path my-remote-secret:

If you want to run the backup regulary you can create a cron job. The flock command makes sure only one backup can run at the time.

* 2 * * * flock --no-fork --exclusive --nonblock /var/lock/rclone-media.lock -c 'rclone sync /local/path my-remote-secret: > /var/log/rclone-media.log'