apiVersion: apps/v1
kind: Deployment
metadata:
  name: ml-pipeline
spec:
  template:
    metadata:
      annotations:
        sidecar.istio.io/inject: "false"
    spec:
      containers:
      - name: ml-pipeline-api-server
        env:
        - name: POD_NAMESPACE
          valueFrom:
            fieldRef:
              fieldPath: metadata.namespace
        image: gcr.io/ml-pipeline/api-server
        imagePullPolicy: IfNotPresent
        command:
          - apiserver
          - --config=/etc/ml-pipeline-config
          - --sampleconfig=/config/sample_config.json
          - -logtostderr=true
        ports:
        - containerPort: 8888
        - containerPort: 8887
        volumeMounts:
        - name: config-volume
          mountPath: /etc/ml-pipeline-config
      serviceAccountName: ml-pipeline
      volumes:
        - name: config-volume
          configMap:
            name: ml-pipeline-config
