We've just deployed an enhancement to the zero-downtime features in DeployHQ - the ability to choose from two "strategies" when deploying. This feature can be found when first configuring a new server with zero-downtime deployments enabled:
And at present, is not supported as a changeable option when editing an existing server with zero-downtime enabled.
The strategies will work like so:
Copy previous release before uploading changes to new release
During each deployment, the last release directory will be copied to a new release directory, and all changes will be uploaded directly there. The current symlink will then be switched to the new release folder.
This means that any changes you make to the release directory outside of the deployment process will be copied over.
This strategy is the default that we've always provided.
Upload changes to a cache directory and copy new release from there
During each deployment, a cache directory that contains a clean copy of your repository only will be updated with the latest changes from the deployment. This will then be copied across to a new release folder before the current symlink is switched.
This means that any changes you make to the release directory outside of the deployment will not be copied over.