Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Management Group Diagnostic Settings recreated every deployment #1170

Closed
robsissons-contino opened this issue Oct 22, 2024 · 0 comments · Fixed by #1201
Closed

Management Group Diagnostic Settings recreated every deployment #1170

robsissons-contino opened this issue Oct 22, 2024 · 0 comments · Fixed by #1201
Assignees

Comments

@robsissons-contino
Copy link
Contributor

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Versions

terraform: 1.9.5

azure provider: 3.116.0

module: 6.1.0

Description

Describe the bug

diagnostic settings deployed for management groups as part of the core module, using the variable "deploy_diagnostics_for_mg" are constantly destroyed and recreated.

Often the recreation of these resources will fail causing the pipeline to fail and requiring another deployment to resolve.

Steps to Reproduce

  1. Deploy CORE module with the "deploy_diagnostics_for_mg" variable set to true
  2. push an update
  3. plan / apply will remove and attempt to recreate the resources
  4. Often the recreation will fail due no sleep between actions

Screenshots

Image

Image

Additional context

This appears to be related to a long outstanding issue with the location field on diagnostic settings which are created through azapi -

Azure/terraform-provider-azapi#511

A possible solution/workaround appears to be to set a location ('global') for the resource to avoid the recreation ?

@robsissons-contino robsissons-contino changed the title Bug Report Management Group Diagnostic Settings recreated every deployment Oct 22, 2024
@matt-FFFFFF matt-FFFFFF linked a pull request Nov 13, 2024 that will close this issue
5 tasks
@matt-FFFFFF matt-FFFFFF self-assigned this Nov 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants