Options

Deployment Agent does not clean up temp folder

OrangeBeanOrangeBean Posts: 8
edited February 2, 2014 6:35PM in Deployment Manager
Hi,

We are using DeploymentManager on a set of servers for different deployments.

In one of the cases the problem of not cleaning up Temp folder by DeploymentAgent becomes a showstopper.

A little bit of details. There is a database server. Server hosts 2 databases that are subject for deployment. One database is redeployed using nupack generated by RedGate SQL Server plugin for TeamCity. Another database is updated by 2 custom made nupacks. All 3 packages belong to 3 different Projects. All projects have different set of variables defined. RedGate nupack contains PreDeploy.ps1. 2 custom nupacks contain Deploy.ps1. Because the Temp folder is not cleaned up by the Agent there are always mix of the packages there and they fail as DeploymentManager tries to run PreDeploy.ps1 then Deploy.ps1 which in fact belong to 2 different packages and expect different variables.

Any advice on how to clean Temp folder before or after deployment?

Comments

  • Options
    Answering my own question. :)

    PPL please read the doco first :oops:

    there is answer to my question right here:http://documentation.red-gate.com/display/DM2/Variables

    To stop polluting system temp folder (and control free disk space) on the agent machine someone can define variable RedGatePackageDirectoryPath to point to some custom temp location. That is what we did and faced the problem described in original post.
    To address clean up issue in custom temp there is another variable: RedGatePurgePackageDirectoryBeforeCopy. Set it to True and agent will clean the folder before copying files into it.
Sign In or Register to comment.