.deployignore file is an optional file that lists filenames and patterns
that should be ignored during a
This is useful if you're using additional tools in your development environment,
which for example rely on things like
node_modules for building/testing/etc.,
.log files and other temporary files which are not essential for
your application to function in production.
These can be added to a file called
.deployignore in the root directory of
your Sail project.
One entry per line, comments start with a
#, simple patterns are supported,
!. Below are a few examples:
Ignore files named
debug.log, in any directory or subdirectory:
.log files anywhere in your project:
Ignore all log files, except ones called
Ignore an entire directory (even if it's in a subdirectory itself):
readme.html file but only in the root project directory:
So this will still deploy
wp-content/plugins/foo/readme.html for example.
Ignored files and directories will not appear in
sail diff or
sail deploy --dry-run,
so they will likely not trigger pre-deploy hooks as well.
Dot-files (filenames and directories that begin with a
., such as
are ignored regardless of what's in your
.deployignore, so naturally, the
.deployignore file itself will also not be shipped to production.
If you have any questions or feedback about deploying with Sail CLI, check out the getting help section.