Skip to content

Commit 9d7d259

Browse files
committed
some code refactor
1 parent 1fe210e commit 9d7d259

File tree

3 files changed

+2
-4
lines changed

3 files changed

+2
-4
lines changed

infrastructure/modules/policy/policy-definition/main.tf

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
resource "azurerm_policy_definition" "item" {
1+
resource "azurerm_policy_definition" "definition" {
22
name = var.name
33
policy_type = coalesce(var.policy_type, "custom")
44
mode = coalesce(var.mode, "all")
@@ -17,4 +17,3 @@ resource "azurerm_policy_definition" "item" {
1717
locals {
1818
requires_identity = contains(["deployIfNotExists", "modify", "append"], var.policy_rule.then.effect)
1919
}
20-

infrastructure/modules/policy/policy-definition/outputs.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
output "policy_definition_id" {
2-
value = azurerm_policy_definition.item.id
2+
value = azurerm_policy_definition.definition.id
33
description = "The ID of the created policy definition."
44
}
55

infrastructure/modules/policy/policy-definition/variables.tf

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
21
variable "name" {
32
type = string
43
description = "Policy definition name."

0 commit comments

Comments
 (0)