apiVersion: apps/v1
kind: Deployment
metadata:
    labels:
      app: flatpak-cache
      app.kubernetes.io/component: flatpak-cache
      app.kubernetes.io/instance: flatpak-cache
      app.kubernetes.io/name: flatpak-cache
      app.kubernetes.io/part-of: flatpak-cache-app
    name: flatpak-cache
spec:
    progressDeadlineSeconds: 600
    replicas: 1
    revisionHistoryLimit: 10
    selector:
      matchLabels:
        app: flatpak-cache
    strategy:
      type: Recreate
    template:
      metadata:
        creationTimestamp: null
        labels:
          app: flatpak-cache
          deployment: flatpak-cache
      spec:
        containers:
        - env:
          volumeMounts:
          - name: config-volume
            mountPath: /etc/squid
            readOnly: true
          - name: data
            mountPath: /var/spool/squid
          - name: flatpak-cache-ca-volume
            mountPath: /etc/pki/squid/ca
            readOnly: true
          - name: flatpak-cache-key-volume
            mountPath: /etc/pki/squid/key
            readOnly: true
          - name: flatpak-cache-dhparam-volume
            mountPath: /etc/pki/squid/dhparam
            readOnly: true
          imagePullPolicy: Always
          image: image-registry.openshift-image-registry.svc:5000/flatpak-cache/flatpak-cache:latest
          name: flatpak-cache
          ports:
            - containerPort: 3128
          command:
            - bash
          args:
            - /etc/squid/start.sh
          resources: {}
          terminationMessagePath: /dev/termination-log
          terminationMessagePolicy: File
        dnsPolicy: ClusterFirst
        restartPolicy: Always
        schedulerName: default-scheduler
        securityContext: {}
        terminationGracePeriodSeconds: 30
        volumes:
        - name: config-volume
          configMap:
            name: flatpak-cache-configmap
        - name: data
          persistentVolumeClaim:
            claimName: data
        - name: flatpak-cache-ca-volume
          secret:
            secretName: flatpak-cache-ca
        - name: flatpak-cache-key-volume
          secret:
            secretName: flatpak-cache-key
        - name: flatpak-cache-dhparam-volume
          secret:
            secretName: flatpak-cache-dhparam
