fix(volsync/template): affinity to prevent scheduling

This commit is contained in:
JJGadgets
2025-06-10 14:52:34 +08:00
parent 3abe96bc75
commit 3bbf4f1266

View File

@@ -94,3 +94,9 @@ spec:
matchExpressions:
- key: kubernetes.io/metadata.name
operator: Exists
podAffinity: # create conflicting affinity so this won't schedule when scheduled is running
requiredDuringSchedulingIgnoredDuringExecution:
- topologyKey: kubernetes.io/hostname
labelSelector:
matchLabels:
batch.kubernetes.io/job-name: "volsync-src-${PVC}-r2-restic"