Use Rclone With Docker

Requirement:

FUSE has to be installed on the host machine:

Installation:

  1. Store a local version of an already existing rclone config (in my case it was the default rclone config directory)
    • ~/.config/rclone
  2. Create a new docker compose file based on the following template:
services:
  rclone_****:
    image: rclone/rclone
    container_name: rclone_*****
    privileged: true # Required for FUSE
    user: 1000:1000
    cap_add: # Required for FUSE
      - SYS_ADMIN
    security_opt: # Required for FUSE
      - apparmor:unconfined
    devices:
      - /dev/fuse:/dev/fuse
    command: "mount remoteInConfig: /mnt/hostDirectory --allow-non-empty --allow-other" ## --allow-other => gives access for OMV
    environment:
      - PHP_TZ=Europe/Oslo
    volumes:
         #Path to rclone config
      - ~/.config/rclone:/config/rclone
            #Volume for the remote directory
            - /mnt/hostDirectoryLocal:/mnt/hostDirectoryDocker:shared
            #Needed for FUSE to work in the container
      - /etc/passwd:/etc/passwd:ro
      - /etc/group:/etc/group:ro

This page was last edited on 2025-12-01 17:55

Powered by Wiki|Docs

This page was last edited on 2025-12-01 17:55

clippy
?

Powered by Wiki|Docs