Question: How to run Picard docker image
0
gravatar for elcortegano
3 months ago by
elcortegano20
elcortegano20 wrote:

I'm trying to run Picard CreateSequenceDictionary using the docker image provided by the Broadinstitute (here), but |I'm having troubles when running it, and don't understand why.

I download and run it as:

docker pull broadinstitute/picard
docker run --rm -v $PWD:/usr/working broadinstitute/picard CreateSequenceDictionary R=ref.fa.gz O=ref.fa.gz.dict

But this returns an error:

docker: Error response from daemon: OCI runtime create failed: container_linux.go:345: starting container process caused "exec: \"CreateSequenceDictionary\": executable file not found in $PATH": unknown.

If the image is run without specifying the command (e.g. without CreateSequenceDictionary and the arguments) nothing is returned.

Does anybody know how to run this image properly?

EDIT

The docker image even does not work if a change the Dockerfile provided in the official Github repository and add an entrypoint to the executable:

ENTRYPOINT ["/usr/local/openjdk-8/bin/java -jar /usr/picard/picard.jar"]

However, the original image will work with the command used in the entrypoint if the image is run interactively (with -i -t options), which is not how I want to run it.

This time, with the entrypoint, the error is:

docker: Error response from daemon: OCI runtime create failed: container_linux.go:345: starting container process caused "exec: \"/usr/local/openjdk-8/bin/java -jar /usr/picard/picard.jar\": stat /usr/local/openjdk-8/bin/java -jar /usr/picard/picard.jar: no such file or directory": unknown.

Any ideas on how make it work?

ADD COMMENTlink modified 3 months ago • written 3 months ago by elcortegano20
0
gravatar for elcortegano
3 months ago by
elcortegano20
elcortegano20 wrote:

The problem was this was with the syntax for the ENTRYPOINT, if fixed to this:

ENTRYPOINT ["java","-jar,"/usr/picard/picard.jar"]

This can be seen at docker documentation: https://docs.docker.com/engine/reference/builder/#entrypoint.

If this line is added to the picard Dockerfile provided by the Broadinstitute, the resulting docker image will run non-interactively as:

docker run --rm -v $PWD:/usr/working picard CreateSequenceDictionary R=genome.fa O=genome.fa.dict

(For example).

ADD COMMENTlink written 3 months ago by elcortegano20
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 1741 users visited in the last hour