---
pipeline:
  name: tchain_array_parser
transform:
  # image_pull_secrets:
  # - battelleecology-quay-read-all-pull-secret
  image: us-central1-docker.pkg.dev/neon-shared-service/neonscience/neon-is-array-parser:v3.0.0
  cmd:
  - /bin/bash
  stdin:
  - '#!/bin/bash'
  - python3 -m array_parser.array_parser_main
  env:
    OUT_PATH: /pfs/out
    PARSE_CALIBRATION: 'True'
    TEST_MODE: 'False'
    LOG_LEVEL: DEBUG
    SOURCE_TYPE_INDEX: '3'
    YEAR_INDEX: '4'
    MONTH_INDEX: '5'
    DAY_INDEX: '6'
    SOURCE_ID_INDEX: '7'
    DATA_TYPE_INDEX: '8'
input:
  cross:
  - pfs:
      name: SCHEMA_PATH
      repo: avro_schemas_tchain
      branch: master
      glob: /tchain/tchain_parsed.avsc
  - pfs:
      name: DATA_PATH
      repo: tchain_data_calibration_group
      branch: master
      glob: /tchain/*/*/*
resource_requests:
  memory: 500M
  cpu: 1
autoscaling: true

scheduling_spec:
  node_selector:
    cloud.google.com/gke-ephemeral-storage-local-ssd: "true"
    nodepool.neonscience.org/pipeline: "yes"
    cloud.google.com/gke-spot: "true"
pod_spec: |-
  { "tolerations": [
    {
      "key": "nodepool.neonscience.org/pipeline",
      "operator": "Exists"
    },
    {
      "effect": "NoSchedule",
      "key": "cloud.google.com/gke-spot",
      "operator": "Exists"
    }  
  ] }
pod_patch: |-
  [
    { "op": "replace",
      "path":"/containers/1/resources/requests/memory",
      "value":"300M"
    },
    { "op": "replace",
      "path": "/containers/1/resources/requests/cpu",
      "value": "0.2"
    }
  ]
