forked from Flangvik/AzureC2Relay
-
Notifications
You must be signed in to change notification settings - Fork 0
/
arm_template.json
102 lines (102 loc) · 3.8 KB
/
arm_template.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
92
93
94
95
96
97
98
99
100
101
102
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"cdn_profile_name": {
"type": "String"
},
"endpoint_name": {
"type": "String"
},
"app_func_name": {
"type": "String"
},
"location": {
"defaultValue": "westeurope",
"type": "String"
}
},
"variables": {},
"resources": [
{
"type": "Microsoft.Cdn/profiles",
"apiVersion": "2020-04-15",
"name": "[parameters('cdn_profile_name')]",
"location": "[parameters('location')]",
"sku": {
"name": "Standard_Verizon"
},
"properties": {}
},
{
"type": "Microsoft.Cdn/profiles/endpoints",
"apiVersion": "2020-04-15",
"name": "[concat(parameters('cdn_profile_name'), '/', parameters('endpoint_name'))]",
"location": "[parameters('location')]",
"dependsOn": [
"[resourceId('Microsoft.Cdn/profiles', parameters('cdn_profile_name'))]"
],
"properties": {
"originHostHeader": "[parameters('app_func_name')]",
"contentTypesToCompress": [
"text/plain",
"text/html",
"text/css",
"text/javascript",
"application/x-javascript",
"application/javascript",
"application/json",
"application/xml"
],
"isCompressionEnabled": true,
"isHttpAllowed": true,
"isHttpsAllowed": true,
"queryStringCachingBehavior": "BypassCaching",
"optimizationType": "GeneralWebDelivery",
"origins": [
{
"name": "[ replace( parameters('app_func_name'), '.', '-') ]",
"properties": {
"hostName": "[parameters('app_func_name')]",
"enabled": true
}
}
],
"originGroups": [],
"geoFilters": [],
"deliveryPolicy": {
"rules": [
{
"order": 0,
"conditions": [],
"actions": [
{
"name": "CacheExpiration",
"parameters": {
"cacheBehavior": "BypassCache",
"cacheType": "All",
"@odata.type": "#Microsoft.Azure.Cdn.Models.DeliveryRuleCacheExpirationActionParameters"
}
}
]
}
]
},
"urlSigningKeys": []
}
},
{
"type": "Microsoft.Cdn/profiles/endpoints/origins",
"apiVersion": "2020-04-15",
"name": "[concat(parameters('cdn_profile_name'), '/' , parameters('endpoint_name') , '/' , replace( parameters('app_func_name'), '.', '-'))]",
"dependsOn": [
"[resourceId('Microsoft.Cdn/profiles/endpoints', parameters('cdn_profile_name'), parameters('endpoint_name'))]",
"[resourceId('Microsoft.Cdn/profiles', parameters('cdn_profile_name'))]"
],
"properties": {
"hostName": "[parameters('app_func_name')]",
"enabled": true
}
}
]
}