kubernetes/test/integration/scheduler_perf/config/event_handling/podadd-pod-podtopologyspread.yaml

apiVersion: v1
kind: Pod
metadata:
  generateName: pod-podtopologyspread-
  labels:
    type: unsched
    topology: blue
spec:
  affinity:
    podAntiAffinity:
      requiredDuringSchedulingIgnoredDuringExecution:
      - labelSelector:
          matchLabels:
            color: green
        topologyKey: kubernetes.io/hostname
        namespaces: ["podtopologyspread"]
  topologySpreadConstraints:
    - maxSkew: 1
      topologyKey: kubernetes.io/hostname
      whenUnsatisfiable: DoNotSchedule
      labelSelector:
        matchLabels:
          topology: blue
  containers:
  - image: registry.k8s.io/pause:3.10
    name: pause