apiVersion: apps/v1
kind: Deployment
metadata:
  name: billing2-api
spec:
  replicas: 3
  template:
    spec:
      affinity:
        podAntiAffinity:
          requiredDuringSchedulingIgnoredDuringExecution:
          - labelSelector:
              matchLabels:
                app: billing2-api
            topologyKey: kubernetes.io/hostname
      topologySpreadConstraints:
      - maxSkew: 1
        topologyKey: topology.kubernetes.io/zone
        whenUnsatisfiable: ScheduleAnyway
        labelSelector:
          matchLabels:
            app: billing2-api
      containers:
      - name: billing2-api
        image: 380838443567.dkr.ecr.us-west-2.amazonaws.com/dbaas/prod/dbaas-billing2:20260907-2
        command: ["/usr/local/bin/server"]
        resources:
          requests:
            cpu: "1000m"
            memory: "1000Mi"
          limits:
            cpu: "1000m"
            memory: "1000Mi"
