-
Notifications
You must be signed in to change notification settings - Fork 21
/
.gitlab-ci.yml
88 lines (84 loc) · 4.34 KB
/
.gitlab-ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
# Include shared CI
include:
- project: "epi2melabs/ci-templates"
file: "wf-containers.yaml"
variables:
NF_WORKFLOW_OPTS: "--fastq test_data/fastq --references test_data/references \
--counts test_data/counts/ERCC_mix1.csv"
CI_FLAVOUR: "new"
docker-run:
tags: []
# Define a 1D job matrix to inject a variable named MATRIX_NAME into
# the CI environment, we can use the value of MATRIX_NAME to determine
# which options to apply as part of the rules block below
# NOTE There is a slightly cleaner way to define this matrix to include
# the variables, but it is broken when using long strings! See CW-756
parallel:
matrix:
- MATRIX_NAME: [
"fastq", "bam", "ubam", "compress-one-ref", "compress-all-refs", "mmi"
]
rules:
# NOTE As we're overriding the rules block for the included docker-run
# we must redefine this CI_COMMIT_BRANCH rule to prevent docker-run
# being incorrectly scheduled for "detached merge request pipelines" etc.
- if: ($CI_COMMIT_BRANCH == null || $CI_COMMIT_BRANCH == "dev-template")
when: never
- if: $MATRIX_NAME == "fastq"
variables:
NF_WORKFLOW_OPTS: "--fastq test_data/fastq --references test_data/references \
--counts test_data/counts/ERCC_mix1.csv -executor.\\$$local.memory 12GB"
NF_IGNORE_PROCESSES: checkReferences,renameBamFiles
- if: $MATRIX_NAME == "bam"
variables:
NF_WORKFLOW_OPTS: "--bam test_data/bam --references test_data/references \
--counts test_data/counts/ERCC_mix1.csv -executor.\\$$local.memory 12GB"
NF_IGNORE_PROCESSES: alignReads,checkReferences
- if: $MATRIX_NAME == "ubam"
variables:
NF_WORKFLOW_OPTS: "--bam test_data/ubam --references test_data/references \
--counts test_data/counts/ERCC_mix1.csv -executor.\\$$local.memory 12GB"
NF_IGNORE_PROCESSES: checkReferences,renameBamFiles
# run on FASTQ again after compressing one / all references
- if: $MATRIX_NAME == "compress-one-ref"
variables:
NF_BEFORE_SCRIPT: |
mkdir -p $CI_PROJECT_NAME &&
cp -r test_data/references $CI_PROJECT_NAME/refs &&
gzip $CI_PROJECT_NAME/refs/ERCC.fasta
NF_WORKFLOW_OPTS: "--fastq test_data/fastq --references $CI_PROJECT_NAME/refs \
--counts test_data/counts/ERCC_mix1.csv -executor.\\$$local.memory 12GB"
NF_IGNORE_PROCESSES: checkReferences,renameBamFiles
- if: $MATRIX_NAME == "compress-all-refs"
variables:
NF_BEFORE_SCRIPT: |
mkdir -p $CI_PROJECT_NAME &&
cp -r test_data/references $CI_PROJECT_NAME/refs &&
gzip $CI_PROJECT_NAME/refs/*
NF_WORKFLOW_OPTS: "--fastq test_data/fastq --references $CI_PROJECT_NAME/refs \
--counts test_data/counts/ERCC_mix1.csv -executor.\\$$local.memory 12GB"
NF_IGNORE_PROCESSES: checkReferences,renameBamFiles
- if: $MATRIX_NAME == "mmi"
variables:
NF_WORKFLOW_OPTS: "--fastq test_data/fastq --references test_data/references \
--reference_mmi_file test_data/references/combined_references.mmi -executor.\\$$local.memory 12GB"
NF_IGNORE_PROCESSES: makeMMIndex,renameBamFiles
aws-run:
parallel:
matrix:
- MATRIX_NAME: [ "counts", "no-counts" ]
rules:
# NOTE As we're overriding the rules block for the included docker-run
# we must redefine this CI_COMMIT_BRANCH rule to prevent docker-run
# being incorrectly scheduled for "detached merge request pipelines" etc.
- if: ($CI_COMMIT_BRANCH == null || $CI_COMMIT_BRANCH == "dev-template")
when: never
- if: $MATRIX_NAME == "counts"
variables:
NF_WORKFLOW_OPTS: "--fastq test_data/fastq --references test_data/references \
--counts test_data/counts/ERCC_mix1.csv"
NF_IGNORE_PROCESSES: sortInputBam
- if: $MATRIX_NAME == "no-counts"
variables:
NF_WORKFLOW_OPTS: "--fastq test_data/fastq --references test_data/references"
NF_IGNORE_PROCESSES: sortInputBam