@@ -235,6 +235,24 @@ ${docker.repository}/exomiser-cli latest f39698e3f36b 53 ye
235235${docker.repository} /exomiser-cli ${project.version} f39698e3f36b 53 years ago 274 MB
236236```
237237
238+ ### <a id =" docker-environment-variables " ></a >Docker environment variables
239+
240+ Exomiser will require at least two environment variables to be set. These can be provided using ` -e ` or ` --env `
241+ or by creating a ` .env ` file.
242+
243+ ``` shell
244+ # -e EXOMISER_DATA_DIRECTORY=/exomiser-data # This variable is automatically set in the docker image
245+ -e EXOMISER_HG19_DATA_VERSION=2512 \
246+ -e EXOMISER_PHENOTYPE_DATA_VERSION=2512
247+ ```
248+
249+ These variables can also be specified in the ` application.properties ` file which should be made available via a mounted
250+ volume.
251+
252+ ``` shell
253+ -e SPRING_CONFIG_LOCATION=/path/to/your/application.properties
254+ ```
255+
238256### <a id =" working-with-the-distroless-image " ></a >Working with the distroless image (no shell)
239257
240258Distroless images are the default image and come without a shell. These are can be pulled using
@@ -246,24 +264,14 @@ If you choose to run the distroless image use the following command:
246264 docker run -v " /path/to/exomiser-data:/exomiser-data" \
247265 -v " /path/to/exomiser/exomiser-config/:/exomiser" \
248266 -v " /path/to/exomiser/results:/results" \
267+ -e SPRING_CONFIG_LOCATION=/exomiser/application.properties
249268 ${docker.repository} /exomiser-cli:${project.version} \
250- analyse --analysis /exomiser/test-analysis-exome.yml \
251- --spring.config.location=/exomiser/application.properties
269+ exomiser analyse --analysis /exomiser/examples/preset-exome-analysis-human-only.yml \
270+ --vcf /exomiser/examples/Pfeiffer.vcf.gz --assembly hg19 \
271+ --sample /exomiser/examples/pfeiffer-phenopacket.yml \
272+ --output-directory /results --output-format=PARQUET --output-filename docker-test
252273```
253274
254- or using Spring configuration arguments instead of the ` application.properties ` :
255-
256- ``` shell
257- docker run -v " /path/to/exomiser-data:/exomiser-data" \
258- -v " /path/to/exomiser/exomiser-config/:/exomiser" \
259- -v " /path/to/exomiser/results:/results" \
260- ${docker.repository} /exomiser-cli:${project.version} \
261- analyse --analysis /exomiser/test-analysis-exome.yml \
262- # minimal requirements for an hg19 exome sample
263- --exomiser.data-directory=/exomiser-data \
264- --exomiser.hg19.data-version=${genome.data.version} \
265- --exomiser.phenotype.data-version=${phenotype.data.version}
266- ```
267275-----
268276
269277In both cases, to run the image you will need the standard Exomiser directory layout to mount as separate volumes as in the CLI and
@@ -281,46 +289,44 @@ exomiser.data-directory=/exomiser-data
281289### <a id =" working-with-the-docker-bash-image " ></a >Working with the docker bash images
282290
283291Running the image with the following command will open the shell and create volumes with
284- links to the exomiser data and connects the results to your local machine. ` /results ` should be an empty directory,
285- where Exomiser will write the results into.
286-
292+ links to the exomiser data and connect the results to your local machine. ` /results ` should be a directory,
293+ where Exomiser will write the results into. The host path ` /path/to/exomiser-data ` should contain the unpacked data
294+ directories ` 2512_hg19 ` and ` 2512_phenotype ` .
287295
288296``` shell
289297docker run -v " /path/to/exomiser-data:/exomiser-data" \
290298 -v " /path/to/exomiser/exomiser-config/:/exomiser" \
291299 -v " /path/to/exomiser/results:/results" \
292- ${docker.repository} /exomiser-cli:${project.version} -bash
300+ -e EXOMISER_HG19_DATA_VERSION=2512 \
301+ -e EXOMISER_PHENOTYPE_DATA_VERSION=2512 \
302+ -it ${docker.repository} /exomiser-cli:${project.version} -bash
293303```
294304
295305Here the contents of ` /path/to/exomiser/exomiser-config ` is simply the ` application.properties ` file and the example files
296- to test all is working correctly.
306+ to test all is working correctly. The ` application.properties ` file can be omitted if the genomic and phenotype data
307+ versions have been provided as environment variables.
297308
298309``` shell
299310$ tree /path/to/exomiser/exomiser-config/
300311exomiser-config/
301312├── application.properties
302313├── Pfeiffer.vcf.gz
303314├── Pfeiffer.vcf.gz.tbi
304- └── test-analysis-exome.yml
315+ ├── pfeiffer-phenopacket.yml
316+ └── preset-exome-analysis-human-only.yml
305317```
306318
307319#### Running Exomiser from the bash shell
308- After running the following commands Exomiser will be started from the containers shell.
320+
321+ The entrypoint for the image is ` /bin/bash ` and the command to run Exomiser is:
309322
310323``` shell
311- source enable_exomiser.sh
312- bash enable_exomiser.sh
313- exomiser analyse --analysis /exomiser/test-analysis-exome .yml \
314- --spring.config.location=/exomiser/application.properties
324+ exomiser analyse --analysis /exomiser/examples/preset-exome-analysis-human-only.yml \
325+ --vcf /exomiser/examples/Pfeiffer.vcf.gz --assembly hg19 \
326+ --sample /exomiser/examples/pfeiffer-phenopacket .yml \
327+ --output-directory /results --output-format=PARQUET --output-filename docker-test
315328```
316329
317- or using Spring configuration arguments instead of the ` application.properties ` :
330+ If successful, the results will be written to ` /results/docker-test.parquet ` .
318331
319- ``` shell
320- exomiser --analysis /exomiser/test-analysis-exome.yml \
321- # minimal requirements for an hg19 exome sample
322- --exomiser.data-directory=/exomiser-data \
323- --exomiser.hg19.data-version=${genome.data.version} \
324- --exomiser.phenotype.data-version=${phenotype.data.version}
325- ```
326332-----
0 commit comments