I have a Docker image with conditions that have a few custom libs compiled and installed for automating tests. It has /bin/bash
as its ENTRYPOINT
, so a docker container created by docker run
does not immediately exit.
However, when I run it on Travis CI, it dies after a few seconds:
# .travis.yml
... (omit language, os, etc) blah
install:
- docker pull <dockerhub link>
- docker run -td <dockerhub addr>
- docker ps
- sleep 15
- docker ps
The first docker ps
shows that the created container is up for a few seconds. However, the second docker ps
shows nothing; during the 15 seconds, something happened to the container. Same if I run docker ps -A
When the commands are run on my local computer, I can observe that it is kept alive.
Why is my Docker container being killed? Any help would be appreciated!