QuestionQ21Verified/Container VirtualizationCopy linkReport a problemAsk AstroTutorSave questionWhat is the purpose of a .dockerignore file?AIt lists files existing in a Docker image which should be excluded when building a derivative image.BIt specifies files that Docker does not submit to the Docker daemon when building a Docker imageCIt exists in the root file system of containers that should ignore volumes and ports provided by Docker.DIt must be placed in the top level directory of volumes that Docker should never attach automatically to a container.EIt specifies which parts of a Dockerfile should be ignored when building a Docker image.Show AnswerAnswerExplanationA .dockerignore file excludes matching files and directories from the Docker build context, preventing them from being sent to the builder during an image build.Learn moreBuild context | Docker DocsShow comments0Show commentsCommunity DiscussionNo comments yet. Be the first to start the discussion!
Community Discussion