-
Notifications
You must be signed in to change notification settings - Fork 1
/
tmrc2_analyses.yml
121 lines (101 loc) · 4.46 KB
/
tmrc2_analyses.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
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
Bootstrap: docker
From: debian:stable
## Order of sections:
## %labels: unknown, storing metadata
## %files: are before %post or installation procedures.
## %setup: in the host-system after base OS install.
## %post: in the container after base OS install.
## %test: run at end of build process.
## %environment: sourced at runtime, not build; if needed at build, do it in %post.
## %runscript: writes the container file /singularity and is run via 'singularity run'
%apphelp hpgltools_test
echo "Run the hpgltools test suite."
%apprun hpgltools_test
echo "Running the hpgltools test suite."
exec cd /data/hpgltools && make test
%environment
## If this works properly, I can delete the bashrc, apparently the contents of this stanza are
## written to /.singularity.d/env/90-environment.sh
## As of this writing, it appears VERSION is not propagated to the %post block, therefore
## the definition is repeated there.
umask 002
export VERSION=202309
export CLICOLOR=true
export CONDA_DEFAULT_ENV=hpgltools
export CONDA_PREFIX=/sw/local/conda/${VERSION}/envs/hpgltools
export CONDA_SHLVL=1
export DEBIAN_FRONTEND=noninteractive
export EDITOR=vi
export FTP_PASSIVE=1
export GREP_COLORS=32
export GREP_OPTIONS=--color=auto
export HACKPAGER=more
export LC_ALL="C"
export LESSOPEN="| /usr/bin/lesspipe %s"
export LESS="-RX"
export MAKEFLAGS="-j $(grep -c ^processor /proc/cpuinfo)"
export MAMBA_EXE=/usr/bin/micromamba
export MAMBA_ROOT_PREFIX="/sw/local/conda/${VERSION}"
export PAGER=less
export PATH=/sw/local/conda/${VERSION}/envs/hpgltools/bin:/sw/local/conda/${VERSION}/condabin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
export R_MAX_NUM_DLLS=512
export R_USER_CACHE_DIR="/tmp/my_r_cache"
export DEFAULT_INPUT="01datasets.Rmd:02pre_visualization.Rmd:03differential_expression.Rmd:04post_visualization.Rmd"
## Instead of copying files within the setup section, one should use the files block, I think because
## this is not run with elevated permissions.
%files
local/etc/bashrc /usr/local/etc/bashrc
local/bin/runscript.sh /usr/local/bin/runscript.sh
local/bin/setup_local.sh /usr/local/bin/setup_local.sh
local/bin/setup_debian.sh /usr/local/bin/setup_debian.sh
local/bin/setup_hpgltools.sh /usr/local/bin/setup_hpgltools.sh
data/Makefile /data/Makefile
local/etc/template /sw/modules/template
data/00preprocessing.Rmd /data/00preprocessing.Rmd
data/01datasets.Rmd /data/01datasets.Rmd
data/02pre_visualization.Rmd /data/02pre_visualization.Rmd
data/03differential_expression.Rmd /data/03differential_expression.Rmd
data/04post_visualization.Rmd /data/04post_visualization.Rmd
data/preprocessing/tmrc2_count_tables.tar /data/preprocessing/tmrc2_count_tables.tar
data/preprocessing/freebayes_tags.tar /data/preprocessing/freebayes_tags.tar
data/preprocessing/macrophage_host_counts.tar /data/preprocessing/macrophage_host_counts.tar
data/preprocessing/macrophage_parasite_counts.tar /data/preprocessing/macrophage_parasite_counts.tar
data/sample_sheets/ClinicalStrains_TMRC2.xlsx /data/sample_sheets/ClinicalStrains_TMRC2.xlsx
data/sample_sheets/tmrc2_macrophage_samples.xlsx /data/sample_sheets/tmrc2_macrophage_samples.xlsx
%help
String printed when "singularity help image.simg" is run.
%labels
Maintainer Ashton Trey Belew <[email protected]>
Version v202309
%post
export VERSION=202309
export BIOC_VERSION=3.18
export R_BIOC_VERSION=${BIOC_VERSION}
echo "Beginning installation with version: ${VERSION}."
/usr/local/bin/setup_debian.sh
/usr/local/bin/setup_hpgltools.sh
/usr/local/bin/setup_local.sh
%runscript
/usr/local/bin/runscript.sh $*
## The setup block will be used to copy material which I cannot acquire
## automatically. Ideally this should only be a sample sheet and potentially
## count tables for now. ** NOTE ** This section is run as root! So be careful.
%setup
mkdir -p ${SINGULARITY_ROOTFS}/usr/local/bin
mkdir -p ${SINGULARITY_ROOTFS}/usr/local/etc
mkdir -p ${SINGULARITY_ROOTFS}/.emacs.d
mkdir -p ${SINGULARITY_ROOTFS}/data/preprocessing
mkdir -p ${SINGULARITY_ROOTFS}/data/R
mkdir -p ${SINGULARITY_ROOTFS}/data/cpm
mkdir -p ${SINGULARITY_ROOTFS}/data/rpkm
mkdir -p ${SINGULARITY_ROOTFS}/data/images
mkdir -p ${SINGULARITY_ROOTFS}/data/figures
mkdir -p ${SINGULARITY_ROOTFS}/data/rda
mkdir -p ${SINGULARITY_ROOTFS}/data/excel
mkdir -p ${SINGULARITY_ROOTFS}/data/sample_sheets
mkdir -p ${SINGULARITY_ROOTFS}/output
mkdir -p ${SINGULARITY_ROOTFS}/sw/local/conda
mkdir -p ${SINGULARITY_ROOTFS}/sw/modules
%test
echo "Making sure hpgltools got installed."
test -d "/data/hpgltools" || true