# Source: tekton-pipeline/templates/tekton-pipelines-controller-deploy.yaml
apiVersion: apps/v1
kind: Deployment
metadata:
  labels:
    app.kubernetes.io/component: controller
    app.kubernetes.io/instance: default
    app.kubernetes.io/name: controller
    app.kubernetes.io/part-of: tekton-pipelines
    app.kubernetes.io/version: v0.21.0
    pipeline.tekton.dev/release: v0.21.0
    version: v0.21.0
    gitops.jenkins-x.io/pipeline: 'namespaces'
  name: tekton-pipelines-controller
  namespace: tekton-pipelines
  annotations:
    wave.pusher.com/update-on-config-change: 'true'
spec:
  replicas: 1
  selector:
    matchLabels:
      app.kubernetes.io/component: controller
      app.kubernetes.io/instance: default
      app.kubernetes.io/name: controller
      app.kubernetes.io/part-of: tekton-pipelines
  template:
    metadata:
      annotations:
        cluster-autoscaler.kubernetes.io/safe-to-evict: "false"
      labels:
        app: tekton-pipelines-controller
        app.kubernetes.io/component: controller
        app.kubernetes.io/instance: default
        app.kubernetes.io/name: controller
        app.kubernetes.io/part-of: tekton-pipelines
        app.kubernetes.io/version: v0.21.0
        pipeline.tekton.dev/release: v0.21.0
        version: v0.21.0
    spec:
      containers:
        - args:
            - -version
            - v0.21.0
            - -kubeconfig-writer-image
            - gcr.io/tekton-releases/github.com/tektoncd/pipeline/cmd/kubeconfigwriter:v0.21.0@sha256:1727868bd5a22dd8e45a4efca0a7f0b5b00cd1bbbe97068e60986ae221b828c3
            - -git-image
            - gcr.io/tekton-releases/github.com/tektoncd/pipeline/cmd/git-init:v0.21.0@sha256:db18a9c1607c8cbbcd72f61d0c4d795b9ff528669deacd5f8a1672e4ef198ffd
            - -entrypoint-image
            - gcr.io/tekton-releases/github.com/tektoncd/pipeline/cmd/entrypoint:v0.21.0@sha256:d5af7d58c2ad222548e7fcaf7d8e8172837df254b49cc636d1f9d0d8c499beb8
            - -nop-image
            - gcr.io/tekton-releases/github.com/tektoncd/pipeline/cmd/nop:v0.21.0@sha256:8172a046a040a6267888ab9755b48631bbcf92ea58534ae506bb80125ee94cc2
            - -imagedigest-exporter-image
            - gcr.io/tekton-releases/github.com/tektoncd/pipeline/cmd/imagedigestexporter:v0.21.0@sha256:265641edf8fbb19f844f7d2006d1b81927f43fd1b19f037709355938a1e3c78e
            - -pr-image
            - gcr.io/tekton-releases/github.com/tektoncd/pipeline/cmd/pullrequest-init:v0.21.0@sha256:6e2c398d27d5d9f6de3a41ed2d70d9c940e22a648a349c5cb5bbdbb76484c9fe
            - -build-gcs-fetcher-image
            - gcr.io/tekton-releases/github.com/tektoncd/pipeline/vendor/github.com/googlecloudplatform/cloud-builders/gcs-fetcher/cmd/gcs-fetcher:v0.21.0@sha256:41c251a2cc7e7c6e6c0f8d3bc3f0c3cc6a980325e754d4d95570c775a2a80b35
            - -gsutil-image
            - gcr.io/google.com/cloudsdktool/cloud-sdk@sha256:27b2c22bf259d9bc1a291e99c63791ba0c27a04d2db0a43241ba0f1f20f4067f
            - -shell-image
            - gcr.io/distroless/base@sha256:92720b2305d7315b5426aec19f8651e9e04222991f877cae71f40b3141d2f07e
          env:
            - name: SYSTEM_NAMESPACE
              valueFrom:
                fieldRef:
                  fieldPath: metadata.namespace
            - name: CONFIG_DEFAULTS_NAME
              value: config-defaults
            - name: CONFIG_LOGGING_NAME
              value: config-logging
            - name: CONFIG_OBSERVABILITY_NAME
              value: config-observability
            - name: CONFIG_ARTIFACT_BUCKET_NAME
              value: config-artifact-bucket
            - name: CONFIG_ARTIFACT_PVC_NAME
              value: config-artifact-pvc
            - name: CONFIG_FEATURE_FLAGS_NAME
              value: feature-flags
            - name: CONFIG_LEADERELECTION_NAME
              value: config-leader-election
            - name: SSL_CERT_FILE
              value: /etc/config-registry-cert/cert
            - name: SSL_CERT_DIR
              value: /etc/ssl/certs
            - name: METRICS_DOMAIN
              value: tekton.dev/pipeline
          image: gcr.io/tekton-releases/github.com/tektoncd/pipeline/cmd/controller:v0.21.0@sha256:972ee9c3f43c88495b074bfc0a8350eb34131355ab9ddc5da63c59f64d74e83d
          livenessProbe:
            httpGet:
              path: /health
              port: probes
              scheme: HTTP
            initialDelaySeconds: 5
            periodSeconds: 10
            timeoutSeconds: 5
          name: tekton-pipelines-controller
          ports:
            - containerPort: 8080
              name: probes
          readinessProbe:
            httpGet:
              path: /readiness
              port: probes
              scheme: HTTP
            initialDelaySeconds: 5
            periodSeconds: 10
            timeoutSeconds: 5
          securityContext:
            allowPrivilegeEscalation: false
            capabilities:
              drop:
                - all
            runAsGroup: 65532
            runAsUser: 65532
          volumeMounts:
            - mountPath: /etc/config-logging
              name: config-logging
            - mountPath: /etc/config-registry-cert
              name: config-registry-cert
      serviceAccountName: tekton-pipelines-controller
      volumes:
        - configMap:
            name: config-logging
          name: config-logging
        - configMap:
            name: config-registry-cert
          name: config-registry-cert
