# Help with Entrypoint calling script

**URL:** <https://forums.docker.com/t/help-with-entrypoint-calling-script/84292>\
**Category:** General\
**Tags:** docker\
**Created:** [November 14, 2019, 6:18am UTC](https://forums.docker.com/t/help-with-entrypoint-calling-script/84292 "2019-11-14T06:18:21Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![dockersubtest](https://sea3.discourse-cdn.com/docker/user_avatar/forums.docker.com/dockersubtest/32/32505_2.png) [@dockersubtest](https://forums.docker.com/u/dockersubtest)\
**Post date:** [November 14, 2019, 6:18am UTC](https://forums.docker.com/t/help-with-entrypoint-calling-script/84292/1 "2019-11-14T06:18:21Z")

</div>

The [dockerfile](https://github.com/Firedrops/qimr_mtb/blob/master/Slim/Dockerfile).  
The docker builds and runs fine. Currently, I run and attach into the docker, and manually send the command:  
`./pipe.sh /data/ RB17MT1804 /data/H37Rv_refe /data/temp /data/out`.

However, I have heard that this can be passed into the docker run command itself, of which I have concocted this:

```auto
docker run -it --rm -v /Backup/Data/:/data/ qimr_slim /data/ RB17MT1804 /data/H37Rv_refe /data/temp /data/out

```

which works with  
`ENTRYPOINT ["pipe.sh"]`  
in the dockerfile.

However, this results in this error:

```auto
docker: Error response from daemon: OCI runtime create failed: container_linux.go:348: starting container process cause"exec: \"pipe.sh\": executable file not found in $PATH": unknown.

```

To check whether the container built properly, I have entered it again via  
`docker run -it --entrypoint /bin/bash qimr_slim`  
which has no problems, and the script also runs without any problems as the format above, so this means the script, dependencies, and permissions are not a problem.

Can anyone tell where I’m going wrong with this docker usage?

---

<div class="post-metadata">

**Author:** ![tekki](https://sea3.discourse-cdn.com/docker/user_avatar/forums.docker.com/tekki/32/21884_2.png) [@tekki](https://forums.docker.com/u/tekki)\
**Post date:** [November 14, 2019, 10:17am UTC](https://forums.docker.com/t/help-with-entrypoint-calling-script/84292/2 "2019-11-14T10:17:14Z")

</div>

> [@dockersubtest](#):
>
> ```auto
> docker: Error response from daemon: OCI runtime create failed: container_linux.go:348: starting container process cause"exec: \"pipe.sh\": executable file not found in $PATH": unknown.
> 
> ```

`pipe.sh` is not in a folder listed in `$PATH`, so it is not executed. You should copy it to one of these folders, for example to `/usr/local/bin`.  
You would get the same error in the bash console if you wouldn’t type `./pipe.sh` with dot-slash.

---

<div class="post-metadata">

**Author:** ![dockersubtest](https://sea3.discourse-cdn.com/docker/user_avatar/forums.docker.com/dockersubtest/32/32505_2.png) [@dockersubtest](https://forums.docker.com/u/dockersubtest)\
**Post date:** [November 14, 2019, 10:38pm UTC](https://forums.docker.com/t/help-with-entrypoint-calling-script/84292/3 "2019-11-14T22:38:51Z")

</div>

thanks!  
alternatively, would replacing  
`ENTRYPOINT ["pipe.sh"]`  
with  
`ENTRYPOINT ["./pipe.sh"]`  
in the Dockerfile also work?

UPDATE: Yes it does 😃

---

<div class="post-metadata">

**Author:** ![dockersubtest](https://sea3.discourse-cdn.com/docker/user_avatar/forums.docker.com/dockersubtest/32/32505_2.png) [@dockersubtest](https://forums.docker.com/u/dockersubtest)\
**Post date:** [November 15, 2019, 11:40am UTC](https://forums.docker.com/t/help-with-entrypoint-calling-script/84292/4 "2019-11-15T11:40:56Z")

</div>

It mysteriously stopped working a few hours later… in my 2nd attempt, I’ve tried both  
`ENTRYPOINT ["./pipe.sh"]`  
and  
copying it into `/usr/local/bin`.  
As before the [dockerfile is here](https://github.com/Firedrops/qimr_mtb/blob/master/Slim/Dockerfile), where I actually do both of the solutions and try `docker run` parameters, and so far have got nothing to work.  
the error message is now mostly

```auto
standard_init_linux.go:190: exec user process caused "exec format error"

```

does anynoe know what’s wrong now?

Nevermind, found some new complications, moving to new thread.
