Titel:
Hi fellow rclone-users,
I am trying to use the Docker Volume Plugin with a timetable.
I would like to set the following: 08:00,400k:off 23:00,off
This should limit the upload from 08:00 to 23:00 and leave it unlimited the rest of the day and in the morning.
To do this i first disabled the rclone plugin:
docker plugin disable rclone
Then i edited my compose file, adding the bwlimit-line:
vol_rc_crypt_Landing:
driver: rclone
driver_opts:
remote: 'gcrypt:<deleted>'
allow_other: 'true'
allow_non_empty: 'true'
vfs_cache_mode: full
poll_interval: 0
bwlimit: "08:00,400k:off 23:00,off"
This gave me the following error:
ERROR: create compose_stash_vol_rc_crypt_Landing: VolumeDriver.Create: unsupported backend option "bwlimit"
Then I tried various variations of the following args, all with the same error:
The command consists of 3 stages. First the set args, then a read args. The last step is the plugin enable. I included the output from the read args (As the list of parameters) and the plugin enable (as "Output:").
No special quotes
docker plugin set rclone args="--allow-other --buffer-size=50G --drive-impersonate=xxx@some.domain --bwlimit=08:00,400k:off 23:00,off"; docker plugin inspect rclone | jq '.[0].Settings.Args'
docker plugin enable rclone
"--allow-other",
"--buffer-size=50G",
"--drive-impersonate=xxx@some.domain",
"--bwlimit=08:00,400k:off",
"23:00,off"
Output: Error response from daemon: dial unix /run/docker/plugins/92ca36642e202fea0eb143c5db96e2f1d43914325fc25363b909b27503aa9ac8/rclone.sock: connect: no such file or directory
Single quotes around --bwlimit Parameter and values
docker plugin set rclone args="--allow-other --buffer-size=50G --drive-impersonate=xxx@some.domain '--bwlimit=08:00,400k:off 23:00,off'"; docker plugin inspect rclone | jq '.[0].Settings.Args'
docker plugin enable rclone
"--allow-other",
"--buffer-size=50G",
"--drive-impersonate=xxx@some.domain",
"'--bwlimit=08:00,400k:off",
"23:00,off'"
Output: Error response from daemon: dial unix /run/docker/plugins/92ca36642e202fea0eb143c5db96e2f1d43914325fc25363b909b27503aa9ac8/rclone.sock: connect: no such file or directory
Single quotes around values only
docker plugin set rclone args="--allow-other --buffer-size=50G --drive-impersonate=xxx@some.domain --bwlimit='08:00,400k:off 23:00,off'"; docker plugin inspect rclone | jq '.[0].Settings.Args'
docker plugin enable rclone
"--allow-other",
"--buffer-size=50G",
"--drive-impersonate=xxx@some.domain",
"--bwlimit='08:00,400k:off",
"23:00,off'"
Output: Error response from daemon: dial unix /run/docker/plugins/92ca36642e202fea0eb143c5db96e2f1d43914325fc25363b909b27503aa9ac8/rclone.sock: connect: no such file or directory
Single quotes around all args, double quotes around values
docker plugin set rclone args='--allow-other --buffer-size=50G --drive-impersonate=xxx@some.domain --bwlimit="08:00,400k:off 23:00,off"'; docker plugin inspect rclone | jq '.[0].Settings.Args'
docker plugin enable rclone
"--allow-other",
"--buffer-size=50G",
"--drive-impersonate=xxx@some.domain",
"--bwlimit=\"08:00,400k:off",
"23:00,off\""
Output: Error response from daemon: dial unix /run/docker/plugins/92ca36642e202fea0eb143c5db96e2f1d43914325fc25363b909b27503aa9ac8/rclone.sock: connect: no such file or directory
Escaped double quotes around --bwlimit and value
docker plugin set rclone args="--allow-other --buffer-size=50G --drive-impersonate=xxx@some.domain \"--bwlimit=08:00,400k:off 23:00,off\""; docker plugin inspect rclone | jq '.[0].Settings.Args'
docker plugin enable rclone
"--allow-other",
"--buffer-size=50G",
"--drive-impersonate=xxx@some.domain",
"\"--bwlimit=08:00,400k:off",
"23:00,off\""
Output: Error response from daemon: dial unix /run/docker/plugins/92ca36642e202fea0eb143c5db96e2f1d43914325fc25363b909b27503aa9ac8/rclone.sock: connect: no such file or directory
Just an escape-Slash
docker plugin set rclone args="--allow-other --buffer-size=50G --drive-impersonate=xxx@some.domain --bwlimit=08:00,400k:off\ 23:00,off"; docker plugin inspect rclone | jq '.[0].Settings.Args'
docker plugin enable rclone
"--allow-other",
"--buffer-size=50G",
"--drive-impersonate=xxx@some.domain",
"--bwlimit=08:00,400k:off\\",
"23:00,off"
Output: Error response from daemon: dial unix /run/docker/plugins/92ca36642e202fea0eb143c5db96e2f1d43914325fc25363b909b27503aa9ac8/rclone.sock: connect: no such file or directory
Two escape-Slashes
docker plugin set rclone args="--allow-other --buffer-size=50G --drive-impersonate=xxx@some.domain --bwlimit=08:00,400k:off\\ 23:00,off"; docker plugin inspect rclone | jq '.[0].Settings.Args'
docker plugin enable rclone
"--allow-other",
"--buffer-size=50G",
"--drive-impersonate=xxx@some.domain",
"--bwlimit=08:00,400k:off\\",
"23:00,off"
Output: Error response from daemon: dial unix /run/docker/plugins/92ca36642e202fea0eb143c5db96e2f1d43914325fc25363b909b27503aa9ac8/rclone.sock: connect: no such file or directory
Just to make sure i also tried the simple bwlimit-format and it worked as expected:
docker plugin set rclone args="--allow-other --buffer-size=50G --drive-impersonate=xxx@some.domain --bwlimit=400k:off"; docker plugin inspect rclone | jq '.[0].Settings.Args'
docker plugin enable rclone
Output: <Everything is fine>
And now for the usual info:
I am trying to limit the upload to gSuite.
Sadly i am unable to get logs when the plugin is disabled. I tried these commands to access the logs:
myID="$(docker plugin inspect -f {{.Id}} rclone)"
cd /run/docker/plugins/$myID
cat < init-stdout
# or
cat < init-stderr
My /var/lib/docker-plugins/rclone/config/rclone.conf looks like this (with some more entries for SFTP or other cloud drives):
[gsuite]
type = drive
scope = drive
service_account_file = /data/config/<deleted>.json
client_id = <deleted>
client_secret = <deleted>
[gcrypt]
type = crypt
remote = gsuite:<deleted>
filename_encryption = <deleted>
directory_name_encryption = <deleted>
password = <deleted>
password2 = <deleted>
I am using the latest tag.