-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path4-many-ingest-storage-accounts-event-subscription.json
91 lines (91 loc) · 3.22 KB
/
4-many-ingest-storage-accounts-event-subscription.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"location": {
"type": "string",
"defaultValue": "[resourceGroup().location]"
},
"eventGridSubscriptionName": {
"type": "string"
},
"queueStorageAccountResourceId": {
"type": "string"
},
"queueName": {
"type": "string"
},
"ingestStorageAccountName": {
"type": "string"
},
"numberOfStorageAccounts": {
"type": "int"
}
},
"variables": {},
"resources": [
{
"apiVersion": "2018-03-01-preview",
"type": "Microsoft.Storage/storageAccounts",
"name": "[concat(parameters('ingestStorageAccountName'),copyIndex())]",
"location": "[parameters('location')]",
"kind": "StorageV2",
"sku": {
"name": "Standard_LRS",
"tier": "Standard"
},
"copy": {
"name": "storageLoop",
"count": "[parameters('numberOfStorageAccounts')]",
"mode": "Serial",
"batchSize": 5
},
"resources": [
{
"apiVersion": "2018-03-01-preview",
"type": "blobServices/containers",
"name": "[concat('default/','ingestcontainer')]",
"dependsOn": [
"[concat(parameters('ingestStorageAccountName'),copyIndex())]"
],
"properties": {}
}
]
},
{
"apiVersion": "2018-05-01-preview",
"type": "Microsoft.Storage/storageAccounts/providers/eventSubscriptions",
"name": "[concat(parameters('ingestStorageAccountName'),copyIndex(),'/Microsoft.EventGrid/',parameters('eventGridSubscriptionName'))]",
"location": "[parameters('location')]",
"dependsOn": [
"[concat('Microsoft.Storage/storageAccounts/',parameters('ingestStorageAccountName'),copyIndex())]"
],
"copy": {
"name": "storageLoop",
"count": "[parameters('numberOfStorageAccounts')]"
},
"properties": {
"destination": {
"endpointType": "StorageQueue",
"properties": {
"resourceId": "[parameters('queueStorageAccountResourceId')]",
"queueName": "[parameters('queueName')]"
}
},
"filter": {
"subjectBeginsWith": "[concat('/blobServices/default/containers/ingestcontainer')]",
"subjectEndsWith": "",
"isSubjectCaseSensitive": false,
"includedEventTypes": ["All"]
},
"eventDeliverySchema": "InputEventSchema",
"retryPolicy": {
"maxDeliveryAttempts": 30,
"eventTimeToLiveInMinutes": 1440
}
}
}
],
"outputs": {
}
}