How to designate local entry-points in rclone.conf

What is the problem you are having with rclone?

I want to create a strict set of local entry points in the rclone.conf. I know that I can do something like this:

rclone lsjson /tmp/local/path

However, I am writing tools for a framework that needs to:

  • be able to query the entry-points before it does anything.
  • run unit-tests from a completely controlled config / env

So I was hoping to add a local entry-point, like this:

rclone --config /my/custom/rclone/rclone.conf lsjson source:



is designated in the custom config.

See config below.

What is your rclone version (output from rclone version)

rclone v1.54.0

  • os/arch: linux/amd64
  • go version: go1.15.7

Which OS you are using and how many bits (eg Windows 7, 64 bit)

Linux 64bit

Which cloud storage system are you using? (eg Google Drive)

Owncloud & local FS

The command you were trying to run (eg rclone copy /tmp remote:tmp)

rclone --config /tmp/pytest_runs/geraldine_johnson/.config/rclone/rclone.conf lsjson source:

This is currently returning the contents of the current directory, not the "source:" defined in the rclone.conf. ( see last line of log below )

The rclone config contents with secrets removed.

type = local
path = /tmp/pytest_runs/geraldine_johnson/source

type = local
path = /tmp/pytest_runs/geraldine_johnson/target

A log from the command with the -vv flag

(venv) 11:55:42 02.07.2021 speters@:/home/speters/dev/arrival/hive/content/libs/hive_rclone_pkg/hive_rclone/
$ rclone --config /tmp/pytest_runs/geraldine_johnson/.config/rclone/rclone.conf -vv lsjson source:
<7>DEBUG : rclone: Version "v1.54.0" starting with parameters ["rclone" "--config" "/tmp/pytest_runs/geraldine_johnson/.config/rclone/rclone.conf" "-vv" "lsjson" "source:"]
<7>DEBUG : rclone: systemd logging support activated
<7>DEBUG : Using config file from "/tmp/pytest_runs/geraldine_johnson/.config/rclone/rclone.conf"
<7>DEBUG : Creating backend with remote "source:"
<7>DEBUG : fs cache: renaming cache item "source:" to be canonical "source:/home/speters/dev/arrival/hive/content/libs/hive_rclone_pkg/hive_rclone"

You want an alias remote:

type = alias
remote = /tmp/pytest_runs/geraldine_johnson/source

type = alias
remote = /tmp/pytest_runs/geraldine_johnson/target

@Animosity022 THANK YOU!

This is perfect. Do you happen to know where / if this is documented?

Thanks again for the swift reply :smiley:


This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.