{"action":"opened","issue":{"url":"https://api.github.com/repos/docker/docker/issues/13352","labels_url":"https://api.github.com/repos/docker/docker/issues/13352/labels{/name}","comments_url":"https://api.github.com/repos/docker/docker/issues/13352/comments","events_url":"https://api.github.com/repos/docker/docker/issues/13352/events","html_url":"https://github.com/docker/docker/issues/13352","id":78502834,"number":13352,"title":"Question: Why does Dockerfile support multiple FROM entries?","user":{"login":"luebken","id":53055,"avatar_url":"https://avatars.githubusercontent.com/u/53055?v=3","gravatar_id":"","url":"https://api.github.com/users/luebken","html_url":"https://github.com/luebken","followers_url":"https://api.github.com/users/luebken/followers","following_url":"https://api.github.com/users/luebken/following{/other_user}","gists_url":"https://api.github.com/users/luebken/gists{/gist_id}","starred_url":"https://api.github.com/users/luebken/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/luebken/subscriptions","organizations_url":"https://api.github.com/users/luebken/orgs","repos_url":"https://api.github.com/users/luebken/repos","events_url":"https://api.github.com/users/luebken/events{/privacy}","received_events_url":"https://api.github.com/users/luebken/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-05-20T12:23:24Z","updated_at":"2015-05-20T12:23:24Z","closed_at":null,"body":"While reading the docs I've stumbled upon: \r\n> FROM can appear multiple times within a single Dockerfile in order to create multiple images. Simply make a note of the last image ID output by the commit before each new FROM command.\r\nhttps://docs.docker.com/reference/builder/#from\r\n\r\nI've tested this via:\r\n```\r\nFROM busybox:ubuntu-14.04\r\nENTRYPOINT [\"echo\", \"from1\"]\r\n\r\nFROM debian:latest\r\nENTRYPOINT [\"echo\", \"from2\"]\r\n```\r\n```\r\n$ docker run deaee2cc56ed\r\nfrom1\r\n$ docker run 93b41e538f02\r\nfrom2\r\n```\r\n\r\nThis example is particular interesting since the docs say:\r\n> Only the last ENTRYPOINT instruction in the Dockerfile will have an effect.\r\nhttps://docs.docker.com/reference/builder/#entrypoint\r\n\r\nSo I am wandering why are multiple FROMs allowed? What are the use-cases? "}}