Repository navigation
TF State old schema dashboard replacement - #545
Merged
Merged
Conversation
…r new provider schema
mattwin1
requested review from
a team,
MuhammadJawad-Mastek,
Raj29-Mastek and
jaibheem22
as code owners
September 24, 2026 09:29
Contributor
✅ Snyk checks have passed. No issues have been found so far.
💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse. |
Raj29-Mastek
approved these changes
Sep 24, 2026
MuhammadJawad-Mastek
approved these changes
Sep 24, 2026
MuhammadJawad-Mastek
left a comment
Collaborator
There was a problem hiding this comment.
Looking good to merge.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request significantly enhances the
Deployment/terraform_conditional_run.ps1script by introducing robust handling for legacy Azure Dashboard state migration, improving error handling and output clarity, and restructuring the script for better maintainability and readability. The changes ensure that deployments involving the transition fromazurerm_dashboardtoazurerm_portal_dashboardare handled safely and automatically, with clear checks and messaging throughout the process.Azure Dashboard State Migration:
azurerm_dashboardresource from Terraform state if present, ensuring compatibility with AzureRM v4 and preventing accidental deletion of the actual Azure Dashboard resource. The script now checks for both legacy and new dashboard resources and handles all possible migration states with clear output and error handling.Script Structure and Error Handling:
Write-Outputmessages, added section headers for clarity, and improved error handling after each critical Terraform command (init,workspace select,validate,plan,apply).Terraform Plan and Apply Enhancements:
Output Handling:
These changes collectively make the deployment process safer, more transparent, and easier to maintain.…r new provider schema