Skip to content

Commit

Permalink
Add Storage file share app settings; Resolve Bicep lint warnings.
Browse files Browse the repository at this point in the history
  • Loading branch information
mcollier committed Apr 21, 2023
1 parent 72cb581 commit 5c117e9
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 10 deletions.
10 changes: 4 additions & 6 deletions src/az-func-http/deploy/bicep/main.bicep
Original file line number Diff line number Diff line change
Expand Up @@ -124,12 +124,10 @@ resource additionalAppSettings 'Microsoft.Web/sites/config@2021-01-15' = {
APPINSIGHTS_INSTRUMENTATIONKEY: '@Microsoft.KeyVault(SecretUri=${appInsightsInstrumentationKeyKeyVaultSecret.properties.secretUriWithVersion})'
FUNCTIONS_EXTENSION_VERSION: '~4'
FUNCTIONS_WORKER_RUNTIME: 'python'

// Set the below settings if using a Windows plan.
// WEBSITE_CONTENTAZUREFILECONNECTIONSTRING: '@Microsoft.KeyVault(storageAccount.outputs.storageAccountConnectionStringSecretUriWithVersion})'
// WEBSITE_CONTENTSHARE: fileShareName
// WEBSITE_CONTENTOVERVNET: '1'
// WEBSITE_SKIP_CONTENTSHARE_VALIDATION: '1'
WEBSITE_CONTENTAZUREFILECONNECTIONSTRING: '@Microsoft.KeyVault(SecretUri=${storageAccount.outputs.storageAccountConnectionStringSecretUriWithVersion})'
WEBSITE_CONTENTOVERVNET: '1'
WEBSITE_CONTENTSHARE: fileShareName
WEBSITE_SKIP_CONTENTSHARE_VALIDATION: '1'
}
}

Expand Down
2 changes: 1 addition & 1 deletion src/common/infrastructure/bicep/azure-functions.bicep
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ resource azureFunction 'Microsoft.Web/sites@2020-12-01' = {
siteConfig: {
vnetRouteAllEnabled: vnetRouteAllEnabled
functionsRuntimeScaleMonitoringEnabled: true
linuxFxVersion: isReserved ? linuxRuntime : json('null')
linuxFxVersion: isReserved ? linuxRuntime : null
appSettings: [
{
name: 'FUNCTIONS_EXTENSION_VERSION'
Expand Down
10 changes: 7 additions & 3 deletions src/common/infrastructure/bicep/private-storage.bicep
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,14 @@ resource storageAccount 'Microsoft.Storage/storageAccounts@2021-02-01' = {
bypass: 'None'
}
}
}

resource storageAccountFileShare 'Microsoft.Storage/storageAccounts/fileServices/shares@2021-02-01' = {
name: '${storageAccount.name}/default/${fileShareName}'
resource service 'fileServices' = {
name: 'default'

resource share 'shares' = {
name: fileShareName
}
}
}

// -- Private Endpoints --
Expand Down

0 comments on commit 5c117e9

Please sign in to comment.