pvesh get nodes/<NODE>/replication/<JOB-ID>/status
last_sync
timestamp. Then run schedule-now
and in a loop with a bit of pause do
pvesh get nodes/<NODE>/replication/<JOB-ID>/status
last_sync
value. When it changes, you know the job has completed.fail_count
and conditionally abort the loop.