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

Unable to deploy Fusion and Microsoft Security type Sentinel MS Security Incident Alert Rules with 3.34.0 #19587

Open
1 task done
PCNZ opened this issue Dec 7, 2022 · 2 comments

Comments

@PCNZ
Copy link

PCNZ commented Dec 7, 2022

Is there an existing issue for this?

  • I have searched the existing issues

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

Terraform Version

1.3.2

AzureRM Provider Version

3.34.0

Affected Resource(s)/Data Source(s)

azurerm_sentinel_alert_rule_ms_security_incident

Terraform Configuration Files

terraform {
  required_providers {
    azurerm = {
      source = "hashicorp/azurerm"
    }
  }
  backend "azurerm" {
  }
}

Debug Output/Panic Output

Error: setting ResourceData for Sentinel Alert Rule Template "Advanced Multistage Attack Detection" (Workspace "xxxxxxxxxxxxxxxxxxxxxx" / Resource Group "xxxxxxxxxxxxxxxxx") ID
2022-12-07T02:22:54.1033107Z 
2022-12-07T02:22:54.1033748Z   with module.sentinel_analytics.module.sentinel_fusion_analytics["Advanced Multistage Attack Detection"].data.azurerm_sentinel_alert_rule_template.alert_rule_template,
2022-12-07T02:22:54.1034651Z   on analytics/fusion/alert_rule_fusion.tf line 10, in data "azurerm_sentinel_alert_rule_template" "alert_rule_template":
2022-12-07T02:22:54.1035310Z   10: data "azurerm_sentinel_alert_rule_template" "alert_rule_template" {

Expected Behaviour

No response

Actual Behaviour

No response

Steps to Reproduce

Deploy using this (no version specified - defaults to lastest)

terraform {
required_providers {
azurerm = {
source = "hashicorp/azurerm"
}
}
backend "azurerm" {
}
}

To workaround hard set the version to 3.33.0 and the deploy works
terraform {
required_providers {
azurerm = {
source = "hashicorp/azurerm"
version = "3.33.0"
}
}
backend "azurerm" {
}
}

Important Factoids

No response

References

https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/resources/sentinel_alert_rule_ms_security_incident

@PCNZ PCNZ added the bug label Dec 7, 2022
@github-actions github-actions bot removed the bug label Dec 7, 2022
@magodo
Copy link
Collaborator

magodo commented Dec 7, 2022

@PCNZ Thank you for raising this and sorry you ran into trouble here.

The issue is introduced by #19487. @mbfrahry The azurerm_sentinel_alert_rule_template is a data source, where we will parse the id that directly from Azure, rather than from what we construct ourselves. So in this case I think we shall keep the casing as is returned by Azure, especially for the alert rule template, the resource type segment is AlertRuleTemplates rather than alertRuleTemplates. Do you think we shall just revert the change in #19487 for the alert rule template part only? If yes, then I'll be happy to submit a PR for that.

@jkyamog
Copy link

jkyamog commented Dec 20, 2022

@magodo Hi! I work with Pete. Let me see if I can explain a bit further some context:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants