.dockerignore
(Redirected from Dockerignore)
Jump to navigation
Jump to search
The .dockerignore file allows you to exclude files from the context like a .gitignore file allow you to exclude files from your git repository. You can use it to help avoid unnecessarily sending large or sensitive files and directories to the docker daemon.
Example[edit]
# More info: https://docs.docker.com/engine/reference/builder/#dockerignore-file # Ignore everything by default and re-include only needed files ** # Re-include Go source files (but not *_test.go) !**/*.go **/*_test.go # Re-include Go module files !go.mod !go.sum
Related terms[edit]
docker-composedocker build.gitignorefile.terraformignore=> => transferring context: 2B
See also[edit]
Advertising: