# The Endpoint Picker. loxilb-igw talks to port 9002 (ext_proc gRPC) directly; no Envoy sidecar is needed.
apiVersion: apps/v1
kind: Deployment
metadata:
  name: pd-disaggregation-epp
  namespace: llm-d-pd-disaggregation
  labels:
    app.kubernetes.io/name: pd-disaggregation-epp
spec:
  replicas: 1
  strategy:
    type: Recreate
  selector:
    matchLabels:
      app.kubernetes.io/name: pd-disaggregation-epp
  template:
    metadata:
      labels:
        app.kubernetes.io/name: pd-disaggregation-epp
    spec:
      serviceAccountName: pd-disaggregation-epp
      containers:
      - name: epp
        image: ghcr.io/llm-d/llm-d-router-endpoint-picker:main
        imagePullPolicy: Always
        args:
        - --pool-name
        - pd-disaggregation
        - --pool-namespace
        - llm-d-pd-disaggregation
        - --pool-group
        - inference.networking.k8s.io
        - --zap-encoder
        - json
        - --config-file
        - /config/epp-config.yaml
        - --grpc-health-port
        - "9003"
        - --v=2                                     # 4 logs one "Request handled" line per request
        - --tracing=false
        env:
        - name: NAMESPACE
          valueFrom:
            fieldRef:
              fieldPath: metadata.namespace
        - name: POD_NAME
          valueFrom:
            fieldRef:
              fieldPath: metadata.name
        ports:
        - name: grpc
          containerPort: 9002
          protocol: TCP
        - name: grpc-health
          containerPort: 9003
          protocol: TCP
        - name: metrics
          containerPort: 9090
          protocol: TCP
        livenessProbe:
          grpc:
            port: 9003
            service: liveness
          initialDelaySeconds: 5
          periodSeconds: 10
        readinessProbe:
          grpc:
            port: 9003
            service: readiness
          initialDelaySeconds: 5
          periodSeconds: 10
        volumeMounts:
        - name: plugins-config-volume
          mountPath: /config
      volumes:
      - name: plugins-config-volume
        configMap:
          name: pd-disaggregation-epp
