---
apiVersion: apps/v1
kind: Deployment
metadata:
  namespace: prow
  name: sinker
  labels:
    app: sinker
spec:
  selector:
    matchLabels:
      app: sinker
  replicas: 1
  template:
    metadata:
      labels:
        app: sinker
    spec:
      serviceAccountName: "sinker"
      containers:
        - name: sinker
          image: gcr.io/k8s-prow/sinker:v20211203-281e29a97a
          args:
            - --config-path=/etc/config/config.yaml
            - --job-config-path=/etc/job-config
            - --dry-run=false
          env:
            # Use KUBECONFIG envvar rather than --kubeconfig flag in order to provide multiple configs to merge.
            - name: KUBECONFIG
              value: "/etc/kubeconfig/config"
          volumeMounts:
            - name: config
              mountPath: /etc/config
              readOnly: true
            - name: job-config
              mountPath: /etc/job-config
              readOnly: true
            - name: kubeconfig
              mountPath: /etc/kubeconfig
              readOnly: true
      volumes:
        - name: config
          configMap:
            name: config
        - name: job-config
          configMap:
            name: job-config
        - name: kubeconfig
          secret:
            defaultMode: 0644
            secretName: kubeconfig
