Changed webapp deployment and setup

This commit is contained in:
Pieter
2021-06-09 16:19:51 +02:00
parent 263e1ae7fa
commit 66ad8b311a
2 changed files with 17 additions and 37 deletions
@@ -117,7 +117,7 @@ resource AssignAttestationReader_Resource 'Microsoft.Authorization/roleAssignmen
// Configure the web application //
///////////////////////////////////
// Create an App Service plan in Free tier
// Create an App Service plan
resource WebAppServicePlan_Resource 'Microsoft.Web/serverfarms@2020-12-01' = {
name: '${projectName}plan'
location: location
@@ -158,33 +158,6 @@ resource WebApp_Resource 'Microsoft.Web/sites@2020-12-01' = {
}
}
// Set the database connection string for the application
// resource WebAppConnectionString_Resource 'Microsoft.Web/sites/config@2020-09-01' = {
// name: '${WebApp_Resource.name}/connectionstrings'
// properties: {
// ContosoHRDatabase: {
// value: 'Server=tcp:${Server_Name_resource.name}.database.windows.net;Database=ContosoHR;Column Encryption Setting=Enabled; Attestation Protocol = AAS; Enclave Attestation Url=${attestationProviderName_resource.properties.attestUri}/attest/SgxEnclave; Authentication=Active Directory Managed Identity'
// type: 'SQLAzure'
// }
// }
// dependsOn: [
// WebApp_Resource
// ]
// }
// // Deploy the application
// resource siteName_web 'Microsoft.Web/sites/sourcecontrols@2015-04-01' = {
// name: '${WebApp_Resource.name}/web'
// properties: {
// RepoUrl: 'https://github.com/Pietervanhove/AEDemo.git'
// branch: 'master'
// IsManualIntegration: true
// }
// dependsOn: [
// WebApp_Resource
// ]
// }
//////////////////////////////////////
// Create and configure a key vault //
@@ -35,16 +35,23 @@ New-AzResourceGroup -Name $resourceGroupName -Location $location
######################################################################
# Deploy the resources for the demo environment
######################################################################
az deployment group create --name DeployAEWithEnclavesDemo --template-file $bicepFile --resource-group $resourceGroupName --parameters `
projectName=$projectName `
userObjectId=$userObjectId `
userName=$userName `
sqlAdminUserName=$sqlAdminUserName `
sqlAdminPassword=$sqlAdminPassword `
clientIP=$clientIP
New-AzResourceGroupDeployment `
-ResourceGroupName $resourceGroupName `
-TemplateFile $bicepFile `
-projectName $projectName `
-userObjectId $userObjectId `
-userName $userName `
-sqlAdminUserName $sqlAdminUserName `
-sqlAdminPassword $sqlAdminPassword `
-clientIP $clientIP
#New-AzResourceGroupDeployment `
# -ResourceGroupName $resourceGroupName `
# -TemplateFile $bicepFile `
# -projectName $projectName `
# -userObjectId $userObjectId `
# -userName $userName `
# -sqlAdminUserName $sqlAdminUserName `
# -sqlAdminPassword $sqlAdminPassword `
# -clientIP $clientIP
######################################################################
# Populate the database with data