Add new is-primary condition to autobackup timers
Avoids running these except on the primary coordinator at the time of firing, to avoid duplicate runs being passed to pvcworkerd.
This commit is contained in:
parent
b395f47852
commit
e35842675f
|
@ -5,4 +5,5 @@ Description=[Cron] PVC VM autobackup (forced-full)
|
||||||
Type=oneshot
|
Type=oneshot
|
||||||
IgnoreSIGPIPE=false
|
IgnoreSIGPIPE=false
|
||||||
KillMode=process
|
KillMode=process
|
||||||
|
ExecCondition=/usr/bin/pvc --quiet node is-primary
|
||||||
ExecStart=/usr/bin/pvc --quiet vm autobackup --cron --force-full {% if pvc_autobackup.reporting.enabled and pvc_autobackup.reporting.report_on.forced_full %}--email-report {{ pvc_autobackup.reporting.emails|join(',') }}{% endif %}
|
ExecStart=/usr/bin/pvc --quiet vm autobackup --cron --force-full {% if pvc_autobackup.reporting.enabled and pvc_autobackup.reporting.report_on.forced_full %}--email-report {{ pvc_autobackup.reporting.emails|join(',') }}{% endif %}
|
||||||
|
|
|
@ -5,4 +5,5 @@ Description=[Cron] PVC VM autobackup (normal)
|
||||||
Type=oneshot
|
Type=oneshot
|
||||||
IgnoreSIGPIPE=false
|
IgnoreSIGPIPE=false
|
||||||
KillMode=process
|
KillMode=process
|
||||||
|
ExecCondition=/usr/bin/pvc --quiet node is-primary
|
||||||
ExecStart=/usr/bin/pvc --quiet vm autobackup --cron {% if pvc_autobackup.reporting.enabled and pvc_autobackup.reporting.report_on.normal %}--email-report {{ pvc_autobackup.reporting.emails|join(',') }}{% endif %}
|
ExecStart=/usr/bin/pvc --quiet vm autobackup --cron {% if pvc_autobackup.reporting.enabled and pvc_autobackup.reporting.report_on.normal %}--email-report {{ pvc_autobackup.reporting.emails|join(',') }}{% endif %}
|
||||||
|
|
Loading…
Reference in New Issue