I would like an option for builds (deployments) not to trigger upstream snapshot dependencies even when new changes are available, but to progress existing build pipelines from the same chain as the default option (i.e. without having to select the exect dependency on the Dependency tab of the Run Custom Build dialog).
I have looked at the various options provided by TeamCity but I can't find a solution to this problem.
Here's a model of a delivery pipeline:
[compile] -> [unit test] -> [package] -> [deploy dev] -> [deploy qc] -> [deploy uat]
Currently if a user triggers the [deploy uat] to deploy the same version/revision of the [package] deployed on [deploy qc] this will work provided there are no pending changes checked anywhere since [deploy qc] was deployed.
If instead pending changes are available for the [compile] build, the whole pipeline, including [deploy dev] and [deploy qc] will be run when [deploy uat] is triggered.
The reasons to want this is:
- My deployment task could be dependent on another deployment task, I don't want the upstream deployments to be triggered as this could cause all sort of trouble (e.g. the environment being deployed might be in use)
- When deployments are triggered manually, users may click on "Run" rather than "…" and fail to select appropriate dependencies, potentially triggering a cascade of builds that would choke the build agents for no real purpose (we have over 100 builds in some of our chains).
One workaround I have put in place to prevent (auto) deployments is to prompt users with a warning to select the dependent build by using a parameter, but this is not fool proof.
Another alternative is to educate users to use Promote instead, however there are drawbacks:
- Can be difficult to locate the right dependent on the Promote build dialog if many builds are present
- Permissions don't seem to cover the scenario where someone is only allowed to run the [deploy uat] build but nothing else. If they go the [deploy qc] build they will not have the option to promote the build.
The other workaround I can think of is of course not have snapshot dependencies for my deployments, but that will limit us by:
- Removing the ability to visualize deployment build & deployment pipelines
- Not being able to easily use dependent properties
- Unable to see the changes from upstream dependencies
Does anyone know if what I want to do is possible with the latest version of TeamCity (we are currently using 8.0.5)?