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

Update alzDefaultPolicyAssignments.bicep #729

Merged
merged 38 commits into from
Feb 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
e7693e1
Update alzDefaultPolicyAssignments.bicep
VeronicaSea Feb 21, 2024
0f1725c
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 21, 2024
14ec44b
Update mc-alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 21, 2024
2ae19fb
Update mc-alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 21, 2024
93931c6
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 21, 2024
6716922
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 21, 2024
e4f0e69
Update mc-alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 21, 2024
b00cc79
Update alzDefaultPolicyAssignments.bicep
VeronicaSea Feb 21, 2024
f686c23
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 21, 2024
92052a7
Update alzDefaultPolicyAssignments.bicep
VeronicaSea Feb 22, 2024
8ff4791
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 22, 2024
67772e8
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 22, 2024
2f04a25
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 22, 2024
c70f4f6
Update alzDefaultPolicyAssignments.bicep
VeronicaSea Feb 26, 2024
6c7200e
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 26, 2024
1879d8d
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 26, 2024
ba47cdf
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 26, 2024
32ef2e0
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 26, 2024
47d5e5a
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 26, 2024
fa19f37
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 26, 2024
f6fc132
Merge branch 'main' into main
oZakari Feb 26, 2024
3cf99cc
Add effect properties to UDT and remove disable slz policy param
oZakari Feb 27, 2024
ce00d22
Simplify sov effect policy property names
oZakari Feb 27, 2024
1171ede
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 27, 2024
bff6a8c
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 27, 2024
914ab84
Update alzDefaultPolicyAssignments.bicep
VeronicaSea Feb 27, 2024
acde149
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 27, 2024
cd215e0
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 27, 2024
818e212
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 27, 2024
4dcd0f7
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 27, 2024
8d1ab5e
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 27, 2024
d038a74
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 27, 2024
91d434c
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 27, 2024
40786fd
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 27, 2024
aaddd13
Update alzDefaultPolicyAssignments.bicep
VeronicaSea Feb 27, 2024
7b89639
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 27, 2024
dff733b
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 27, 2024
273c44c
Update alzDefaultPolicyAssignments.bicep.md
VeronicaSea Feb 27, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ type policyAssignmentSovereigntyGlobalOptionsType = {

@sys.description('The list of locations that your organization can use to restrict deploying resources to. If left empty, only the deployment location will be allowed.')
parListOfAllowedLocations: string[]

@sys.description('The effect type for the Sovereignty Baseline - Global Policies Assignment.')
parPolicyEffect: ('Audit' | 'Deny' | 'Disabled' | 'AuditIfNotExists')
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is to broad as a parameter name and will cause confusion also seems a duplicate of parTopLevelSovereignGlobalPoliciesEnable?

Please can we align and make this simplified and clear to customers what the parameter does

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, it explains in the description. It is already simplified and clear. We need it for different scope, like global, confidential.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@oZakari How do you think?

}

type policyAssignmentSovereigntyConfidentialOptionsType = {
Expand All @@ -18,6 +21,9 @@ type policyAssignmentSovereigntyConfidentialOptionsType = {

@sys.description('The list of VM SKUs approved approved for usage, which is the set of SKUs backed by Azure Confidential Computing. Leave empty to allow all relevant SKUs.')
parAllowedVirtualMachineSKUs: string[]

@sys.description('The effect type for the Sovereignty Baseline - Confidential Policies Assignment.')
parPolicyEffect: ('Audit' | 'Deny' | 'Disabled' | 'AuditIfNotExists')
}

@sys.description('Prefix used for the management group hierarchy.')
Expand All @@ -31,26 +37,30 @@ param parTopLevelManagementGroupSuffix string = ''

@sys.description('''Object used to assign Sovereignty Baseline - Global Policies to the intermediate root management group.'

- `parTopLevelSovereignGlobalPoliciesEnable - Switch to enable/disable deployment of the Sovereignty Baseline - Global Policies Assignment to the intermediate root management group.
- `parTopLevelSovereignGlobalPoliciesEnable` - Switch to enable/disable deployment of the Sovereignty Baseline - Global Policies Assignment to the intermediate root management group.
- `parListOfAllowedLocations` - The list of locations that your organization can use to restrict deploying resources to. If left empty, only the deployment location will be allowed.
- `parPolicyEffect` - The effect type for the Sovereignty Baseline - Global Policies Assignment.

''')
param parTopLevelPolicyAssignmentSovereigntyGlobal policyAssignmentSovereigntyGlobalOptionsType = {
parTopLevelSovereigntyGlobalPoliciesEnable: false
parListOfAllowedLocations: []
parPolicyEffect: 'Deny'
}

@sys.description('''Object used to assign Sovereignty Baseline - Confidential Policies to the confidential landing zone management groups.'

- `parAllowedResourceTypes` - The list of Azure resource types approved for usage, which is the set of resource types that have a SKU backed by Azure Confidential Computing or resource types that do not process customer data. Leave empty to allow all relevant resource types.
- `parListOfAllowedLocations` - The list of locations that your organization can use to restrict deploying resources to. If left empty, only the deployment location will be allowed.
- `parallowedVirtualMachineSKUs` - The list of VM SKUs approved approved for usage, which is the set of SKUs backed by Azure Confidential Computing. Leave empty to allow all relevant SKUs.
- `parPolicyEffect` - The effect type for the Sovereignty Baseline - Confidential Policies Assignment.

''')
param parPolicyAssignmentSovereigntyConfidential policyAssignmentSovereigntyConfidentialOptionsType = {
parAllowedResourceTypes: []
parListOfAllowedLocations: []
parAllowedVirtualMachineSKUs: []
parPolicyEffect: 'Deny'
}

@sys.description('Management, Identity and Connectivity Management Groups beneath Platform Management Group have been deployed. If set to false, platform policies are assigned to the Platform Management Group; otherwise policies are assigned to the child management groups.')
Expand Down Expand Up @@ -89,6 +99,9 @@ param parPrivateDnsZonesNamesToAuditInCorp array = []
@sys.description('Set Enforcement Mode of all default Policies assignments to Do Not Enforce.')
param parDisableAlzDefaultPolicies bool = false

@sys.description('Set Enforcement Mode of all default sovereign Policies assignments to Do Not Enforce.')
param parDisableSlzDefaultPolicies bool = false
VeronicaSea marked this conversation as resolved.
Show resolved Hide resolved

@sys.description('Name of the tag to use for excluding VMs from the scope of this policy. This should be used along with the Exclusion Tag Value parameter.')
param parVmBackupExclusionTagName string = ''

Expand Down Expand Up @@ -524,9 +537,12 @@ module modPolicyAssignmentIntRootEnforceSovereigntyGlobal '../../../policy/assig
#disable-next-line no-loc-expr-outside-params
value: !(empty(parTopLevelPolicyAssignmentSovereigntyGlobal.parListOfAllowedLocations)) ? parTopLevelPolicyAssignmentSovereigntyGlobal.parListOfAllowedLocations : array(deployment().location)
}
effect: {
value: parTopLevelPolicyAssignmentSovereigntyGlobal.parPolicyEffect
}
}
parPolicyAssignmentIdentityType: varPolicyAssignmentEnforceSovereignGlobal.libDefinition.identity.type
parPolicyAssignmentEnforcementMode: parDisableAlzDefaultPolicies ? 'DoNotEnforce' : varPolicyAssignmentEnforceSovereignGlobal.libDefinition.properties.enforcementMode
parPolicyAssignmentEnforcementMode: parDisableSlzDefaultPolicies ? 'DoNotEnforce' : varPolicyAssignmentEnforceSovereignGlobal.libDefinition.properties.enforcementMode
parTelemetryOptOut: parTelemetryOptOut
}
}
Expand Down Expand Up @@ -1560,9 +1576,12 @@ module modPolicyAssignmentLzsConfidentialOnlineEnforceSovereigntyConf '../../../
allowedVirtualMachineSKUs: {
value: !(empty(parPolicyAssignmentSovereigntyConfidential.parAllowedVirtualMachineSKUs)) ? parPolicyAssignmentSovereigntyConfidential.parAllowedVirtualMachineSKUs : varPolicyAssignmentEnforceSovereignConf.libDefinition.properties.parameters.allowedVirtualMachineSKUs.value
}
effect: {
value: parPolicyAssignmentSovereigntyConfidential.parPolicyEffect
}
}
parPolicyAssignmentIdentityType: varPolicyAssignmentEnforceSovereignConf.libDefinition.identity.type
parPolicyAssignmentEnforcementMode: parDisableAlzDefaultPolicies ? 'DoNotEnforce' : varPolicyAssignmentEnforceSovereignConf.libDefinition.properties.enforcementMode
parPolicyAssignmentEnforcementMode: parDisableSlzDefaultPolicies ? 'DoNotEnforce' : varPolicyAssignmentEnforceSovereignConf.libDefinition.properties.enforcementMode
parTelemetryOptOut: parTelemetryOptOut
}
}
Expand All @@ -1589,9 +1608,12 @@ module modPolicyAssignmentLzsConfidentialCorpEnforceSovereigntyConf '../../../po
allowedVirtualMachineSKUs: {
value: !(empty(parPolicyAssignmentSovereigntyConfidential.parAllowedVirtualMachineSKUs)) ? parPolicyAssignmentSovereigntyConfidential.parAllowedVirtualMachineSKUs : varPolicyAssignmentEnforceSovereignConf.libDefinition.properties.parameters.allowedVirtualMachineSKUs.value
}
effect: {
value: parPolicyAssignmentSovereigntyConfidential.parPolicyEffect
}
}
parPolicyAssignmentIdentityType: varPolicyAssignmentEnforceSovereignConf.libDefinition.identity.type
parPolicyAssignmentEnforcementMode: parDisableAlzDefaultPolicies ? 'DoNotEnforce' : varPolicyAssignmentEnforceSovereignConf.libDefinition.properties.enforcementMode
parPolicyAssignmentEnforcementMode: parDisableSlzDefaultPolicies ? 'DoNotEnforce' : varPolicyAssignmentEnforceSovereignConf.libDefinition.properties.enforcementMode
parTelemetryOptOut: parTelemetryOptOut
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ Parameter name | Required | Description
-------------- | -------- | -----------
parTopLevelManagementGroupPrefix | No | Prefix used for the management group hierarchy.
parTopLevelManagementGroupSuffix | No | Optional suffix for the management group hierarchy. This suffix will be appended to management group names/IDs. Include a preceding dash if required. Example: -suffix
parTopLevelPolicyAssignmentSovereigntyGlobal | No | Object used to assign Sovereignty Baseline - Global Policies to the intermediate root management group.' - `parTopLevelSovereignGlobalPoliciesEnable - Switch to enable/disable deployment of the Sovereignty Baseline - Global Policies Assignment to the intermediate root management group. - `parListOfAllowedLocations` - The list of locations that your organization can use to restrict deploying resources to. If left empty, only the deployment location will be allowed.
parPolicyAssignmentSovereigntyConfidential | No | Object used to assign Sovereignty Baseline - Confidential Policies to the confidential landing zone management groups.' - `parAllowedResourceTypes` - The list of Azure resource types approved for usage, which is the set of resource types that have a SKU backed by Azure Confidential Computing or resource types that do not process customer data. Leave empty to allow all relevant resource types. - `parListOfAllowedLocations` - The list of locations that your organization can use to restrict deploying resources to. If left empty, only the deployment location will be allowed. - `parallowedVirtualMachineSKUs` - The list of VM SKUs approved approved for usage, which is the set of SKUs backed by Azure Confidential Computing. Leave empty to allow all relevant SKUs.
parTopLevelPolicyAssignmentSovereigntyGlobal | No | Object used to assign Sovereignty Baseline - Global Policies to the intermediate root management group.' - `parTopLevelSovereignGlobalPoliciesEnable` - Switch to enable/disable deployment of the Sovereignty Baseline - Global Policies Assignment to the intermediate root management group. - `parListOfAllowedLocations` - The list of locations that your organization can use to restrict deploying resources to. If left empty, only the deployment location will be allowed. - `parPolicyEffect` - The effect type for the Sovereignty Baseline - Global Policies Assignment.
parPolicyAssignmentSovereigntyConfidential | No | Object used to assign Sovereignty Baseline - Confidential Policies to the confidential landing zone management groups.' - `parAllowedResourceTypes` - The list of Azure resource types approved for usage, which is the set of resource types that have a SKU backed by Azure Confidential Computing or resource types that do not process customer data. Leave empty to allow all relevant resource types. - `parListOfAllowedLocations` - The list of locations that your organization can use to restrict deploying resources to. If left empty, only the deployment location will be allowed. - `parallowedVirtualMachineSKUs` - The list of VM SKUs approved approved for usage, which is the set of SKUs backed by Azure Confidential Computing. Leave empty to allow all relevant SKUs. - `parPolicyEffect` - The effect type for the Sovereignty Baseline - Confidential Policies Assignment.
parPlatformMgAlzDefaultsEnable | No | Management, Identity and Connectivity Management Groups beneath Platform Management Group have been deployed. If set to false, platform policies are assigned to the Platform Management Group; otherwise policies are assigned to the child management groups.
parLandingZoneChildrenMgAlzDefaultsEnable | No | Corp & Online Management Groups beneath Landing Zones Management Groups have been deployed. If set to false, policies will not try to be assigned to corp or online Management Groups.
parLandingZoneMgConfidentialEnable | No | Confidential Corp & Confidential Online Management Groups beneath Landing Zones Management Group have been deployed. If set to false, policies will not try to be assigned to Confidential Corp & Confidential Online Management Groups
Expand All @@ -22,6 +22,7 @@ parDdosProtectionPlanId | No | ID of the DdosProtectionPlan which will be
parPrivateDnsResourceGroupId | No | Resource ID of the Resource Group that conatin the Private DNS Zones. If left empty, the policy Deploy-Private-DNS-Zones will not be assigned to the corp Management Group.
parPrivateDnsZonesNamesToAuditInCorp | No | Provide an array/list of Private DNS Zones that you wish to audit if deployed into Subscriptions in the Corp Management Group. NOTE: The policy default values include all the static Private Link Private DNS Zones, e.g. all the DNS Zones that dont have a region or region shortcode in them. If you wish for these to be audited also you must provide a complete array/list to this parameter for ALL Private DNS Zones you wish to audit, including the static Private Link ones, as this parameter performs an overwrite operation. You can get all the Private DNS Zone Names form the `outPrivateDnsZonesNames` output in the Hub Networking or Private DNS Zone modules.
parDisableAlzDefaultPolicies | No | Set Enforcement Mode of all default Policies assignments to Do Not Enforce.
parDisableSlzDefaultPolicies | No | Set Enforcement Mode of all default sovereign Policies assignments to Do Not Enforce.
parVmBackupExclusionTagName | No | Name of the tag to use for excluding VMs from the scope of this policy. This should be used along with the Exclusion Tag Value parameter.
parVmBackupExclusionTagValue | No | Value of the tag to use for excluding VMs from the scope of this policy (in case of multiple values, use a comma-separated list). This should be used along with the Exclusion Tag Name parameter.
parExcludedPolicyAssignments | No | Adding assignment definition names to this array will exclude the specific policies from assignment. Find the correct values to this array in the following documentation: https://github.com/Azure/ALZ-Bicep/wiki/AssigningPolicies#what-if-i-want-to-exclude-specific-policy-assignments-from-alz-default-policy-assignments
Expand All @@ -47,12 +48,13 @@ Optional suffix for the management group hierarchy. This suffix will be appended

Object used to assign Sovereignty Baseline - Global Policies to the intermediate root management group.'

- `parTopLevelSovereignGlobalPoliciesEnable - Switch to enable/disable deployment of the Sovereignty Baseline - Global Policies Assignment to the intermediate root management group.
- `parTopLevelSovereignGlobalPoliciesEnable` - Switch to enable/disable deployment of the Sovereignty Baseline - Global Policies Assignment to the intermediate root management group.
- `parListOfAllowedLocations` - The list of locations that your organization can use to restrict deploying resources to. If left empty, only the deployment location will be allowed.
- `parPolicyEffect` - The effect type for the Sovereignty Baseline - Global Policies Assignment.



- Default value: `@{parTopLevelSovereigntyGlobalPoliciesEnable=False; parListOfAllowedLocations=System.Object[]}`
- Default value: `@{parTopLevelSovereigntyGlobalPoliciesEnable=False; parListOfAllowedLocations=System.Object[]; parPolicyEffect=Deny}`

### parPolicyAssignmentSovereigntyConfidential

Expand All @@ -63,10 +65,11 @@ Object used to assign Sovereignty Baseline - Confidential Policies to the confid
- `parAllowedResourceTypes` - The list of Azure resource types approved for usage, which is the set of resource types that have a SKU backed by Azure Confidential Computing or resource types that do not process customer data. Leave empty to allow all relevant resource types.
- `parListOfAllowedLocations` - The list of locations that your organization can use to restrict deploying resources to. If left empty, only the deployment location will be allowed.
- `parallowedVirtualMachineSKUs` - The list of VM SKUs approved approved for usage, which is the set of SKUs backed by Azure Confidential Computing. Leave empty to allow all relevant SKUs.
- `parPolicyEffect` - The effect type for the Sovereignty Baseline - Confidential Policies Assignment.



- Default value: `@{parAllowedResourceTypes=System.Object[]; parListOfAllowedLocations=System.Object[]; parAllowedVirtualMachineSKUs=System.Object[]}`
- Default value: `@{parAllowedResourceTypes=System.Object[]; parListOfAllowedLocations=System.Object[]; parAllowedVirtualMachineSKUs=System.Object[]; parPolicyEffect=Deny}`

### parPlatformMgAlzDefaultsEnable

Expand Down Expand Up @@ -156,6 +159,14 @@ Set Enforcement Mode of all default Policies assignments to Do Not Enforce.

- Default value: `False`

### parDisableSlzDefaultPolicies

![Parameter Setting](https://img.shields.io/badge/parameter-optional-green?style=flat-square)

Set Enforcement Mode of all default sovereign Policies assignments to Do Not Enforce.

- Default value: `False`

### parVmBackupExclusionTagName

![Parameter Setting](https://img.shields.io/badge/parameter-optional-green?style=flat-square)
Expand Down Expand Up @@ -203,14 +214,16 @@ Set Parameter to true to Opt-out of deployment telemetry
"parTopLevelPolicyAssignmentSovereigntyGlobal": {
"value": {
"parTopLevelSovereigntyGlobalPoliciesEnable": false,
"parListOfAllowedLocations": []
"parListOfAllowedLocations": [],
"parPolicyEffect": "Deny"
}
},
"parPolicyAssignmentSovereigntyConfidential": {
"value": {
"parAllowedResourceTypes": [],
"parListOfAllowedLocations": [],
"parAllowedVirtualMachineSKUs": []
"parAllowedVirtualMachineSKUs": [],
"parPolicyEffect": "Deny"
}
},
"parPlatformMgAlzDefaultsEnable": {
Expand Down Expand Up @@ -249,6 +262,9 @@ Set Parameter to true to Opt-out of deployment telemetry
"parDisableAlzDefaultPolicies": {
"value": false
},
"parDisableSlzDefaultPolicies": {
"value": false
},
"parVmBackupExclusionTagName": {
"value": ""
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
"parTopLevelPolicyAssignmentSovereigntyGlobal": {
"value": {
"parTopLevelSovereigntyGlobalPoliciesEnable": false,
"parListOfAllowedLocations": []
"parListOfAllowedLocations": [],
"parPolicyEffect": "Deny"
}
},
"parPlatformMgAlzDefaultsEnable": {
Expand All @@ -27,7 +28,8 @@
"value": {
"parAllowedResourceTypes": [],
"parListOfAllowedLocations": [],
"parAllowedVirtualMachineSKUs": []
"parAllowedVirtualMachineSKUs": [],
"parPolicyEffect": "Deny"
}
},
"parLogAnalyticsWorkSpaceAndAutomationAccountLocation": {
Expand Down
Loading