generated from azure-template-resources/react-basic
-
Notifications
You must be signed in to change notification settings - Fork 0
/
template.json
103 lines (103 loc) · 2.93 KB
/
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
103
{
"$schema": "http://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"metadata": {
"title": "Deploys Static Web App",
"description": "This template deploys a React Static Web App"
},
"parameters": {
"location": {
"type": "string",
"defaultValue": "[resourceGroup().location]",
"metadata": {
"description": "Location for all resources."
}
},
"staticSiteName": {
"type": "string",
"defaultValue": "[format('swa-{0}', uniqueString(resourceGroup().id))]",
"minLength": 2,
"metadata": {
"description": "static web app name"
}
},
"staticSiteSku": {
"type": "string",
"defaultValue": "Standard",
"metadata": {
"description": "The SKU of Static web app."
}
},
"staticSiteSkuCode": {
"type": "string",
"defaultValue": "Standard",
"metadata": {
"description": "The SKU code of Static web app."
}
},
"staticSiteAppLocation": {
"type": "string",
"defaultValue": "/",
"metadata": {
"description": "The app location for the repo used to create static web app"
}
},
"staticSiteApiLocation": {
"type": "string",
"defaultValue": "api",
"metadata": {
"description": "The api location for the repo used to create static web app"
}
},
"staticSiteAppArtifactLocation": {
"type": "string",
"defaultValue": "build",
"metadata": {
"description": "The app artifact location for the repo used to create static web app"
}
},
"repoUrl": {
"type": "string",
"metadata": {
"description": "The repo url used to deploy static web app"
}
},
"branch": {
"type": "string",
"defaultValue": "main",
"metadata": {
"description": "The branch of the repo used to deploy static web app"
}
},
"repositoryToken": {
"type": "secureString",
"metadata": {
"description": "The github token of the repo's owner to deploy static web app"
}
}
},
"variables": {},
"resources": [
{
"type": "Microsoft.Web/staticSites",
"apiVersion": "2021-01-15",
"name": "[parameters('staticSiteName')]",
"location": "[parameters('location')]",
"sku": {
"Tier": "[parameters('staticSiteSku')]",
"Name": "[parameters('staticSiteSkuCode')]"
},
"properties": {
"name": "[parameters('staticSiteName')]",
"repositoryUrl": "[parameters('repoUrl')]",
"branch": "[parameters('branch')]",
"repositoryToken": "[parameters('repositoryToken')]",
"buildProperties": {
"appLocation": "[parameters('staticSiteAppLocation')]",
"apiLocation": "[parameters('staticSiteApiLocation')]",
"appArtifactLocation": "[parameters('staticSiteAppArtifactLocation')]"
}
}
}
]
}