Skip to content

[User Guide] Module upgrade guidance

github-actions edited this page Jun 18, 2024 · 11 revisions

Staying up to date

Deploying the latest version of the module is the recommended approach for staying up to date with the latest architectural changes to Azure landing zones. Looking at it from a governance perspective, this also ensures you have the latest recommended policies applied to your environment for improved compliance.

With each release of the module, it's possible that your environment will change. We will do our best to ensure any changes are clearly documented in the release notes, or upgrade guides when publishing a new major version. To avoid unexpected or unwanted changes we recommend that you configure your version constraints to pin to a specific module version.

To do this, you would use the following version constraint syntax:

module "enterprise_scale" {
  source  = "Azure/caf-enterprise-scale/azurerm"
  version = "<version>" # change this to your desired version, https://www.terraform.io/language/expressions/version-constraints

  # Insert provider block and input variables here
}

NOTE: This is the format we use in all of our documentation.

To allow automatic upgrades to the latest patch release, use the following version constraint syntax:

module "enterprise_scale" {
  source  = "Azure/caf-enterprise-scale/azurerm"
  version = "~> 3.1.2"

  # Insert provider block and input variables here
}

This should ensure you receive the latest fixes for the module, reducing the risk of unexpected behavior.

NOTE: To reduce the risk of failed plans, we do not recommend using a less restrictive version constraint when deploying using CI/CD pipelines.

When planning an upgrade, please take care to review both the release notes and upgrade guides where applicable.

As a general rule, we will only document an upgrade guide when publishing a new major release, and this will be written on the assumption that you plan to upgrade from the most recent version of the previous release, to the first new release. For example, from release v1.1.4 to release v2.0.0. If jumping multiple release versions, take care to note additional changes documented in the release notes of all iterative releases.

Upgrade guides

Please refer to the following upgrade guides when updating between major release:

Clone this wiki locally