⬅️ Docker 🔗 Stack Overflow
-
Docker has a default entrypoint which is
/bin/sh -cbut does not have a default command. -
When you run docker like this:
docker run -i -t ubuntu bashthe entrypoint is the default/bin/sh -c, the image isubuntuand the command isbash -
the
ENTRYPOINTspecifies a command that will always be executed when the container starts. -
The
CMDspecifies arguments that will be fed to theENTRYPOINT