apiVersion: apps/v1
kind: StatefulSet
metadata:
  labels:
    app.kubernetes.io/component: iap-ingress
    app.kubernetes.io/instance: iap-ingress-v1.0.0
    app.kubernetes.io/managed-by: kfctl
    app.kubernetes.io/name: iap-ingress
    app.kubernetes.io/part-of: kubeflow
    app.kubernetes.io/version: v1.0.0
    kustomize.component: iap-ingress
    service: backend-updater
  name: backend-updater
  namespace: istio-system
spec:
  selector:
    matchLabels:
      app.kubernetes.io/component: iap-ingress
      app.kubernetes.io/instance: iap-ingress-v1.0.0
      app.kubernetes.io/managed-by: kfctl
      app.kubernetes.io/name: iap-ingress
      app.kubernetes.io/part-of: kubeflow
      app.kubernetes.io/version: v1.0.0
      kustomize.component: iap-ingress
      service: backend-updater
  serviceName: backend-updater
  template:
    metadata:
      labels:
        app.kubernetes.io/component: iap-ingress
        app.kubernetes.io/instance: iap-ingress-v1.0.0
        app.kubernetes.io/managed-by: kfctl
        app.kubernetes.io/name: iap-ingress
        app.kubernetes.io/part-of: kubeflow
        app.kubernetes.io/version: v1.0.0
        kustomize.component: iap-ingress
        service: backend-updater
    spec:
      containers:
      - command:
        - bash
        - /var/envoy-config/update_backend.sh
        env:
        - name: NAMESPACE
          value: istio-system
        - name: SERVICE
          value: istio-ingressgateway
        - name: INGRESS_NAME
          value: envoy-ingress
        - name: USE_ISTIO
          value: "true"
        image: gcr.io/kubeflow-images-public/ingress-setup:latest
        name: backend-updater
        volumeMounts:
        - mountPath: /var/envoy-config/
          name: config-volume
      serviceAccountName: kf-admin
      volumes:
      - configMap:
          name: envoy-config
        name: config-volume
  volumeClaimTemplates: []
