Using Visual Studio Team Service’s automated build system empowers projects with simplified and powerful automation for build, test, and deploying projects in the cloud. However, before the introduction of the Release Manager features, it was difficult to manage releases, as packages and projects often validated code branches for release or promotion, instead of binary packages. With the introduction of Release Manager, build and deploy steps can be separated and a particular build artifact can be promoted across multiple environments.Unfortunately, configuring these environments outside of the codebase was difficult, often leading to:
- Configuration files with passwords and other critical configuration residing in source control, or
- Using a secondary deployment or build system (such as Octopus) that can control environmental configuration
Release Manager 3.0 (preview)
Now with Release Manager 3.0, currently in preview, VS-TS allows the creation of secure Variable Groups that can be used with configuration transformation to properly configure a package for deployment. Let’s take a quick look at the solution:
Inside of Visual Studio – Team Services you can create, secure, and manage Variable Groups that can be applied to release environment definitions. A variable group can contain standard or private variables (think passwords) and a variable group can be assigned Access Control based on role. Private Variables are encrypted after saving and are non-retrievable in the UI. This should allow Production configuration to be reusable but not visible to roles that should not have access to those details. It will also allow re-usability of these variables across multiple projects or release setups.
Inside of an Environment Configuration for a release, Variable Groups can be assigned for use. Thus they can be managed completely independently.
There are three levels of variable scope-
- Variable Groups – Have scope across the entire project (managed in the library)
- Release Variables – Have scope across the entire release (managed in the release definition)
- Environment Variables – Have scope across all tasks in a release
Now with Release Manager 3.0, you can use Variables (and thus Variable Groups) to transform configurations whether they be XML or JSON. The variable names need to named in such a way to properly apply to the transformation, but this will allow the environment configuration for a release to be completely removed from the creation of the release promotion configuration process, making it more manageable and secure.