Skip to content

Glossary: Docker Basics

.dockerignore

Also written: dockerignore

A file in the build context listing what to leave out of the build, using the same patterns as `.gitignore`. It keeps secrets like `.env` and junk out of the image.

Where the book teaches it

Related terms

Build context.gitignoreSecret