# Submitted by the Argo Events sensor in events.yaml for each "vcf-uploaded" Pub/Sub message. # The Nextflow driver runs here; its tasks run on Google Batch (see the gcp profile in # pipeline/nextflow.config). Image names are rewritten by the gcp overlay and bumped by CI. apiVersion: argoproj.io/v1alpha1 kind: WorkflowTemplate metadata: { name: annotate-vcf } spec: serviceAccountName: rarelens-pipeline entrypoint: nextflow onExit: exit-handler arguments: parameters: - { name: job_id } - { name: vcf_uri } - { name: assembly, value: GRCh38 } templates: - name: nextflow container: image: rarelens/pipeline args: - run - /pipeline/main.nf - -profile - gcp - --vcf - "{{workflow.parameters.vcf_uri}}" - --job_id - "{{workflow.parameters.job_id}}" - --assembly - "{{workflow.parameters.assembly}}" # GCP_PROJECT / GCS_BUCKET / GCP_REGION feed params in nextflow.config. envFrom: [{ configMapRef: { name: pipeline-config } }] resources: { requests: { cpu: "1", memory: 2Gi } } # The loader marks success; anything else (Nextflow error, OOM, eviction) is marked here # so the UI never polls a dead job forever. - name: exit-handler steps: - - name: mark-failed template: mark-failed when: "{{workflow.status}} != Succeeded" - name: mark-failed container: image: rarelens/loader command: [set_job_status.py] args: - --job-id - "{{workflow.parameters.job_id}}" - --status - failed - --log - "Argo workflow {{workflow.name}} ended {{workflow.status}}" envFrom: [{ secretRef: { name: pipeline-secrets } }] resources: { requests: { cpu: 100m, memory: 256Mi } }