Skip to content

Commit de6d34d

Browse files
authored
Merge pull request #1614 from camillemarie/patch-1
Remove policy resources from tenant deployment schema
2 parents 208d790 + afe81d6 commit de6d34d

File tree

2 files changed

+2
-128
lines changed

2 files changed

+2
-128
lines changed

schemas/2019-08-01/tenantDeploymentTemplate.json

Lines changed: 1 addition & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -68,51 +68,6 @@
6868
{
6969
"$ref": "https://schema.management.azure.com/schemas/2017-09-01/Microsoft.Authorization.json#/resourceDefinitions/roleDefinitions"
7070
},
71-
{
72-
"$ref": "https://schema.management.azure.com/schemas/2018-03-01/Microsoft.Authorization.json#/resourceDefinitions/policyAssignments"
73-
},
74-
{
75-
"$ref": "https://schema.management.azure.com/schemas/2018-03-01/Microsoft.Authorization.json#/resourceDefinitions/policyDefinitions"
76-
},
77-
{
78-
"$ref": "https://schema.management.azure.com/schemas/2018-03-01/Microsoft.Authorization.json#/resourceDefinitions/policySetDefinitions"
79-
},
80-
{
81-
"$ref": "https://schema.management.azure.com/schemas/2018-05-01/Microsoft.Authorization.json#/resourceDefinitions/policyAssignments"
82-
},
83-
{
84-
"$ref": "https://schema.management.azure.com/schemas/2018-05-01/Microsoft.Authorization.json#/resourceDefinitions/policyDefinitions"
85-
},
86-
{
87-
"$ref": "https://schema.management.azure.com/schemas/2018-05-01/Microsoft.Authorization.json#/resourceDefinitions/policySetDefinitions"
88-
},
89-
{
90-
"$ref": "https://schema.management.azure.com/schemas/2019-01-01/Microsoft.Authorization.json#/resourceDefinitions/policyAssignments"
91-
},
92-
{
93-
"$ref": "https://schema.management.azure.com/schemas/2019-01-01/Microsoft.Authorization.json#/resourceDefinitions/policyDefinitions"
94-
},
95-
{
96-
"$ref": "https://schema.management.azure.com/schemas/2019-01-01/Microsoft.Authorization.json#/resourceDefinitions/policySetDefinitions"
97-
},
98-
{
99-
"$ref": "https://schema.management.azure.com/schemas/2019-06-01/Microsoft.Authorization.json#/resourceDefinitions/policyAssignments"
100-
},
101-
{
102-
"$ref": "https://schema.management.azure.com/schemas/2019-06-01/Microsoft.Authorization.json#/resourceDefinitions/policyDefinitions"
103-
},
104-
{
105-
"$ref": "https://schema.management.azure.com/schemas/2019-06-01/Microsoft.Authorization.json#/resourceDefinitions/policySetDefinitions"
106-
},
107-
{
108-
"$ref": "https://schema.management.azure.com/schemas/2019-09-01/Microsoft.Authorization.json#/resourceDefinitions/policyAssignments"
109-
},
110-
{
111-
"$ref": "https://schema.management.azure.com/schemas/2019-09-01/Microsoft.Authorization.json#/resourceDefinitions/policyDefinitions"
112-
},
113-
{
114-
"$ref": "https://schema.management.azure.com/schemas/2019-09-01/Microsoft.Authorization.json#/resourceDefinitions/policySetDefinitions"
115-
},
11671
{
11772
"$ref": "https://schema.management.azure.com/schemas/2018-11-01-preview/Microsoft.Billing.json#/tenant_resourceDefinitions/billingAccounts_billingProfiles"
11873
},
@@ -761,4 +716,4 @@
761716
"description": "Output copy"
762717
}
763718
}
764-
}
719+
}

tools/templateTests/TenantTemplate.2019-08-01.json

Lines changed: 1 addition & 82 deletions
Original file line numberDiff line numberDiff line change
@@ -291,87 +291,6 @@
291291
"/"
292292
]
293293
}
294-
},
295-
{
296-
"apiVersion": "2018-05-01",
297-
"properties": {
298-
"displayName": "Test Policy Set Definition",
299-
"policyType": "Custom",
300-
"metadata": {
301-
"category": "SomeCategory",
302-
"SomethingUseful": {
303-
"aThing": "A thing value"
304-
}
305-
},
306-
"parameters": {
307-
"Parameter1": {
308-
"type": "String",
309-
"metadata": {
310-
"displayName": "Parameter1",
311-
"description": "The first parameter"
312-
},
313-
"defaultValue": "audit"
314-
}
315-
},
316-
"policyDefinitions": [
317-
{
318-
"policyDefinitionReferenceId": "SomePolicyDefinitionName",
319-
"policyDefinitionId": "/subscriptions/63e997c7-5fd1-4b3a-8eb5-a3dc0fb3ab6f/providers/Microsoft.Authorization/policyDefinitions/SomePolicyDefinitionName",
320-
"parameters": {
321-
"effect": {
322-
"value": "audit"
323-
}
324-
}
325-
},
326-
{
327-
"policyDefinitionReferenceId": "AnotherPolicyDefinitionName",
328-
"policyDefinitionId": "/subscriptions/63e997c7-5fd1-4b3a-8eb5-a3dc0fb3ab6f/providers/Microsoft.Authorization/policyDefinitions/AnotherPolicyDefinitionName",
329-
"parameters": {
330-
"effect": {
331-
"value": "[parameters('Parameter1')]"
332-
}
333-
}
334-
}
335-
]
336-
},
337-
"id": "/subscriptions/63e997c7-5fd1-4b3a-8eb5-a3dc0fb3ab6f/providers/Microsoft.Authorization/policySetDefinitions/SomePolicySetDefinitionName",
338-
"type": "Microsoft.Authorization/policySetDefinitions",
339-
"name": "SomePolicySetDefinitionName"
340-
},
341-
{
342-
"apiVersion": "2018-05-01",
343-
"sku": {
344-
"name": "A0",
345-
"tier": "Free"
346-
},
347-
"properties": {
348-
"displayName": "Test Assignment",
349-
"policyDefinitionId": "/subscriptions/d5a43281-5981-4cc7-a939-6ff1ab06636a/providers/Microsoft.Authorization/policyDefinitions/SomePolicyDefinition",
350-
"scope": "/subscriptions/d5a43281-5981-4cc7-a939-6ff1ab06636a/resourceGroups/SomeResourceGroup",
351-
"notScopes": [
352-
"/subscriptions/d5a43281-5981-4cc7-a939-6ff1ab06636a/resourceGroups/SomeResourceGroup"
353-
],
354-
"parameters": {
355-
"allowedLocations": {
356-
"value": [
357-
"centralus"
358-
]
359-
}
360-
},
361-
"description": "Some policy assignment test",
362-
"metadata": {
363-
"assignedBy": "Test Writer",
364-
"parameterScopes": {}
365-
}
366-
},
367-
"identity": {
368-
"principalId": "c2360c90-bab1-4e87-8ea0-da97d17c037d",
369-
"tenantId": "ae0450b3-f3c6-4685-bc92-2669d7d5f810",
370-
"type": "SystemAssigned"
371-
},
372-
"id": "/subscriptions/d5a43281-5981-4cc7-a939-6ff1ab06636a/resourceGroups/SomeResourceGroup/providers/Microsoft.Authorization/policyAssignments/TestAssignment",
373-
"type": "Microsoft.Authorization/policyAssignments",
374-
"name": "TestAssignment"
375294
}
376295
]
377-
}
296+
}

0 commit comments

Comments
 (0)