---
apiVersion: apps/v1
kind: Deployment
metadata:
  name: eirini-api
  namespace: eirini-core
spec:
  selector:
    matchLabels:
      name: eirini-api
  template:
    metadata:
      labels:
        name: eirini-api
        eirinifs_version: v75.0.0
    spec:
      dnsPolicy: ClusterFirst
      serviceAccountName: opi
      volumes:
        - name: config-map
          configMap:
            name: eirini
        - name: cc-certs
          secret:
            secretName: capi-tls
            optional: true
        - name: eirini-certs
          secret:
            secretName: eirini-certs
            optional: true
      securityContext:
        runAsNonRoot: true
      containers:
      - name: opi
        image: eirini/opi@sha256:f6f6476eaa951ac2520b7f7fe42aa95c1480c00e099c585cdc136302db122b94
        imagePullPolicy: Always
        volumeMounts:
        - name: config-map
          mountPath: /etc/eirini/config
        - name: eirini-certs
          mountPath: /etc/eirini/certs
        - name: cc-certs
          mountPath: /etc/cf-api/certs
        ports:
        - containerPort: 8085
          name: https
        resources:
          requests:
            cpu: 20m
            memory: 20
