@@ -593,11 +593,7 @@ variable "custom_role_definitions_terraform" {
593593 - `actions` (list(string)) - Allowed Azure actions
594594 - `not_actions` (list(string)) - Denied Azure actions
595595
596- Default includes 4 predefined roles:
597- - `alz_management_group_contributor` - Manage management group hierarchy and governance
598- - `alz_management_group_reader` - Read management group structure and validate deployments
599- - `alz_subscription_owner` - Full access to platform subscriptions
600- - `alz_subscription_reader` - Read/write access for platform subscription resources
596+ Default is empty, meaning no custom roles are created.
601597
602598 See default value for complete role action definitions.
603599 EOT
@@ -609,89 +605,7 @@ variable "custom_role_definitions_terraform" {
609605 not_actions = list (string )
610606 })
611607 }))
612- default = {
613- alz_management_group_contributor = {
614- name = " Azure Landing Zones Management Group Contributor ({{service_name}}-{{environment_name}})"
615- description = " This is a custom role created by the Azure Landing Zones Accelerator for Writing the Management Group Structure."
616- permissions = {
617- actions = [
618- " Microsoft.Management/managementGroups/delete" ,
619- " Microsoft.Management/managementGroups/read" ,
620- " Microsoft.Management/managementGroups/subscriptions/delete" ,
621- " Microsoft.Management/managementGroups/subscriptions/write" ,
622- " Microsoft.Management/managementGroups/settings/read" ,
623- " Microsoft.Management/managementGroups/settings/write" ,
624- " Microsoft.Management/managementGroups/settings/delete" ,
625- " Microsoft.Management/managementGroups/write" ,
626- " Microsoft.Management/managementGroups/subscriptions/read" ,
627- " Microsoft.Authorization/policyDefinitions/write" ,
628- " Microsoft.Authorization/policySetDefinitions/write" ,
629- " Microsoft.Authorization/policyAssignments/write" ,
630- " Microsoft.Authorization/roleDefinitions/write" ,
631- " Microsoft.Authorization/*/read" ,
632- " Microsoft.Authorization/roleAssignments/write" ,
633- " Microsoft.Authorization/roleAssignments/delete" ,
634- " Microsoft.Insights/diagnosticSettings/write"
635- ]
636- not_actions = []
637- }
638- }
639- alz_management_group_reader = {
640- name = " Azure Landing Zones Management Group Reader ({{service_name}}-{{environment_name}})"
641- description = " This is a custom role created by the Azure Landing Zones Accelerator for Reading the Management Group Structure."
642- permissions = {
643- actions = [
644- " Microsoft.Management/managementGroups/read" ,
645- " Microsoft.Management/managementGroups/subscriptions/read" ,
646- " Microsoft.Management/managementGroups/settings/read" ,
647- " Microsoft.Authorization/*/read" ,
648- " Microsoft.Authorization/policyDefinitions/write" ,
649- " Microsoft.Authorization/policySetDefinitions/write" ,
650- " Microsoft.Authorization/roleDefinitions/write" ,
651- " Microsoft.Authorization/policyAssignments/write" ,
652- " Microsoft.Insights/diagnosticSettings/write" ,
653- " Microsoft.Insights/diagnosticSettings/read" ,
654- " Microsoft.Resources/deployments/whatIf/action" ,
655- " Microsoft.Resources/deployments/write" ,
656- " Microsoft.Resources/deploymentStacks/read" ,
657- " Microsoft.Resources/deploymentStacks/validate/action"
658- ]
659- not_actions = []
660- }
661- }
662- alz_subscription_owner = {
663- name = " Azure Landing Zones Subscription Owner ({{service_name}}-{{environment_name}})"
664- description = " This is a custom role created by the Azure Landing Zones Accelerator for Writing in platform subscriptions."
665- permissions = {
666- actions = [
667- " *"
668- ]
669- not_actions = []
670- }
671- }
672- alz_subscription_reader = {
673- name = " Azure Landing Zones Subscription Reader ({{service_name}}-{{environment_name}})"
674- description = " This is a custom role created by the Azure Landing Zones Accelerator for Reading the platform subscriptions."
675- permissions = {
676- actions = [
677- " */read" ,
678- " Microsoft.Resources/subscriptions/resourceGroups/write" ,
679- " Microsoft.ManagedIdentity/userAssignedIdentities/write" ,
680- " Microsoft.Automation/automationAccounts/write" ,
681- " Microsoft.OperationalInsights/workspaces/write" ,
682- " Microsoft.OperationalInsights/workspaces/linkedServices/write" ,
683- " Microsoft.OperationsManagement/solutions/write" ,
684- " Microsoft.Insights/dataCollectionRules/write" ,
685- " Microsoft.Authorization/locks/write" ,
686- " Microsoft.Network/*/write" ,
687- " Microsoft.Resources/deployments/whatIf/action" ,
688- " Microsoft.Resources/deployments/write" ,
689- " Microsoft.SecurityInsights/onboardingStates/write"
690- ]
691- not_actions = []
692- }
693- }
694- }
608+ default = {}
695609}
696610
697611variable "custom_role_definitions_bicep" {
@@ -707,11 +621,8 @@ variable "custom_role_definitions_bicep" {
707621 - `actions` (list(string)) - Allowed Azure actions
708622 - `not_actions` (list(string)) - Denied Azure actions
709623
710- Default includes 4 predefined roles:
711- - `alz_management_group_contributor` - Manage management group hierarchy and governance
712- - `alz_management_group_reader` - Run Bicep What-If validations (requires --validation-level providerNoRbac flag)
713- - `alz_subscription_owner` - Full access to platform subscriptions
714- - `alz_subscription_reader` - Run Bicep What-If for subscription deployments
624+ Default includes 1 predefined roles:
625+ - `alz_reader` - Run Bicep What-If validations (requires --validation-level providerNoRbac flag)s
715626
716627 See default value for complete role action definitions.
717628 EOT
@@ -724,25 +635,7 @@ variable "custom_role_definitions_bicep" {
724635 })
725636 }))
726637 default = {
727- alz_management_group_contributor = {
728- name = " Azure Landing Zones Management Group Contributor ({{service_name}}-{{environment_name}})"
729- description = " This is a custom role created by the Azure Landing Zones Accelerator for creating and managing the Management Group hierarchy and its associated governance resources such as policy, RBAC etc..."
730- permissions = {
731- actions = [
732- " */read" ,
733- " Microsoft.Management/*" ,
734- " Microsoft.Authorization/*" ,
735- " Microsoft.Resources/*" ,
736- " Microsoft.Support/*" ,
737- " Microsoft.Insights/diagnosticSettings/*"
738- ]
739- not_actions = [
740- " Microsoft.Resources/subscriptions/resourceGroups/write" ,
741- " Microsoft.Resources/subscriptions/resourceGroups/delete"
742- ]
743- }
744- }
745- alz_management_group_reader = {
638+ alz_reader = {
746639 name = " Azure Landing Zones Management Group What If ({{service_name}}-{{environment_name}})"
747640 description = " This is a custom role created by the Azure Landing Zones Accelerator for running Bicep What If for the Management Group hierarchy and its associated governance resources such as policy, RBAC etc... You must use the `--validation-level providerNoRbac` (Az CLI 2.75.0 or later) or `-ValidationLevel providerNoRbac` (Az PowerShell 13.4.0 or later (Az.Resources 7.10.0 or later)) flag when running Bicep What If with this role."
748641 permissions = {
@@ -756,30 +649,6 @@ variable "custom_role_definitions_bicep" {
756649 not_actions = []
757650 }
758651 }
759- alz_subscription_owner = {
760- name = " Azure Landing Zones Subscription Owner ({{service_name}}-{{environment_name}})"
761- description = " This is a custom role created by the Azure Landing Zones Accelerator for Writing in platform subscriptions."
762- permissions = {
763- actions = [
764- " *"
765- ]
766- not_actions = []
767- }
768- }
769- alz_subscription_reader = {
770- name = " Azure Landing Zones Subscription What If ({{service_name}}-{{environment_name}})"
771- description = " This is a custom role created by the Azure Landing Zones Accelerator for running Bicep What If for the Management Group hierarchy and its associated governance resources such as policy, RBAC etc... You must use the `--validation-level providerNoRbac` (Az CLI 2.75.0 or later) or `-ValidationLevel providerNoRbac` (Az PowerShell 13.4.0 or later (Az.Resources 7.10.0 or later)) flag when running Bicep What If with this role."
772- permissions = {
773- actions = [
774- " */read" ,
775- " Microsoft.Resources/deployments/whatIf/action" ,
776- " Microsoft.Resources/deployments/validate/action" ,
777- " Microsoft.Resources/subscriptions/operationResults/read" ,
778- " Microsoft.Management/operationResults/*/read"
779- ]
780- not_actions = []
781- }
782- }
783652 }
784653}
785654
@@ -909,50 +778,83 @@ variable "role_assignments_terraform" {
909778 Map of role assignment configurations where:
910779 - **Key**: Assignment identifier (e.g., 'plan_management_group')
911780 - **Value**: Object containing:
781+ - `built_in_role_definition_name` (string) - Name of built-in role (e.g., 'Owner', 'Contributor')
912782 - `custom_role_definition_key` (string) - Key from custom_role_definitions_terraform
913783 - `user_assigned_managed_identity_key` (string) - Managed identity key ('plan' or 'apply')
914784 - `scope` (string) - Assignment scope ('management_group' or 'subscription')
915785
916- Default includes 4 assignments:
917- - Plan and apply access for management group operations
918- - Plan and apply access for subscription operations
786+ Default includes 2 assignments:
787+ - Plan and apply access
788+
919789 EOT
920790 type = map (object ({
921- custom_role_definition_key = string
791+ built_in_role_definition_name = optional (string )
792+ custom_role_definition_key = optional (string )
922793 user_assigned_managed_identity_key = string
923794 scope = string
924795 }))
925796 default = {
926- plan_management_group = {
927- custom_role_definition_key = " alz_management_group_reader "
797+ plan = {
798+ built_in_role_definition_name = " Reader "
928799 user_assigned_managed_identity_key = " plan"
929800 scope = " management_group"
930801 }
931- apply_management_group = {
932- custom_role_definition_key = " alz_management_group_contributor "
802+ apply = {
803+ built_in_role_definition_name = " Owner "
933804 user_assigned_managed_identity_key = " apply"
934805 scope = " management_group"
935806 }
936- plan_subscription = {
937- custom_role_definition_key = " alz_subscription_reader"
807+ }
808+ }
809+
810+ variable "role_assignments_bicep" {
811+ description = <<- EOT
812+ **(Optional)** RBAC role assignments for Bicep-based deployments.
813+
814+ Map of role assignment configurations where:
815+ - **Key**: Assignment identifier (e.g., 'plan_management_group')
816+ - **Value**: Object containing:
817+ - `built_in_role_definition_name` (string) - Name of built-in role (e.g., 'Owner', 'Contributor')
818+ - `custom_role_definition_key` (string) - Key from custom_role_definitions_bicep
819+ - `user_assigned_managed_identity_key` (string) - Managed identity key ('plan' or 'apply')
820+ - `scope` (string) - Assignment scope ('management_group' or 'subscription')
821+
822+ Default includes 3 assignments:
823+ - Plan and apply access operations
824+ EOT
825+ type = map (object ({
826+ built_in_role_definition_name = optional (string )
827+ custom_role_definition_key = optional (string )
828+ user_assigned_managed_identity_key = string
829+ scope = string
830+ }))
831+ default = {
832+ plan = {
833+ custom_role_definition_key = " Reader"
938834 user_assigned_managed_identity_key = " plan"
939- scope = " subscription "
835+ scope = " management_group "
940836 }
941- apply_subscription = {
942- custom_role_definition_key = " alz_subscription_owner"
837+ plan_custom = {
838+ custom_role_definition_key = " alz_reader"
839+ user_assigned_managed_identity_key = " plan"
840+ scope = " management_group"
841+ }
842+ apply_management_group = {
843+ custom_role_definition_key = " Owner"
943844 user_assigned_managed_identity_key = " apply"
944- scope = " subscription "
845+ scope = " management_group "
945846 }
946847 }
947848}
948849
949- variable "role_assignments_bicep " {
850+ variable "role_assignments_bicep_classic " {
950851 description = <<- EOT
951- **(Optional)** RBAC role assignments for Bicep- based deployments.
852+ **(Optional)** RBAC role assignments for Bicep Classic based deployments.
952853
953854 Map of role assignment configurations where:
954855 - **Key**: Assignment identifier (e.g., 'plan_management_group')
955856 - **Value**: Object containing:
857+ - `built_in_role_definition_name` (string) - Name of built-in role (e.g., 'Owner', 'Contributor')
956858 - `custom_role_definition_key` (string) - Key from custom_role_definitions_bicep
957859 - `user_assigned_managed_identity_key` (string) - Managed identity key ('plan' or 'apply')
958860 - `scope` (string) - Assignment scope ('management_group' or 'subscription')
@@ -962,7 +864,8 @@ variable "role_assignments_bicep" {
962864 - Plan and apply access for subscription operations
963865 EOT
964866 type = map (object ({
965- custom_role_definition_key = string
867+ built_in_role_definition_name = optional (string )
868+ custom_role_definition_key = optional (string )
966869 user_assigned_managed_identity_key = string
967870 scope = string
968871 }))
@@ -1078,3 +981,14 @@ variable "bicep_tenant_role_assignment_role_definition_name" {
1078981 type = string
1079982 default = " Landing Zone Management Owner"
1080983}
984+
985+ variable "terraform_architecture_file_path" {
986+ description = <<- EOT
987+ **(Required)** Relative path to the Terraform architecture definition JSON file within the module folder.
988+
989+ This file defines the structure and components of the Terraform deployment architecture.
990+ Used for dynamic file manipulation based on architecture specifics.
991+ EOT
992+ type = string
993+ default = " lib/architecture_definitions/alz_custom.alz_architecture_definition.yaml"
994+ }
0 commit comments