From b6fb9888647a18960c12a8be3935870f39ff5b42 Mon Sep 17 00:00:00 2001 From: Patrick Picard Date: Wed, 22 Jul 2020 09:51:51 -0400 Subject: [PATCH] Fixed passing in the list of supported services Added the missing encoding --- .../policies/builtin/allowed_resource_type.tf | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/landingzones/landingzone_caf_foundations/blueprint_foundations_governance/policies/builtin/allowed_resource_type.tf b/landingzones/landingzone_caf_foundations/blueprint_foundations_governance/policies/builtin/allowed_resource_type.tf index 325fae87d..ad7b572eb 100644 --- a/landingzones/landingzone_caf_foundations/blueprint_foundations_governance/policies/builtin/allowed_resource_type.tf +++ b/landingzones/landingzone_caf_foundations/blueprint_foundations_governance/policies/builtin/allowed_resource_type.tf @@ -1,6 +1,10 @@ #Definition ID: /providers/Microsoft.Authorization/policyDefinitions/a08ec900-254a-4555-9bf5-e42af04b5c5c #Name: Allowed resource types +locals { + supported_svc = "${jsonencode(var.policies_matrix.list_of_supported_svc)}" +} + resource "azurerm_policy_assignment" "res_type" { count = var.policies_matrix.restrict_supported_svc ? 1 : 0 name = "res_svc" @@ -12,10 +16,8 @@ resource "azurerm_policy_assignment" "res_type" { parameters = <