rclone sync when backup-event

This commit is contained in:
Leon van Kammen 2026-09-02 13:43:59 +02:00
parent 586cea2cc6
commit 733ddd7cfc

View file

@ -12,8 +12,9 @@ app.on('set', function(k,v)
end)
app.on('autobackup', function() -- triggered by src/plugin/webhook.lua
if util.cmdExist('rclone') then
print("running RCLONE cmd sync!")
if util.cmdExist('rclone') and #app.opts.plugin_clouddrive_syncpath > 0 then
print("running RCLONE sync")
os.execute("rclone sync " .. app.opts.plugin_diskscan_dir .. "/ " .. app.opts.plugin_clouddrive_syncpath )
end
end)