docs: updates Terraform init example - #872
Conversation
There was a problem hiding this comment.
Pull request overview
Updates the Azure Terraform integration guide to reflect newer Terraform provider requirements, aiming to keep the example working with azurerm provider 5.x.
Changes:
- Bumps the
azurermprovider version used in the example configuration. - Adds an explicit
randomprovider requirement for therandom_uuidresource. - Reorders/standardizes the
azurermprovider configuration fields (includingmetadata_host).
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
| azurerm = { | ||
| source = "hashicorp/azurerm" | ||
| version = "=4.14.0" | ||
| version = "5.1.0" | ||
| } |
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
|
Hello @ksatirli, thank you for your contribution! :) I'll make sure the team takes a look. |
|
Hola @localstack/smurf @lazarkanelov, adding your folks for ENG review, this is a community contribution we just received this week. |
|
Hi @ksatirli, thanks a lot for the contribution! 🙌 I verified your updated example end-to-end against the latest emulator build (localstack/localstack-azure:latest): terraform init resolves azurerm 5.1.0 + random 3.9.0 cleanly, apply creates the resource group as expected, and destroy works too. The bump makes sense. That said, we still need make sure the emulator's test suites and all sample apps are bumped to 5.1.0 so the docs don't run ahead of what we validate in CI. We'll keep this PR open and merge it as part of that upgrade. One tiny nit in the meantime: the two version constraints use different styles ("5.1.0" vs "= 3.9.0") — mind aligning them (e.g. both as "5.1.0" / "3.9.0")? Thanks again — this kind of contribution is much appreciated! 🚀 |
Hey @ksatirli, good question! We have a strong preference for an exact pin here. The reason is emulator-specific: we validate the LocalStack Azure emulator against a specific provider version, and azurerm minor releases regularly change wire-level behavior in ways that matter to an emulator even when they're invisible against real Azure. With a range like >= 5.1.0, < 6.0.0, the docs example can break overnight when HashiCorp releases 5.2 — and the reader can't tell whether they broke something or we did. With an exact pin, the example always reflects a combination we've actually tested, and we bump it deliberately. So: exact pin on both blocks please, in the repo's usual style — version = "=5.1.0" version = "=3.9.0" |
Hey @localstack-bot!
Figured I'd update the TF example to make it work with 5.x of the
azurermprovider :)