1
0
Fork 0
mirror of https://github.com/capistrano/capistrano synced 2023-03-27 23:21:18 -04:00
capistrano/docs/documentation/advanced-features/ignoring/index.markdown
2017-09-17 21:39:45 +02:00

967 B

title layout
Ignoring default

Files committed to version control (i.e. not in .gitignore) can still be ignored when deploying. To ignore these files or directories, simply add them to .gitattributes:

config/deploy/deploy.rb   export-ignore
config/deploy/            export-ignore

These files will be kept in version control but not deployed to the server.

Note: This feature is probably unnecessary unless the root of your repository is also your web server's docroot. For example, in a Rails application, the docroot is the public/ folder. Since all of the Capistrano configuration lives above or beside this folder, it cannot be served and is not a security risk. If the docroot is indeed at the base of the repository, consider changing that by moving the code at the repository base to a subdirectory such as public_html instead of using this feature. Note that this feature is very specific to Git and will not work on other SCMs.