apiVersion: apps/v1
kind: Deployment
metadata:
  labels:
    app: seldon
    app.kubernetes.io/component: seldon
    app.kubernetes.io/instance: seldon-1.15
    app.kubernetes.io/managed-by: kfctl
    app.kubernetes.io/name: seldon-core-operator
    app.kubernetes.io/part-of: kubeflow
    app.kubernetes.io/version: "1.15"
    control-plane: seldon-controller-manager
  name: seldon-controller-manager
  namespace: kubeflow
spec:
  replicas: 1
  selector:
    matchLabels:
      app: seldon
      app.kubernetes.io/component: seldon
      app.kubernetes.io/instance: seldon-1.15
      app.kubernetes.io/managed-by: kfctl
      app.kubernetes.io/name: seldon-core-operator
      app.kubernetes.io/part-of: kubeflow
      app.kubernetes.io/version: "1.15"
      control-plane: seldon-controller-manager
  template:
    metadata:
      annotations:
        prometheus.io/scrape: "true"
        sidecar.istio.io/inject: "false"
      labels:
        app: seldon
        app.kubernetes.io/component: seldon
        app.kubernetes.io/instance: seldon-1.15
        app.kubernetes.io/managed-by: kfctl
        app.kubernetes.io/name: seldon-core-operator
        app.kubernetes.io/part-of: kubeflow
        app.kubernetes.io/version: "1.15"
        control-plane: seldon-controller-manager
    spec:
      containers:
      - args:
        - --enable-leader-election
        - --webhook-port=443
        - ""
        command:
        - /manager
        env:
        - name: POD_NAMESPACE
          valueFrom:
            fieldRef:
              fieldPath: metadata.namespace
        - name: CONTROLLER_ID
          value: ""
        - name: AMBASSADOR_ENABLED
          value: "true"
        - name: AMBASSADOR_SINGLE_NAMESPACE
          value: "false"
        - name: ENGINE_CONTAINER_IMAGE_AND_VERSION
          value: docker.io/seldonio/engine:1.0.2
        - name: ENGINE_CONTAINER_IMAGE_PULL_POLICY
          value: IfNotPresent
        - name: ENGINE_CONTAINER_SERVICE_ACCOUNT_NAME
          value: default
        - name: ENGINE_CONTAINER_USER
          value: "8888"
        - name: ENGINE_LOG_MESSAGES_EXTERNALLY
          value: "false"
        - name: PREDICTIVE_UNIT_SERVICE_PORT
          value: "9000"
        - name: ENGINE_SERVER_GRPC_PORT
          value: "5001"
        - name: ENGINE_SERVER_PORT
          value: "8000"
        - name: ENGINE_PROMETHEUS_PATH
          value: prometheus
        - name: ISTIO_ENABLED
          value: "true"
        - name: ISTIO_GATEWAY
          value: kubeflow-gateway
        - name: ISTIO_TLS_MODE
          value: ""
        image: docker.io/seldonio/seldon-core-operator:1.0.2
        imagePullPolicy: IfNotPresent
        name: manager
        ports:
        - containerPort: 443
          name: webhook-server
          protocol: TCP
        - containerPort: 8080
          name: metrics
          protocol: TCP
        resources:
          limits:
            cpu: 500m
            memory: 300Mi
          requests:
            cpu: 100m
            memory: 200Mi
        volumeMounts:
        - mountPath: /tmp/k8s-webhook-server/serving-certs
          name: cert
          readOnly: true
      serviceAccountName: seldon-manager
      terminationGracePeriodSeconds: 10
      volumes:
      - name: cert
        secret:
          defaultMode: 420
          secretName: seldon-webhook-server-cert
