Terminate Suspended Instances (Dev only) - BTDF/DeploymentFramework GitHub Wiki

Wiki: Home > Tips and Tricks

Requirement

I want to automatically terminate instances on deployment, but only in development environments.

Solution

If you are deploying using the MSI, then you are using the Configuration==Server. However, in development Visual Studio will use the configuration != Server.

As such, add the following in bold to the Deployment.btdfproj file:

<AutoTerminateInstances>'$(Configuration)' != 'Server'</AutoTerminateInstances>