Possible to pass filters to rcd as part of copy/move/sync

What is the problem you are having with rclone?

I'm looking to simulate a few rclone commands using rc/rcd rather than invoking them directly via.

What is your rclone version (output from rclone version)

rclone v1.51.0-151-gfc663d98-beta

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

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

Linux 64

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

multiple

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

rclone rcd --rc-user=xxx --rc-pass=xxx

rclone rc --rc-user=xxx --rc-pass=xxx sync/move srcFs=/data/cams dstFs=robgs:/cams/

The caveat is I have a few of those 'rc' commands to run with varying 'filters' to pass. So I want to be able to pass those filters at execution time rather than when I start the 'rcd'. I realize I can add those filters to the 'rcd' but then i'd need to run multiple 'rcd' daemons to take care of the multiple filters.

Is this possible?

An example of a filter is like this:

--include="/{x,y,z}/20{1,2}[0-9][0-1][0-9][0-3][0-9]/*.{JPG,AVI,MP4,MKV}"

A log from the command with the -vv flag (eg output from rclone -vv copy /tmp remote:tmp)

n/a

You can set that using options/set.
E.g.
rclone rc options/set --json '{"filter": {"IncludeRule": ["/{x,y,z}/20{1,2}[0-9][0-1][0-9][0-3][0-9]/*.{JPG,AVI,MP4,MKV}"]}}'

It might work for different filters if the jobs are run sequentially.

1 Like

Thanks. That's helpful and may work for some of my jobs but won't that make it persistent for any executions you fire off? If I have 3 different jobs that need 3 different types of filters I believe it would impact each other. I'd like to be able to execute this as part of the copy/sync/move rather than tie these to the rcd itself.

It will, yes.

The rclone config is global at the moment which is a little unfortunate so that means there isn't a way of specifying flags for a particular job yet.

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