What happens to entrypoint of Docker parent image when child defines another one?

Let’s say I’ve got the Docker image parent built by this Dockerfile:

FROM ubuntu
ENTRYPOINT ["parent-entry"]

Now I inherit from this parent image in my child image built with this code:

  • What's the best way to compose multiple Docker images with different bases
  • Docker Registry - read-only mode
  • create-react-app + docker = QA and PROD Deploy
  • Running node and nginx in docker with supervisor
  • Docker Error Pulling Images in Ubuntu
  • How to attach to a demonized container in docker
  • FROM parent
    ENTRYPOINT ["child-entry"]
    

    As far as I have tested it the entrypoint of the child image overwrites the one in the parent image.

    But since I am new to Docker I am not sure about this. My research also hasn’t yet resulted in a satisfying answer. So is the assumption above correct?

  • docker memory-swap=-1 OOM
  • Use private image from Google Container Registry as base image in Dockerfile
  • I am getting an error when i am trying to build my Docker postgres image
  • How can I find out what is contained in a saved Docker image tar file?
  • Issues in elasticsearch server running in docker
  • I just installed docker, but running “hello world” failed, it doesn't download image?
  • One Solution collect form web for “What happens to entrypoint of Docker parent image when child defines another one?”

    The last entrypoint is used, only the last one.

    You can check, put several lines with different ENTRYPOINT in your Dockerfile, and check what happens.

    Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.