I am trying to run the official bwa docker https://hub.docker.com/r/biocontainers/bwa/, and I keep getting an error:
sudo docker run -u="root" -v ~/files/:/opt/inputs/ biocontainers/bwa "index /opt/inputs/hg19.fa"
docker: Error response from daemon: OCI runtime create failed: container_linux.go:348: starting container process caused "exec: \"index /opt/inputs/hg19.fa\": stat index /opt/inputs/hg19.fa: no such file or directory": unknown.
ERRO[0000] error waiting for container: context canceled
EDIT: Removing the double quotes from the lst string gives a different error:
sudo docker run -u="root" -v ~/files/:/opt/inputs/ biocontainers/bwa index /opt/inputs/hg19.fa
docker: Error response from daemon: OCI runtime create failed: container_linux.go:348: starting container process caused "exec: \"index\": executable file not found in $PATH": unknown.
I have found the reason behind it here:
docker: executable file not found in $PATH
This is the correct reason, but since this file was pre-build, and I want to use the official release, I cannot change the CMD synthax in Dockerfile. How can I make this work without changing the container itself?