How to setup periodic sync in macOS Monterey

What is the problem you are having with rclone?

I'm trying to setup a periodic sync schedule in macOS Monterey every 30 minutes (unless another sync is already running) that activates automatically on login. The problems I'm having:

  • I've tested the attached script below which works in zsh terminal. I tried creating an automator application running the same exact script but when I run the script via the created app, automator says "rclone command not found". Why is that?
  • How to run the script on login?
  • How to run the script periodically as long as another instance is NOT running?
  • Optional: How to handle sleep gracefully?

What is your rclone version (output from rclone version)

rclone version

rclone v1.57.0
- os/version: darwin 12.0.1 (64 bit)
- os/kernel: 21.1.0 (arm64)
- os/type: darwin
- os/arch: arm64
- go/version: go1.17.2
- go/linking: dynamic
- go/tags: none

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

macOS Monterey 12.01 (64 bit)

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

Google Drive

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

rclone sync "/Users/<user name>/google-drive-personal" "gcrypt:/" --exclude "node_modules/**" --log-file "/Users/<user name>/Rclone Latest Logs/rclone-sync-$(date +%FT%T%Z).log" --fast-list --verbose --progress

hello,

tho i do not use macos, on the many platforms i use, i always hardcode the full path of rclone.
for example, /usr/bin/rclone

1 Like

Thanks for the response. Trying that gives me a "permission denied" error

is that it, do you have more detail?
perhaps do a internet search about automator

for the rclone command i would test using a simple command
/usr/bin/rclone version --log-level=DEBUG --log-file=/path/to/rclone.log

I think rclone is installed in /usr/local/bin/rclone on macOS (not a mac user!)

If you type which rclone in the shell then it will tell you where for definite.

hi, you are correct.

just checked the install.sh, the location of rclone is
/usr/local/bin/rclone

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