Skip to main content
Zerobyte integrates with rclone to provide support for 40+ cloud storage providers including Google Drive, Dropbox, OneDrive, Box, pCloud, Mega, and many more. This gives you the flexibility to store your backups on virtually any cloud storage service.

Overview

Rclone can be used in Zerobyte for two purposes:
  1. Repository Backend - Store encrypted backups on cloud storage (Dropbox, Google Drive, OneDrive, etc.)
  2. Volume Backend - Mount cloud storage as a source to back up from (requires additional configuration)
Before using rclone with Zerobyte, you must configure rclone on your Docker host system and mount the configuration into the container.

Prerequisites

  • Docker with Docker Compose
  • Linux host (required for rclone volume mounting)
  • rclone installed on the Docker host

Installation

1. Install rclone on Host

If rclone is not already installed on your Docker host:
Verify installation:

2. Configure Cloud Storage Remote

Run rclone’s interactive configuration wizard:
Follow the prompts to set up your cloud storage provider. For OAuth providers like Google Drive, Dropbox, and OneDrive, rclone will guide you through the authentication flow in your browser.
Give your remote a descriptive name (e.g., gdrive, dropbox, onedrive) as this will appear in Zerobyte’s repository creation interface.

3. Verify Remote Configuration

Confirm your remote is properly configured:
If these commands fail on your host, fix your rclone configuration before proceeding. Most rclone issues in Zerobyte are due to misconfigured remotes on the host.

4. Mount Rclone Config into Container

Update your docker-compose.yml to mount the rclone configuration directory:
docker-compose.yml
The rclone config is mounted read-only (:ro) for security. The default path is ~/.config/rclone on Linux. For root users, use /root/.config/rclone.

5. Restart Zerobyte

After updating the configuration:

Using Rclone Repositories

Once configured, rclone remotes will appear in the repository creation dropdown:
  1. Navigate to Repositories in the Zerobyte UI
  2. Click Create Repository
  3. Select rclone as the backend type
  4. Choose your configured remote from the dropdown
  5. Specify the path on the remote where backups should be stored
  6. Click Create
Zerobyte will initialize a new Restic repository on your cloud storage.

Supported Cloud Providers

Rclone supports 40+ storage providers. Popular options include:
  • Dropbox - Cloud storage with 2GB free tier
  • Google Drive - 15GB free tier
  • OneDrive - Microsoft’s cloud storage
  • Box - Enterprise cloud storage
  • pCloud - European cloud storage
  • Mega - End-to-end encrypted storage
  • Amazon Drive - Amazon’s cloud storage
  • Backblaze B2 - Low-cost cloud storage
  • SFTP - Any SSH/SFTP server
  • WebDAV - Generic WebDAV servers
  • FTP - Traditional FTP servers
For a complete list, see the official rclone documentation.

Rclone Volume Mounting

You can also use rclone to mount cloud storage as a volume source to back up from. This requires additional Docker privileges.

Requirements for Volume Mounting

  • Linux Docker host (not supported on Windows/macOS)
  • /dev/fuse device access
  • SYS_ADMIN capability
  • FUSE support on host system

Configuration for Volume Mounting

Update your docker-compose.yml:
docker-compose.yml
Granting SYS_ADMIN allows the container to perform mount operations. Only use this if you need rclone volume mounting.

Testing Rclone Mount on Host

Before using rclone volumes in Zerobyte, verify mounting works on your host:
If this works, you can create rclone volumes in Zerobyte.

Authentication Issues

OAuth Token Expiration

OAuth tokens for providers like Google Drive and Dropbox can expire. If you see “Failed to Create File System” errors:

SFTP Remote with SSH Keys

When using SFTP remotes with SSH key authentication, the key file must be accessible inside the container. Option 1: Mount SSH keys (Recommended)
docker-compose.yml
Option 2: Embed key in rclone config Convert your SSH key to single-line format:
Update ~/.config/rclone/rclone.conf:
rclone.conf
Option 3: Use ssh-agent Configure the remote to use ssh-agent:
rclone.conf
Mount the SSH agent socket:
docker-compose.yml

Non-Root Containers

For non-root container environments (e.g., TrueNAS), set the correct config path:
docker-compose.yml

Example: Complete Setup

See the rclone-config-mount example in the repository for a complete working configuration.
docker-compose.yml
.env

Verification

To verify rclone is properly configured inside the container:

Best Practices

  1. Test on host first - Always verify rclone works on your Docker host before troubleshooting container issues
  2. Use descriptive names - Name remotes clearly (e.g., personal-gdrive, work-dropbox)
  3. Read-only mount - Keep the rclone config mounted as :ro for security
  4. Backup your config - Store a copy of ~/.config/rclone/rclone.conf securely
  5. Monitor tokens - OAuth tokens can expire; re-authenticate periodically
  6. Use separate folders - Create dedicated folders on cloud storage for Zerobyte backups