scofield преди 3 години
родител
ревизия
046b718372
променени са 1 файла, в които са добавени 12 реда и са изтрити 0 реда
  1. 12 0
      deploy-tmp.yaml

+ 12 - 0
deploy-tmp.yaml

@@ -18,6 +18,18 @@ spec:
         app: $DRONE_REPO_NAME
     spec:
       terminationGracePeriodSeconds: 180
+      affinity:
+        podAntiAffinity:
+          preferredDuringSchedulingIgnoredDuringExecution:
+          - weight: 100
+            podAffinityTerm:
+              labelSelector:
+                matchExpressions:
+                - key: app
+                  operator: In
+                  values:
+                  - dashouye
+              topologyKey: kubernetes.io/hostname
       initContainers:
         - name: init
           image: $JNLP_REPO/dev/busybox