From the course: Deploying .NET Applications with Octopus Deploy

Unlock this course with a free trial

Join today to access over 22,400 courses taught by industry experts.

Variable substitutions

Variable substitutions

- [Instructor] One of the most powerful parts of Octopus Deploy is the ability to easily apply variable substitutions when a release is being deployed. You can replace an app setting or connection string with the value of an Octopus variable simply by naming them the same. For example, if I wanted to replace a connection string name MyConnection in my web.config file, I would create an Octopus variable named MyConnection. If enabled, Octopus will see that the variable name matches the connection string name and substitute the value. Many .net applications use config transforms to alter configuration between environments. Octopus Deploy can be configured to apply config transforms in many ways. It can be as simple as always using the Release transform or as complicated as picking the transform based on another variable. If you store your configuration in a JSON format, you can name your variable using the path to the JSON name value pair you want to update. For example, if your…

Contents