-
Notifications
You must be signed in to change notification settings - Fork 1
/
smiinit.sh
executable file
·25 lines (25 loc) · 1.11 KB
/
smiinit.sh
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
#!/bin/sh
set -e
export SMI_ROOT=/smi
export SMI_LOGS_ROOT=/logs
[ -d /data ] || echo "FATAL: Data volume missing!"
[ -d /data ] || exit
[ -d /logs ] || echo "WARNING: Log volume missing, discarding logs!"
mkdir -p /data/identifiablerules/tessdata
[ -e /data/identifiablerules/tessdata/eng.traineddata ] || zcat /smi/eng.traineddata.gz > /data/identifiablerules/tessdata/eng.traineddata
mkdir -p /logs
touch /logs/.writetest || echo "FATAL: Logs not writable"
touch /logs/.writetest || exit
cat << EOS > /smi/smi.yaml
jobs:
- "/opt/java/openjdk/bin/java -jar /smi/smi-nerd-v4.0.0.jar"
- "/opt/java/openjdk/bin/java -jar /smi/CTPAnonymiser-portable-1.0.0.jar -a /smi/ctp-whitelist.script -y /smi/smi.yaml"
- "/smi/smi dicom-relational-mapper -y /smi/smi.yaml"
- "/smi/smi is-identifiable service -y /smi/smi.yaml"
- "/smi/smi cohort-extractor -y /smi/smi.yaml"
- "/smi/smi dicom-tag-reader -y /smi/smi.yaml"
- "/smi/smi mongodb-populator -y /smi/smi.yaml"
- "/smi/smi cohort-packager -y /smi/smi.yaml"
- "/smi/smi file-copier -y /smi/smi.yaml"
- "/smi/smi identifier-mapper -y /smi/smi.yaml"
- "/smi/smi update-values -y /smi/smi.yaml"