question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

When running make tre-deploy in succession terraform updates/replaces resources that have not changed.

See original GitHub issue

Describe the bug Each time run make tre-deploy terraform updates/replaces resources unnecessarily.

Steps to reproduce

  1. Deploy TRE with make
  2. Re run `‘make tre-deploy’ and monitor terraform output.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:7 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
marrobicommented, Jan 18, 2022

Here’s an occurrence:

module.resource_processor_vmss_porter[0].azurerm_role_assignment.subscription_owner must be replaced
-/+ resource "azurerm_role_assignment" "subscription_owner" ***
      ~ id                               = "/subscriptions/***/providers/Microsoft.Authorization/roleAssignments/deb370d9-e9c0-6ede-a44b-1f1ee3d2146d" -> (known after apply)
      ~ name                             = "deb370d9-e9c0-6ede-a44b-1f1ee3d2146d" -> (known after apply)
      ~ principal_type                   = "ServicePrincipal" -> (known after apply)
      ~ role_definition_id               = "/subscriptions/***/providers/Microsoft.Authorization/roleDefinitions/8e3af657-a8ff-443c-a75c-2fe8c4bcb635" -> (known after apply)
      ~ scope                            = "/subscriptions/***" -> (known after apply) # forces replacement
      + skip_service_principal_aad_check = (known after apply)
        # (2 unchanged attributes hidden)
    ***
0reactions
tanya-borisovacommented, Jan 26, 2022

I’m going to close this as the remaining work is tracked in https://github.com/microsoft/AzureTRE/issues/1161

Read more comments on GitHub >

github_iconTop Results From Across the Web

Update/replace resource when a dependency is changed #8099
In Terraform's design, a dependency edge (which is what depends_on creates explicitly) is used only for ordering operations. So in the very ...
Read more >
Zero Downtime Updates with HashiCorp Terraform
In this post, we are going to look at two simple features in Terraform that allow us to avoid downtime caused by updates...
Read more >
Terraform Apply? When External Change Happens.
When a plan file is passed to apply , Terraform does not perform a refresh. This means that changes made to managed resources...
Read more >
Continuous Infrastructure Deployment with Terraform Cloud
This policy, which is applied to a plan output via the tfplan/v2 import, filters through all resource changes for actions that are “create”...
Read more >
SweetOps #terraform for April, 2022
Are you running terraform from this directory or from the ... to force a replacing update on a resource when there are changes...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found