apiVersion: batch/v1
kind: Job
metadata:
  labels:
    app: modelmanager-platform
    app.kubernetes.io/version: 2019.10.0
  name: modelmanager-platform
  namespace: default
spec:
  template:
    metadata:
      labels:
        app: modelmanager-platform
    spec:
      containers:
      - env:
        - name: MODELMANAGER_HOME
          value: /modelmanager-2019.10.0/
        - name: MODELMANAGER_SCHEMA
          value: platform
        - name: MODELMANAGER_AUTO
          value: "true"
        - name: cassandra_contactPoints
          valueFrom:
            configMapKeyRef:
              key: CASSANDRA_CONTACTPOINTS
              name: cluster-config
        - name: cassandra_keyspace
          value: production
        - name: BOOTSTRAP_SERVERS
          valueFrom:
            configMapKeyRef:
              key: BOOTSTRAP_SERVERS
              name: arcus-config
              name: arcus-config
        - name: OPS_BOOTSTRAP_SERVERS
          valueFrom:
            configMapKeyRef:
              key: OPS_BOOTSTRAP_SERVERS
              name: arcus-config
        - name: PARTITION_COUNT
          valueFrom:
            configMapKeyRef:
              key: PARTITION_COUNT
              name: arcus-config
        - name: IRIS_AES_SECRET
          valueFrom:
            secretKeyRef:
              key: iris.aes.secret
              name: shared
        - name: IRIS_AES_IV
          valueFrom:
            secretKeyRef:
              key: iris.aes.iv
              name: shared
        - name: QUESTIONS_AES_SECRET
          valueFrom:
            secretKeyRef:
              key: questions.aes.secret
              name: shared
        image: gcr.io/arcus-238802/arcus/modelmanager:2019.10.0
        imagePullPolicy: Always
        command: ["/modelmanager-2019.10.0/bin/modelmanager"]
        args: ["-c", "/modelmanager-2019.10.0/conf/arcus-modelmanager.properties", "-P", "production"]
        name: modelmanager-platform
        resources: {}
        terminationMessagePath: /dev/termination-log
        terminationMessagePolicy: File
      dnsPolicy: ClusterFirst
      restartPolicy: OnFailure
      schedulerName: default-scheduler
      securityContext: {}
      terminationGracePeriodSeconds: 30
