Here is a simple dockerfile
FROM centos:6.6 ENTRYPOINT ["/bin/bash", "-l", "-c"] CMD ["echo", "foo"]
Unfortunately this will not work. Nothing happens when you start the created container that was built.
If you comment out ENTRYPOINT then it will work. However, if you set the ENTRYPOINT parameter to /bin/sh -c , it does not work again
FROM centos:6.6 ENTRYPOINT ["/bin/sh", "-c"] CMD ["echo", "foo"]
I thought it was the standard ENTRYPOINT for a container that didn't have a specific one, why doesn't it work?
Finally, it also works.
FROM centos:6.6 ENTRYPOINT ["/bin/bash", "-l", "-c"] CMD ["echo foo"]
Before I post a question, I wanted to see if I am doing something clearly wrong?
I use rvm inside my container, which requires the login shell to work properly.
source share