apiVersion: apps/v1
kind: Deployment
metadata:
  # TODO: Replace with your custom name
  name: {Replace with your custom placeholder deployment name}
spec:
  # TODO: Replace with your custom node nums
  replicas: 1
  selector:
    matchLabels:
      app: low-priority-placeholder
  template:
    metadata:
      labels:
        app: low-priority-placeholder
    spec:
      terminationGracePeriodSeconds: 1
      priorityClassName: automq-low-priority
      affinity:
        podAntiAffinity:
          requiredDuringSchedulingIgnoredDuringExecution:
            - labelSelector:
                matchExpressions:
                  - key: app.kubernetes.io/component
                    operator: In
                    values:
                      - controller
                      - broker
              topologyKey: kubernetes.io/hostname
            - labelSelector:
                matchLabels:
                  app: low-priority-placeholder
              topologyKey: topology.kubernetes.io/zone
        nodeAffinity:
          requiredDuringSchedulingIgnoredDuringExecution:
            nodeSelectorTerms:
              - matchExpressions:
                - key: ccs.bj.baidubce.com/node-pool
                  operator: In
                  values:
                  # TODO: Replace with your custom Node Pool Name
                  - "Replace with your custom Node Pool Name"
                - key: node.kubernetes.io/instance-type
                  operator: In
                  values:
                  # TODO: Replace with your custom Node Pool VM Size
                  - "Replace with your custom Node Pool VM Size"
      tolerations:
        - key: "dedicated"
          operator: "Equal"
          value: "automq"
          effect: "NoSchedule"
      containers:
        - name: placeholder
          image: busybox:1.35
          imagePullPolicy: Always
          command: ["sh", "-c", "sleep infinity"]
          resources:
            limits:
              cpu: 2000m
              memory: 16Gi
            requests:
              cpu: 1000m
              memory: 12Gi               
