diff --git a/constructs/Compute/virtualMachinesMultiple/README.md b/constructs/Compute/virtualMachinesMultiple/README.md index 19266955b9..81b6f034e7 100644 --- a/constructs/Compute/virtualMachinesMultiple/README.md +++ b/constructs/Compute/virtualMachinesMultiple/README.md @@ -67,7 +67,6 @@ This module deploys one or multiple Virtual Machines. | `dedicatedHostId` | string | `''` | | Specifies resource ID about the dedicated host that the virtual machine resides in. | | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | | `diagnosticWorkspaceId` | string | `''` | | Resource ID of the diagnostic log analytics workspace. | | `disablePasswordAuthentication` | bool | `False` | | Specifies whether password authentication should be disabled. | diff --git a/constructs/Compute/virtualMachinesMultiple/main.bicep b/constructs/Compute/virtualMachinesMultiple/main.bicep index 42e9527e8a..9fc00d6f9e 100644 --- a/constructs/Compute/virtualMachinesMultiple/main.bicep +++ b/constructs/Compute/virtualMachinesMultiple/main.bicep @@ -230,11 +230,6 @@ param extensionCustomScriptProtectedSetting object = {} @description('Optional. Location for all resources.') param location string = resourceGroup().location -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -301,7 +296,7 @@ var vmNamesToApply = !empty(vmNames) ? vmNames : vmGeneratedNames var enableReferencedModulesTelemetry = false -module virtualMachine '../../../modules/Compute/virtualMachines/main.bicep' = [for (vmName, index) in vmNamesToApply: { +module virtualMachine '../../../modules/compute/virtual-machine/main.bicep' = [for (vmName, index) in vmNamesToApply: { name: '${deployment().name}-vm-${index}' params: { name: vmName @@ -328,7 +323,6 @@ module virtualMachine '../../../modules/Compute/virtualMachines/main.bicep' = [f dedicatedHostId: dedicatedHostId diagnosticEventHubAuthorizationRuleId: diagnosticEventHubAuthorizationRuleId diagnosticEventHubName: diagnosticEventHubName - diagnosticLogsRetentionInDays: diagnosticLogsRetentionInDays diagnosticStorageAccountId: diagnosticStorageAccountId diagnosticWorkspaceId: diagnosticWorkspaceId disablePasswordAuthentication: disablePasswordAuthentication diff --git a/constructs/Network/virtualNetwork/virtualNetworkPeeringsMultiRemoteVnets/README.md b/constructs/Network/virtualNetwork/virtualNetworkPeeringsMultiRemoteVnets/README.md index dcbcc3715e..6a06b43945 100644 --- a/constructs/Network/virtualNetwork/virtualNetworkPeeringsMultiRemoteVnets/README.md +++ b/constructs/Network/virtualNetwork/virtualNetworkPeeringsMultiRemoteVnets/README.md @@ -13,7 +13,7 @@ This template deploys Virtual Network Peering. | Resource Type | API Version | | :-- | :-- | -| `Microsoft.Network/virtualNetworks/virtualNetworkPeerings` | [2021-08-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2021-08-01/virtualNetworks/virtualNetworkPeerings) | +| `Microsoft.Network/virtualNetworks/virtualNetworkPeerings` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/virtualnetworks/virtualnetworkpeerings) | ## Parameters diff --git a/constructs/Network/virtualNetwork/virtualNetworkPeeringsMultiRemoteVnets/main.bicep b/constructs/Network/virtualNetwork/virtualNetworkPeeringsMultiRemoteVnets/main.bicep index d2db3767e0..9a6eedc849 100644 --- a/constructs/Network/virtualNetwork/virtualNetworkPeeringsMultiRemoteVnets/main.bicep +++ b/constructs/Network/virtualNetwork/virtualNetworkPeeringsMultiRemoteVnets/main.bicep @@ -19,7 +19,7 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -module virtualNetworkPeering '../../../../modules/Network/virtualNetworks/virtualNetworkPeerings/main.bicep' = [for peeringConfiguration in peeringConfigurations: { +module virtualNetworkPeering '../../../../modules/network/virtual-network/virtual-network-peering/main.bicep' = [for peeringConfiguration in peeringConfigurations: { name: 'virtualNetworkPeering-${last(split(peeringConfiguration.remoteVirtualNetworkId, '/'))}' params: { name: contains(peeringConfiguration, 'peeringName') ? '${peeringConfiguration.peeringName}' : '${localVnetName}-${last(split(peeringConfiguration.remoteVirtualNetworkId, '/'))}' diff --git a/docs/wiki/The library - Module design.md b/docs/wiki/The library - Module design.md index 8be0455ffb..b1ad89c38c 100644 --- a/docs/wiki/The library - Module design.md +++ b/docs/wiki/The library - Module design.md @@ -295,10 +295,6 @@ The diagnostic settings may differ slightly, from resource to resource. Most not Details ```bicep -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -336,20 +332,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -357,10 +345,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] resource _diagnosticSettings 'Microsoft.Insights/diagnosticsettings@2021-05-01-preview' = if (!empty(diagnosticStorageAccountId) || !empty(diagnosticWorkspaceId) || !empty(diagnosticEventHubAuthorizationRuleId) || !empty(diagnosticEventHubName)) { diff --git a/modules/aad/domain-service/.test/common/dependencies.bicep b/modules/aad/domain-service/.test/common/dependencies.bicep index f8b131d624..0790bd447a 100644 --- a/modules/aad/domain-service/.test/common/dependencies.bicep +++ b/modules/aad/domain-service/.test/common/dependencies.bicep @@ -17,75 +17,75 @@ var certPWSecretName = 'pfxCertificatePassword' var certSecretName = 'pfxBase64Certificate' var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource keyVault 'Microsoft.KeyVault/vaults@2022-07-01' = { - name: keyVaultName - location: location - properties: { - sku: { - family: 'A' - name: 'standard' - } - tenantId: tenant().tenantId - enablePurgeProtection: null - enabledForTemplateDeployment: true - enabledForDiskEncryption: true - enabledForDeployment: true - enableRbacAuthorization: true - accessPolicies: [] + name: keyVaultName + location: location + properties: { + sku: { + family: 'A' + name: 'standard' } + tenantId: tenant().tenantId + enablePurgeProtection: null + enabledForTemplateDeployment: true + enabledForDiskEncryption: true + enabledForDeployment: true + enableRbacAuthorization: true + accessPolicies: [] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource keyPermissions 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid('msi-${managedIdentity.name}-KeyVault-Admin-RoleAssignment') - scope: keyVault - properties: { - principalId: managedIdentity.properties.principalId - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '00482a5a-887f-4fb3-b363-3b7fe8e74483') // Key Vault Administrator - principalType: 'ServicePrincipal' - } + name: guid('msi-${managedIdentity.name}-KeyVault-Admin-RoleAssignment') + scope: keyVault + properties: { + principalId: managedIdentity.properties.principalId + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '00482a5a-887f-4fb3-b363-3b7fe8e74483') // Key Vault Administrator + principalType: 'ServicePrincipal' + } } resource certDeploymentScript 'Microsoft.Resources/deploymentScripts@2020-10-01' = { - name: certDeploymentScriptName - location: location - kind: 'AzurePowerShell' - identity: { - type: 'UserAssigned' - userAssignedIdentities: { - '${managedIdentity.id}': {} - } - } - properties: { - azPowerShellVersion: '3.0' - retentionInterval: 'P1D' - arguments: ' -KeyVaultName "${keyVault.name}" -ResourceGroupName "${resourceGroup().name}" -CertPWSecretName "${certPWSecretName}" -CertSecretName "${certSecretName}"' - scriptContent: loadTextContent('../../../../.shared/.scripts/Set-PfxCertificateInKeyVault.ps1') + name: certDeploymentScriptName + location: location + kind: 'AzurePowerShell' + identity: { + type: 'UserAssigned' + userAssignedIdentities: { + '${managedIdentity.id}': {} } + } + properties: { + azPowerShellVersion: '3.0' + retentionInterval: 'P1D' + arguments: ' -KeyVaultName "${keyVault.name}" -ResourceGroupName "${resourceGroup().name}" -CertPWSecretName "${certPWSecretName}" -CertSecretName "${certSecretName}"' + scriptContent: loadTextContent('../../../../.shared/.scripts/Set-PfxCertificateInKeyVault.ps1') + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/aad/domain-service/.test/common/main.test.bicep b/modules/aad/domain-service/.test/common/main.test.bicep index d75646823c..39ebef747d 100644 --- a/modules/aad/domain-service/.test/common/main.test.bicep +++ b/modules/aad/domain-service/.test/common/main.test.bicep @@ -75,7 +75,6 @@ module testDeployment '../../main.bicep' = { additionalRecipients: [ '${namePrefix}@noreply.github.com' ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/aad/domain-service/README.md b/modules/aad/domain-service/README.md index 5f254cf354..14813acc04 100644 --- a/modules/aad/domain-service/README.md +++ b/modules/aad/domain-service/README.md @@ -43,7 +43,6 @@ This module deploys an Azure Active Directory Domain Services (AADDS). | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', AccountLogon, AccountManagement, allLogs, DetailTracking, DirectoryServiceAccess, LogonLogoff, ObjectAccess, PolicyChange, PrivilegeUse, SystemSecurity]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | | `diagnosticWorkspaceId` | string | `''` | | Resource ID of the diagnostic log analytics workspace. | | `domainConfigurationType` | string | `'FullySynced'` | `[FullySynced, ResourceTrusting]` | The value is to provide domain configuration type. | @@ -238,7 +237,6 @@ module domainService './aad/domain-service/main.bicep' = { ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -289,9 +287,6 @@ module domainService './aad/domain-service/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/aad/domain-service/main.bicep b/modules/aad/domain-service/main.bicep index 8e33c8f9b0..e8aa4ad471 100644 --- a/modules/aad/domain-service/main.bicep +++ b/modules/aad/domain-service/main.bicep @@ -130,11 +130,6 @@ param diagnosticEventHubName string = '' @description('Optional. Tags of the resource.') param tags object = {} -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Enable telemetry via a Globally Unique Identifier (GUID).') param enableDefaultTelemetry bool = true @@ -170,20 +165,12 @@ param diagnosticLogCategoriesToEnable array = [ var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified diff --git a/modules/aad/domain-service/main.json b/modules/aad/domain-service/main.json index 8451da0e89..d7c212e90c 100644 --- a/modules/aad/domain-service/main.json +++ b/modules/aad/domain-service/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7212864402192809754" - } + "version": "0.20.4.51522", + "templateHash": "11963708843565725905" + }, + "name": "Azure Active Directory Domain Services", + "description": "This module deploys an Azure Active Directory Domain Services (AADDS).", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -232,15 +235,6 @@ "description": "Optional. Tags of the resource." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "enableDefaultTelemetry": { "type": "bool", "defaultValue": true, @@ -251,14 +245,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -297,15 +291,11 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" }, "resources": [ { @@ -420,8 +410,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1835196590744677033" + "version": "0.20.4.51522", + "templateHash": "1057451730185252367" } }, "parameters": { diff --git a/modules/analysis-services/server/.test/common/main.test.bicep b/modules/analysis-services/server/.test/common/main.test.bicep index b5ad65e147..ad76d1af43 100644 --- a/modules/analysis-services/server/.test/common/main.test.bicep +++ b/modules/analysis-services/server/.test/common/main.test.bicep @@ -74,7 +74,6 @@ module testDeployment '../../main.bicep' = { principalType: 'ServicePrincipal' } ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/analysis-services/server/.test/max/main.test.bicep b/modules/analysis-services/server/.test/max/main.test.bicep index a0448bdaa0..582c804860 100644 --- a/modules/analysis-services/server/.test/max/main.test.bicep +++ b/modules/analysis-services/server/.test/max/main.test.bicep @@ -85,7 +85,6 @@ module testDeployment '../../main.bicep' = { principalType: 'ServicePrincipal' } ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/analysis-services/server/README.md b/modules/analysis-services/server/README.md index 320ede300c..b01b46f8b3 100644 --- a/modules/analysis-services/server/README.md +++ b/modules/analysis-services/server/README.md @@ -34,7 +34,6 @@ This module deploys an Analysis Services Server. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, Engine, Service]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -184,7 +183,6 @@ module server './analysis-services/server/main.bicep' = { // Non-required parameters diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -230,9 +228,6 @@ module server './analysis-services/server/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, @@ -291,7 +286,6 @@ module server './analysis-services/server/main.bicep' = { 'Engine' 'Service' ] - diagnosticLogsRetentionInDays: 7 diagnosticMetricsToEnable: [ 'AllMetrics' ] @@ -353,9 +347,6 @@ module server './analysis-services/server/main.bicep' = { "Service" ] }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticMetricsToEnable": { "value": [ "AllMetrics" diff --git a/modules/analysis-services/server/main.bicep b/modules/analysis-services/server/main.bicep index 178798e9db..0b0ca98d44 100644 --- a/modules/analysis-services/server/main.bicep +++ b/modules/analysis-services/server/main.bicep @@ -26,11 +26,6 @@ param firewallSettings object = { @description('Optional. Location for all Resources.') param location string = resourceGroup().location -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -85,20 +80,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -106,10 +93,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (enableDefaultTelemetry) { diff --git a/modules/analysis-services/server/main.json b/modules/analysis-services/server/main.json index b50b4ddb8c..034f53242c 100644 --- a/modules/analysis-services/server/main.json +++ b/modules/analysis-services/server/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9546583248614187167" - } + "version": "0.20.4.51522", + "templateHash": "10064223785329368726" + }, + "name": "Analysis Services Servers", + "description": "This module deploys an Analysis Services Server.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -52,15 +55,6 @@ "description": "Optional. Location for all Resources." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -92,14 +86,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -164,11 +158,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -177,15 +167,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" }, "resources": [ { @@ -282,8 +268,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11608096580745695876" + "version": "0.20.4.51522", + "templateHash": "15590714007425491246" } }, "parameters": { diff --git a/modules/api-management/service/.test/max/main.test.bicep b/modules/api-management/service/.test/max/main.test.bicep index 0ffbd7d57d..daf0f7f8ad 100644 --- a/modules/api-management/service/.test/max/main.test.bicep +++ b/modules/api-management/service/.test/max/main.test.bicep @@ -117,7 +117,6 @@ module testDeployment '../../main.bicep' = { useFromLocation: 'westeurope' } ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/api-management/service/README.md b/modules/api-management/service/README.md index 5a6a3c57a6..0aa2f605e6 100644 --- a/modules/api-management/service/README.md +++ b/modules/api-management/service/README.md @@ -59,7 +59,6 @@ This module deploys an API Management Service. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, GatewayLogs]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -484,7 +483,6 @@ module service './api-management/service/main.bicep' = { ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -653,9 +651,6 @@ module service './api-management/service/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/api-management/service/api-version-set/main.json b/modules/api-management/service/api-version-set/main.json index cfe229a07b..f09d56ff92 100644 --- a/modules/api-management/service/api-version-set/main.json +++ b/modules/api-management/service/api-version-set/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5488393470456105245" - } + "version": "0.20.4.51522", + "templateHash": "9352626903654043411" + }, + "name": "API Management Service API Version Sets", + "description": "This module deploys an API Management Service API Version Set.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { diff --git a/modules/api-management/service/api/main.json b/modules/api-management/service/api/main.json index a83f4ed2f0..08c998bf80 100644 --- a/modules/api-management/service/api/main.json +++ b/modules/api-management/service/api/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2877903221973830932" - } + "version": "0.20.4.51522", + "templateHash": "9074052005199170712" + }, + "name": "API Management Service APIs", + "description": "This module deploys an API Management Service API.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -281,9 +284,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14535247884365099462" - } + "version": "0.20.4.51522", + "templateHash": "5031714372762112092" + }, + "name": "API Management Service APIs Policies", + "description": "This module deploys an API Management Service API Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { diff --git a/modules/api-management/service/api/policy/main.json b/modules/api-management/service/api/policy/main.json index 0f1748fbf4..76457b0c2f 100644 --- a/modules/api-management/service/api/policy/main.json +++ b/modules/api-management/service/api/policy/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14535247884365099462" - } + "version": "0.20.4.51522", + "templateHash": "5031714372762112092" + }, + "name": "API Management Service APIs Policies", + "description": "This module deploys an API Management Service API Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { diff --git a/modules/api-management/service/authorization-server/main.json b/modules/api-management/service/authorization-server/main.json index 5425db1054..d956cf25f5 100644 --- a/modules/api-management/service/authorization-server/main.json +++ b/modules/api-management/service/authorization-server/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16113108844531678160" - } + "version": "0.20.4.51522", + "templateHash": "8155815469027179886" + }, + "name": "API Management Service Authorization Servers", + "description": "This module deploys an API Management Service Authorization Server.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/api-management/service/backend/main.json b/modules/api-management/service/backend/main.json index 515fde20f7..17c351e22a 100644 --- a/modules/api-management/service/backend/main.json +++ b/modules/api-management/service/backend/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10485477109069205796" - } + "version": "0.20.4.51522", + "templateHash": "1669725941639871055" + }, + "name": "API Management Service Backends", + "description": "This module deploys an API Management Service Backend.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { diff --git a/modules/api-management/service/cache/main.json b/modules/api-management/service/cache/main.json index a606438e2b..662943675f 100644 --- a/modules/api-management/service/cache/main.json +++ b/modules/api-management/service/cache/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14901031265236109470" - } + "version": "0.20.4.51522", + "templateHash": "17031319637382778576" + }, + "name": "API Management Service Caches", + "description": "This module deploys an API Management Service Cache.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { diff --git a/modules/api-management/service/identity-provider/main.json b/modules/api-management/service/identity-provider/main.json index 35fbc544d2..12777acfdc 100644 --- a/modules/api-management/service/identity-provider/main.json +++ b/modules/api-management/service/identity-provider/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5110602870020980101" - } + "version": "0.20.4.51522", + "templateHash": "17041253664250888675" + }, + "name": "API Management Service Identity Providers", + "description": "This module deploys an API Management Service Identity Provider.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { diff --git a/modules/api-management/service/main.bicep b/modules/api-management/service/main.bicep index 3d7e8e488c..cdc0d4c0d6 100644 --- a/modules/api-management/service/main.bicep +++ b/modules/api-management/service/main.bicep @@ -18,11 +18,6 @@ param enableDefaultTelemetry bool = true @description('Optional. Custom properties of the API Management service.') param customProperties object = {} -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -177,20 +172,12 @@ var authorizationServerList = !empty(authorizationServers) ? authorizationServer var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -198,10 +185,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var identityType = systemAssignedIdentity ? (!empty(userAssignedIdentities) ? 'SystemAssigned,UserAssigned' : 'SystemAssigned') : (!empty(userAssignedIdentities) ? 'UserAssigned' : 'None') diff --git a/modules/api-management/service/main.json b/modules/api-management/service/main.json index 3e8af8e080..466bded3f4 100644 --- a/modules/api-management/service/main.json +++ b/modules/api-management/service/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11470399654102963558" - } + "version": "0.20.4.51522", + "templateHash": "11924576523256910990" + }, + "name": "API Management Services", + "description": "This module deploys an API Management Service.", + "owner": "Azure/module-maintainers" }, "parameters": { "additionalLocations": { @@ -44,15 +47,6 @@ "description": "Optional. Custom properties of the API Management service." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -119,14 +113,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "minApiVersion": { "type": "string", @@ -358,11 +352,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -371,17 +361,13 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], "enableReferencedModulesTelemetry": false, "authorizationServerList": "[if(not(empty(parameters('authorizationServers'))), parameters('authorizationServers').secureList, createArray())]", - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "identityType": "[if(parameters('systemAssignedIdentity'), if(not(empty(parameters('userAssignedIdentities'))), 'SystemAssigned,UserAssigned', 'SystemAssigned'), if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None'))]", "identity": "[if(not(equals(variables('identityType'), 'None')), createObject('type', variables('identityType'), 'userAssignedIdentities', if(not(empty(parameters('userAssignedIdentities'))), parameters('userAssignedIdentities'), null())), null())]" }, @@ -515,9 +501,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2877903221973830932" - } + "version": "0.20.4.51522", + "templateHash": "9074052005199170712" + }, + "name": "API Management Service APIs", + "description": "This module deploys an API Management Service API.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -792,9 +781,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14535247884365099462" - } + "version": "0.20.4.51522", + "templateHash": "5031714372762112092" + }, + "name": "API Management Service APIs Policies", + "description": "This module deploys an API Management Service API Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { @@ -959,9 +951,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5488393470456105245" - } + "version": "0.20.4.51522", + "templateHash": "9352626903654043411" + }, + "name": "API Management Service API Version Sets", + "description": "This module deploys an API Management Service API Version Set.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { @@ -1096,9 +1091,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16113108844531678160" - } + "version": "0.20.4.51522", + "templateHash": "8155815469027179886" + }, + "name": "API Management Service Authorization Servers", + "description": "This module deploys an API Management Service Authorization Server.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1341,9 +1339,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10485477109069205796" - } + "version": "0.20.4.51522", + "templateHash": "1669725941639871055" + }, + "name": "API Management Service Backends", + "description": "This module deploys an API Management Service Backend.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { @@ -1532,9 +1533,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14901031265236109470" - } + "version": "0.20.4.51522", + "templateHash": "17031319637382778576" + }, + "name": "API Management Service Caches", + "description": "This module deploys an API Management Service Cache.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { @@ -1680,9 +1684,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5110602870020980101" - } + "version": "0.20.4.51522", + "templateHash": "17041253664250888675" + }, + "name": "API Management Service Identity Providers", + "description": "This module deploys an API Management Service Identity Provider.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { @@ -1893,9 +1900,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7564868053605703508" - } + "version": "0.20.4.51522", + "templateHash": "7537918735725646871" + }, + "name": "API Management Service Named Values", + "description": "This module deploys an API Management Service Named Value.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { @@ -2043,9 +2053,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4856642569874165602" - } + "version": "0.20.4.51522", + "templateHash": "11909172258549553650" + }, + "name": "API Management Service Portal Settings", + "description": "This module deploys an API Management Service Portal Setting.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { @@ -2163,9 +2176,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8916467929496361160" - } + "version": "0.20.4.51522", + "templateHash": "8348924989076719813" + }, + "name": "API Management Service Policies", + "description": "This module deploys an API Management Service Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { @@ -2300,9 +2316,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16475090457313931987" - } + "version": "0.20.4.51522", + "templateHash": "11659142408016307537" + }, + "name": "API Management Service Products", + "description": "This module deploys an API Management Service Product.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { @@ -2446,9 +2465,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12089259943011536891" - } + "version": "0.20.4.51522", + "templateHash": "13243242177616383868" + }, + "name": "API Management Service Products APIs", + "description": "This module deploys an API Management Service Product API.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { @@ -2557,9 +2579,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11103836419434676307" - } + "version": "0.20.4.51522", + "templateHash": "11867976378445976169" + }, + "name": "API Management Service Products Groups", + "description": "This module deploys an API Management Service Product Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { @@ -2720,9 +2745,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12367355015017633052" - } + "version": "0.20.4.51522", + "templateHash": "15277659663277232184" + }, + "name": "API Management Service Subscriptions", + "description": "This module deploys an API Management Service Subscription.", + "owner": "Azure/module-maintainers" }, "parameters": { "allowTracing": { @@ -2880,8 +2908,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2137109478394702779" + "version": "0.20.4.51522", + "templateHash": "10733405494558281066" } }, "parameters": { diff --git a/modules/api-management/service/named-value/main.json b/modules/api-management/service/named-value/main.json index 417ad16f86..c75a4a3928 100644 --- a/modules/api-management/service/named-value/main.json +++ b/modules/api-management/service/named-value/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7564868053605703508" - } + "version": "0.20.4.51522", + "templateHash": "7537918735725646871" + }, + "name": "API Management Service Named Values", + "description": "This module deploys an API Management Service Named Value.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { diff --git a/modules/api-management/service/policy/main.json b/modules/api-management/service/policy/main.json index bfc425aa16..65580b17b4 100644 --- a/modules/api-management/service/policy/main.json +++ b/modules/api-management/service/policy/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8916467929496361160" - } + "version": "0.20.4.51522", + "templateHash": "8348924989076719813" + }, + "name": "API Management Service Policies", + "description": "This module deploys an API Management Service Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { diff --git a/modules/api-management/service/portalsetting/main.json b/modules/api-management/service/portalsetting/main.json index 3d23b87e0d..174392d0e0 100644 --- a/modules/api-management/service/portalsetting/main.json +++ b/modules/api-management/service/portalsetting/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4856642569874165602" - } + "version": "0.20.4.51522", + "templateHash": "11909172258549553650" + }, + "name": "API Management Service Portal Settings", + "description": "This module deploys an API Management Service Portal Setting.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { diff --git a/modules/api-management/service/product/api/main.json b/modules/api-management/service/product/api/main.json index 4619016a4b..157c8181f7 100644 --- a/modules/api-management/service/product/api/main.json +++ b/modules/api-management/service/product/api/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12089259943011536891" - } + "version": "0.20.4.51522", + "templateHash": "13243242177616383868" + }, + "name": "API Management Service Products APIs", + "description": "This module deploys an API Management Service Product API.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { diff --git a/modules/api-management/service/product/group/main.json b/modules/api-management/service/product/group/main.json index 44041f695b..de5f8ef5c8 100644 --- a/modules/api-management/service/product/group/main.json +++ b/modules/api-management/service/product/group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11103836419434676307" - } + "version": "0.20.4.51522", + "templateHash": "11867976378445976169" + }, + "name": "API Management Service Products Groups", + "description": "This module deploys an API Management Service Product Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { diff --git a/modules/api-management/service/product/main.json b/modules/api-management/service/product/main.json index a1b3ef1f1d..172a816f4f 100644 --- a/modules/api-management/service/product/main.json +++ b/modules/api-management/service/product/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16475090457313931987" - } + "version": "0.20.4.51522", + "templateHash": "11659142408016307537" + }, + "name": "API Management Service Products", + "description": "This module deploys an API Management Service Product.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { @@ -150,9 +153,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12089259943011536891" - } + "version": "0.20.4.51522", + "templateHash": "13243242177616383868" + }, + "name": "API Management Service Products APIs", + "description": "This module deploys an API Management Service Product API.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { @@ -261,9 +267,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11103836419434676307" - } + "version": "0.20.4.51522", + "templateHash": "11867976378445976169" + }, + "name": "API Management Service Products Groups", + "description": "This module deploys an API Management Service Product Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "apiManagementServiceName": { diff --git a/modules/api-management/service/subscription/main.json b/modules/api-management/service/subscription/main.json index e74886e83f..2ca7d5862e 100644 --- a/modules/api-management/service/subscription/main.json +++ b/modules/api-management/service/subscription/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12367355015017633052" - } + "version": "0.20.4.51522", + "templateHash": "15277659663277232184" + }, + "name": "API Management Service Subscriptions", + "description": "This module deploys an API Management Service Subscription.", + "owner": "Azure/module-maintainers" }, "parameters": { "allowTracing": { diff --git a/modules/app-configuration/configuration-store/.test/common/main.test.bicep b/modules/app-configuration/configuration-store/.test/common/main.test.bicep index 10563eb418..46047d29bc 100644 --- a/modules/app-configuration/configuration-store/.test/common/main.test.bicep +++ b/modules/app-configuration/configuration-store/.test/common/main.test.bicep @@ -64,7 +64,6 @@ module testDeployment '../../main.bicep' = { enableDefaultTelemetry: enableDefaultTelemetry name: '${namePrefix}${serviceShort}001' createMode: 'Default' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/app-configuration/configuration-store/.test/pe/dependencies.bicep b/modules/app-configuration/configuration-store/.test/pe/dependencies.bicep index a92ed9b76a..ca28691a17 100644 --- a/modules/app-configuration/configuration-store/.test/pe/dependencies.bicep +++ b/modules/app-configuration/configuration-store/.test/pe/dependencies.bicep @@ -6,7 +6,7 @@ param location string = resourceGroup().location var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkName location: location properties: { diff --git a/modules/app-configuration/configuration-store/README.md b/modules/app-configuration/configuration-store/README.md index 96101fecc6..23edaceeaf 100644 --- a/modules/app-configuration/configuration-store/README.md +++ b/modules/app-configuration/configuration-store/README.md @@ -19,8 +19,8 @@ This module deploys an App Configuration Store. | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | ## Parameters @@ -38,7 +38,6 @@ This module deploys an App Configuration Store. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, Audit, HttpRequest]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -333,7 +332,6 @@ module configurationStore './app-configuration/configuration-store/main.bicep' = createMode: 'Default' diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' disableLocalAuth: false @@ -401,9 +399,6 @@ module configurationStore './app-configuration/configuration-store/main.bicep' = "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/app-configuration/configuration-store/key-value/main.json b/modules/app-configuration/configuration-store/key-value/main.json index 3edf1d060b..69e7caf120 100644 --- a/modules/app-configuration/configuration-store/key-value/main.json +++ b/modules/app-configuration/configuration-store/key-value/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11694174927127142874" - } + "version": "0.20.4.51522", + "templateHash": "18125120019454222929" + }, + "name": "App Configuration Stores Key Values", + "description": "This module deploys an App Configuration Store Key Value.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/app-configuration/configuration-store/main.bicep b/modules/app-configuration/configuration-store/main.bicep index fe242a7844..f3943eb2ba 100644 --- a/modules/app-configuration/configuration-store/main.bicep +++ b/modules/app-configuration/configuration-store/main.bicep @@ -50,11 +50,6 @@ param softDeleteRetentionInDays int = 1 @description('Optional. All Key / Values to create.') param keyValues array = [] -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -114,20 +109,12 @@ var enableReferencedModulesTelemetry = false var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -135,10 +122,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var identityType = systemAssignedIdentity ? 'SystemAssigned' : !empty(userAssignedIdentities) ? 'UserAssigned' : 'None' diff --git a/modules/app-configuration/configuration-store/main.json b/modules/app-configuration/configuration-store/main.json index d8a6ae0bd4..84bf22d70e 100644 --- a/modules/app-configuration/configuration-store/main.json +++ b/modules/app-configuration/configuration-store/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14681467525006388511" - } + "version": "0.20.4.51522", + "templateHash": "10371162736830551365" + }, + "name": "App Configuration Stores", + "description": "This module deploys an App Configuration Store.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -39,24 +42,24 @@ "sku": { "type": "string", "defaultValue": "Standard", - "metadata": { - "description": "Optional. Pricing tier of App Configuration." - }, "allowedValues": [ "Free", "Standard" - ] + ], + "metadata": { + "description": "Optional. Pricing tier of App Configuration." + } }, "createMode": { "type": "string", "defaultValue": "Default", - "metadata": { - "description": "Optional. Indicates whether the configuration store need to be recovered." - }, "allowedValues": [ "Default", "Recover" - ] + ], + "metadata": { + "description": "Optional. Indicates whether the configuration store need to be recovered." + } }, "disableLocalAuth": { "type": "bool", @@ -87,8 +90,8 @@ "softDeleteRetentionInDays": { "type": "int", "defaultValue": 1, - "maxValue": 7, "minValue": 1, + "maxValue": 7, "metadata": { "description": "Optional. The amount of time in days that the configuration store will be retained when it is soft deleted." } @@ -100,15 +103,6 @@ "description": "Optional. All Key / Values to create." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -140,14 +134,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -219,11 +213,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -232,16 +222,12 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], "enableReferencedModulesTelemetry": false, - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "identityType": "[if(parameters('systemAssignedIdentity'), 'SystemAssigned', if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None'))]", "identity": { "type": "[variables('identityType')]", @@ -348,9 +334,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11694174927127142874" - } + "version": "0.20.4.51522", + "templateHash": "18125120019454222929" + }, + "name": "App Configuration Stores Key Values", + "description": "This module deploys an App Configuration Store Key Value.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -482,8 +471,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9214998026819281183" + "version": "0.20.4.51522", + "templateHash": "8595390874320189922" } }, "parameters": { @@ -646,9 +635,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -713,14 +705,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -778,7 +770,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -843,9 +835,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -856,8 +851,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -908,7 +903,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -978,8 +973,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -1149,7 +1144,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } diff --git a/modules/app/container-app/main.json b/modules/app/container-app/main.json index ac3a6178ad..6fa21ef628 100644 --- a/modules/app/container-app/main.json +++ b/modules/app/container-app/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18402842656591712663" - } + "version": "0.20.4.51522", + "templateHash": "811549268081936202" + }, + "name": "Container Apps", + "description": "This module deploys a Container App.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -32,15 +35,15 @@ "ingressTransport": { "type": "string", "defaultValue": "auto", - "metadata": { - "description": "Optional. Ingress transport protocol." - }, "allowedValues": [ "auto", "http", "http2", "tcp" - ] + ], + "metadata": { + "description": "Optional. Ingress transport protocol." + } }, "ingressAllowInsecure": { "type": "bool", @@ -80,13 +83,13 @@ "activeRevisionsMode": { "type": "string", "defaultValue": "Single", - "metadata": { - "description": "Optional. ActiveRevisionsMode controls how active revisions are handled for the Container app." - }, "allowedValues": [ "Multiple", "Single" - ] + ], + "metadata": { + "description": "Optional. ActiveRevisionsMode controls how active revisions are handled for the Container app." + } }, "environmentId": { "type": "string", @@ -97,14 +100,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "tags": { "type": "object", @@ -368,8 +371,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16174564455702406600" + "version": "0.20.4.51522", + "templateHash": "17140491380029994713" } }, "parameters": { diff --git a/modules/app/managed-environment/.test/common/dependencies.bicep b/modules/app/managed-environment/.test/common/dependencies.bicep index 0c98af9fe3..8fddc251f3 100644 --- a/modules/app/managed-environment/.test/common/dependencies.bicep +++ b/modules/app/managed-environment/.test/common/dependencies.bicep @@ -24,7 +24,7 @@ resource logAnalyticsWorkspace 'Microsoft.OperationalInsights/workspaces@2022-10 }) } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-07-01' = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkName location: location properties: { diff --git a/modules/app/managed-environment/main.json b/modules/app/managed-environment/main.json index 88516d1369..deb5e11f77 100644 --- a/modules/app/managed-environment/main.json +++ b/modules/app/managed-environment/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9395681676877884238" - } + "version": "0.20.4.51522", + "templateHash": "6927038014071705356" + }, + "name": "App ManagedEnvironments", + "description": "This module deploys an App Managed Environment (also known as a Container App Environment).", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -45,13 +48,13 @@ "skuName": { "type": "string", "defaultValue": "Consumption", - "metadata": { - "description": "Optional. Managed environment SKU." - }, "allowedValues": [ "Consumption", "Premium" - ] + ], + "metadata": { + "description": "Optional. Managed environment SKU." + } }, "logsDestination": { "type": "string", @@ -146,14 +149,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "workloadProfiles": { "type": "array", @@ -261,8 +264,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12222893390511211948" + "version": "0.20.4.51522", + "templateHash": "11046672918941567596" } }, "parameters": { diff --git a/modules/authorization/lock/main.json b/modules/authorization/lock/main.json index dd10d9fd42..6056d5b30b 100644 --- a/modules/authorization/lock/main.json +++ b/modules/authorization/lock/main.json @@ -4,20 +4,23 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "613260573340848220" - } + "version": "0.20.4.51522", + "templateHash": "2597475384765677035" + }, + "name": "Authorization Locks (All scopes)", + "description": "This module deploys an Authorization Lock at a Subscription or Resource Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "level": { "type": "string", - "metadata": { - "description": "Required. Set lock level." - }, "allowedValues": [ "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Required. Set lock level." + } }, "notes": { "type": "string", @@ -106,9 +109,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15744477094233687901" - } + "version": "0.20.4.51522", + "templateHash": "10927394621764774821" + }, + "name": "Authorization Locks (Subscription scope)", + "description": "This module deploys an Authorization Lock at a Subscription scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -120,13 +126,13 @@ }, "level": { "type": "string", - "metadata": { - "description": "Required. Set lock level." - }, "allowedValues": [ "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Required. Set lock level." + } }, "notes": { "type": "string", @@ -233,9 +239,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9338790793667422174" - } + "version": "0.20.4.51522", + "templateHash": "7885747985110001606" + }, + "name": "Authorization Locks (Resource Group scope)", + "description": "This module deploys an Authorization Lock at a Resource Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -247,13 +256,13 @@ }, "level": { "type": "string", - "metadata": { - "description": "Required. Set lock level." - }, "allowedValues": [ "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Required. Set lock level." + } }, "notes": { "type": "string", diff --git a/modules/authorization/lock/resource-group/main.json b/modules/authorization/lock/resource-group/main.json index e9d5c7defd..25b2ec1b99 100644 --- a/modules/authorization/lock/resource-group/main.json +++ b/modules/authorization/lock/resource-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9338790793667422174" - } + "version": "0.20.4.51522", + "templateHash": "7885747985110001606" + }, + "name": "Authorization Locks (Resource Group scope)", + "description": "This module deploys an Authorization Lock at a Resource Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -18,13 +21,13 @@ }, "level": { "type": "string", - "metadata": { - "description": "Required. Set lock level." - }, "allowedValues": [ "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Required. Set lock level." + } }, "notes": { "type": "string", diff --git a/modules/authorization/lock/subscription/main.json b/modules/authorization/lock/subscription/main.json index 00e36535a2..5664616784 100644 --- a/modules/authorization/lock/subscription/main.json +++ b/modules/authorization/lock/subscription/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15744477094233687901" - } + "version": "0.20.4.51522", + "templateHash": "10927394621764774821" + }, + "name": "Authorization Locks (Subscription scope)", + "description": "This module deploys an Authorization Lock at a Subscription scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -18,13 +21,13 @@ }, "level": { "type": "string", - "metadata": { - "description": "Required. Set lock level." - }, "allowedValues": [ "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Required. Set lock level." + } }, "notes": { "type": "string", diff --git a/modules/authorization/policy-assignment/main.json b/modules/authorization/policy-assignment/main.json index 039205e380..02ae8ce6ee 100644 --- a/modules/authorization/policy-assignment/main.json +++ b/modules/authorization/policy-assignment/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9805735127867120314" - } + "version": "0.20.4.51522", + "templateHash": "16987051403501720199" + }, + "name": "Policy Assignments (All scopes)", + "description": "This module deploys a Policy Assignment at a Management Group, Subscription or Resource Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -223,9 +226,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7958026663340611642" - } + "version": "0.20.4.51522", + "templateHash": "8902545451587564927" + }, + "name": "Policy Assignments (Management Group scope)", + "description": "This module deploys a Policy Assignment at a Management Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -500,9 +506,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16656448416694951710" - } + "version": "0.20.4.51522", + "templateHash": "13568773713405945676" + }, + "name": "Policy Assignments (Subscription scope)", + "description": "This module deploys a Policy Assignment at a Subscription scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -777,9 +786,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10829143557172841315" - } + "version": "0.20.4.51522", + "templateHash": "18205418867751406787" + }, + "name": "Policy Assignments (Resource Group scope)", + "description": "This module deploys a Policy Assignment at a Resource Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/authorization/policy-assignment/management-group/main.json b/modules/authorization/policy-assignment/management-group/main.json index f33d918273..1f346ad116 100644 --- a/modules/authorization/policy-assignment/management-group/main.json +++ b/modules/authorization/policy-assignment/management-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7958026663340611642" - } + "version": "0.20.4.51522", + "templateHash": "8902545451587564927" + }, + "name": "Policy Assignments (Management Group scope)", + "description": "This module deploys a Policy Assignment at a Management Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/authorization/policy-assignment/resource-group/main.json b/modules/authorization/policy-assignment/resource-group/main.json index d7f50faa89..91b95356eb 100644 --- a/modules/authorization/policy-assignment/resource-group/main.json +++ b/modules/authorization/policy-assignment/resource-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10829143557172841315" - } + "version": "0.20.4.51522", + "templateHash": "18205418867751406787" + }, + "name": "Policy Assignments (Resource Group scope)", + "description": "This module deploys a Policy Assignment at a Resource Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/authorization/policy-assignment/subscription/main.json b/modules/authorization/policy-assignment/subscription/main.json index b63bb81cf0..24a4662eca 100644 --- a/modules/authorization/policy-assignment/subscription/main.json +++ b/modules/authorization/policy-assignment/subscription/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16656448416694951710" - } + "version": "0.20.4.51522", + "templateHash": "13568773713405945676" + }, + "name": "Policy Assignments (Subscription scope)", + "description": "This module deploys a Policy Assignment at a Subscription scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/authorization/policy-definition/main.json b/modules/authorization/policy-definition/main.json index 993d56b721..911e3b219b 100644 --- a/modules/authorization/policy-definition/main.json +++ b/modules/authorization/policy-definition/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4122001514474984050" - } + "version": "0.20.4.51522", + "templateHash": "14526788352544918663" + }, + "name": "Policy Definitions (All scopes)", + "description": "This module deploys a Policy Definition at a Management Group or Subscription scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -153,9 +156,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14309814077168618325" - } + "version": "0.20.4.51522", + "templateHash": "14890815799488372081" + }, + "name": "Policy Definitions (Management Group scope)", + "description": "This module deploys a Policy Definition at a Management Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -326,9 +332,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4872290154327272363" - } + "version": "0.20.4.51522", + "templateHash": "14434059777291440353" + }, + "name": "Policy Definitions (Subscription scope)", + "description": "This module deploys a Policy Definition at a Subscription scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/authorization/policy-definition/management-group/main.json b/modules/authorization/policy-definition/management-group/main.json index 126cdcfb60..c1d82a9803 100644 --- a/modules/authorization/policy-definition/management-group/main.json +++ b/modules/authorization/policy-definition/management-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14309814077168618325" - } + "version": "0.20.4.51522", + "templateHash": "14890815799488372081" + }, + "name": "Policy Definitions (Management Group scope)", + "description": "This module deploys a Policy Definition at a Management Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/authorization/policy-definition/subscription/main.json b/modules/authorization/policy-definition/subscription/main.json index 3c20186de6..9d45f6df13 100644 --- a/modules/authorization/policy-definition/subscription/main.json +++ b/modules/authorization/policy-definition/subscription/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4872290154327272363" - } + "version": "0.20.4.51522", + "templateHash": "14434059777291440353" + }, + "name": "Policy Definitions (Subscription scope)", + "description": "This module deploys a Policy Definition at a Subscription scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/authorization/policy-exemption/main.json b/modules/authorization/policy-exemption/main.json index 520b3ada6e..75dce346f6 100644 --- a/modules/authorization/policy-exemption/main.json +++ b/modules/authorization/policy-exemption/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5584436159810024704" - } + "version": "0.20.4.51522", + "templateHash": "2976809537385212941" + }, + "name": "Policy Exemptions (All scopes)", + "description": "This module deploys a Policy Exemption at a Management Group, Subscription or Resource Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -199,9 +202,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18434150449398323118" - } + "version": "0.20.4.51522", + "templateHash": "17592627855612646241" + }, + "name": "Policy Exemptions (Management Group scope)", + "description": "This module deploys a Policy Exemption at a Management Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -407,9 +413,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3561878551919543054" - } + "version": "0.20.4.51522", + "templateHash": "5067037150154630010" + }, + "name": "Policy Exemptions (Subscription scope)", + "description": "This module deploys a Policy Exemption at a Subscription scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -612,9 +621,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5976971954600806249" - } + "version": "0.20.4.51522", + "templateHash": "13048294777047698866" + }, + "name": "Policy Exemptions (Resource Group scope)", + "description": "This module deploys a Policy Exemption at a Resource Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/authorization/policy-exemption/management-group/main.json b/modules/authorization/policy-exemption/management-group/main.json index 91eb3bea33..9d9e463ba8 100644 --- a/modules/authorization/policy-exemption/management-group/main.json +++ b/modules/authorization/policy-exemption/management-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18434150449398323118" - } + "version": "0.20.4.51522", + "templateHash": "17592627855612646241" + }, + "name": "Policy Exemptions (Management Group scope)", + "description": "This module deploys a Policy Exemption at a Management Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/authorization/policy-exemption/resource-group/main.json b/modules/authorization/policy-exemption/resource-group/main.json index f3ee5c215c..f9d5590f54 100644 --- a/modules/authorization/policy-exemption/resource-group/main.json +++ b/modules/authorization/policy-exemption/resource-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5976971954600806249" - } + "version": "0.20.4.51522", + "templateHash": "13048294777047698866" + }, + "name": "Policy Exemptions (Resource Group scope)", + "description": "This module deploys a Policy Exemption at a Resource Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/authorization/policy-exemption/subscription/main.json b/modules/authorization/policy-exemption/subscription/main.json index 1c7104aab5..2418e1af36 100644 --- a/modules/authorization/policy-exemption/subscription/main.json +++ b/modules/authorization/policy-exemption/subscription/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3561878551919543054" - } + "version": "0.20.4.51522", + "templateHash": "5067037150154630010" + }, + "name": "Policy Exemptions (Subscription scope)", + "description": "This module deploys a Policy Exemption at a Subscription scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/authorization/policy-set-definition/main.json b/modules/authorization/policy-set-definition/main.json index 9cdc43d639..dac4d81d6f 100644 --- a/modules/authorization/policy-set-definition/main.json +++ b/modules/authorization/policy-set-definition/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9590503753935030573" - } + "version": "0.20.4.51522", + "templateHash": "2811282400533411698" + }, + "name": "Policy Set Definitions (Initiatives) (All scopes)", + "description": "This module deploys a Policy Set Definition (Initiative) at a Management Group or Subscription scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -143,9 +146,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3402211804211188599" - } + "version": "0.20.4.51522", + "templateHash": "1638152228410583836" + }, + "name": "Policy Set Definitions (Initiatives) (Management Group scope)", + "description": "This module deploys a Policy Set Definition (Initiative) at a Management Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -299,9 +305,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10195867857732116184" - } + "version": "0.20.4.51522", + "templateHash": "8864751360907211482" + }, + "name": "Policy Set Definitions (Initiatives) (Subscription scope)", + "description": "This module deploys a Policy Set Definition (Initiative) at a Subscription scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/authorization/policy-set-definition/management-group/main.json b/modules/authorization/policy-set-definition/management-group/main.json index 8a94ab50df..baa439be6e 100644 --- a/modules/authorization/policy-set-definition/management-group/main.json +++ b/modules/authorization/policy-set-definition/management-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3402211804211188599" - } + "version": "0.20.4.51522", + "templateHash": "1638152228410583836" + }, + "name": "Policy Set Definitions (Initiatives) (Management Group scope)", + "description": "This module deploys a Policy Set Definition (Initiative) at a Management Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/authorization/policy-set-definition/subscription/main.json b/modules/authorization/policy-set-definition/subscription/main.json index a37b11c5b5..430128e583 100644 --- a/modules/authorization/policy-set-definition/subscription/main.json +++ b/modules/authorization/policy-set-definition/subscription/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10195867857732116184" - } + "version": "0.20.4.51522", + "templateHash": "8864751360907211482" + }, + "name": "Policy Set Definitions (Initiatives) (Subscription scope)", + "description": "This module deploys a Policy Set Definition (Initiative) at a Subscription scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/authorization/role-assignment/main.json b/modules/authorization/role-assignment/main.json index 2033eae799..6d1fc12f85 100644 --- a/modules/authorization/role-assignment/main.json +++ b/modules/authorization/role-assignment/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14691526432601298583" - } + "version": "0.20.4.51522", + "templateHash": "2365186882065323571" + }, + "name": "Role Assignments (All scopes)", + "description": "This module deploys a Role Assignment at a Management Group, Subscription or Resource Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "roleDefinitionIdOrName": { @@ -164,9 +167,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16437436871893645237" - } + "version": "0.20.4.51522", + "templateHash": "5116103670131987468" + }, + "name": "Role Assignments (Management Group scope)", + "description": "This module deploys a Role Assignment at a Management Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "roleDefinitionIdOrName": { @@ -750,9 +756,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8551972767559758659" - } + "version": "0.20.4.51522", + "templateHash": "318736480892502738" + }, + "name": "Role Assignments (Subscription scope)", + "description": "This module deploys a Role Assignment at a Subscription scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "roleDefinitionIdOrName": { @@ -1336,9 +1345,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11819315313212174566" - } + "version": "0.20.4.51522", + "templateHash": "1439450089488966223" + }, + "name": "Role Assignments (Resource Group scope)", + "description": "This module deploys a Role Assignment at a Resource Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "roleDefinitionIdOrName": { diff --git a/modules/authorization/role-assignment/management-group/main.json b/modules/authorization/role-assignment/management-group/main.json index 0a93d74330..5356f24b6f 100644 --- a/modules/authorization/role-assignment/management-group/main.json +++ b/modules/authorization/role-assignment/management-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16437436871893645237" - } + "version": "0.20.4.51522", + "templateHash": "5116103670131987468" + }, + "name": "Role Assignments (Management Group scope)", + "description": "This module deploys a Role Assignment at a Management Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "roleDefinitionIdOrName": { diff --git a/modules/authorization/role-assignment/resource-group/main.json b/modules/authorization/role-assignment/resource-group/main.json index 2396bee14a..056f28f034 100644 --- a/modules/authorization/role-assignment/resource-group/main.json +++ b/modules/authorization/role-assignment/resource-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11819315313212174566" - } + "version": "0.20.4.51522", + "templateHash": "1439450089488966223" + }, + "name": "Role Assignments (Resource Group scope)", + "description": "This module deploys a Role Assignment at a Resource Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "roleDefinitionIdOrName": { diff --git a/modules/authorization/role-assignment/subscription/main.json b/modules/authorization/role-assignment/subscription/main.json index b3bec5019c..751db130ed 100644 --- a/modules/authorization/role-assignment/subscription/main.json +++ b/modules/authorization/role-assignment/subscription/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8551972767559758659" - } + "version": "0.20.4.51522", + "templateHash": "318736480892502738" + }, + "name": "Role Assignments (Subscription scope)", + "description": "This module deploys a Role Assignment at a Subscription scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "roleDefinitionIdOrName": { diff --git a/modules/authorization/role-definition/main.json b/modules/authorization/role-definition/main.json index 73f786f530..3a5a38ed6e 100644 --- a/modules/authorization/role-definition/main.json +++ b/modules/authorization/role-definition/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7983900470064159202" - } + "version": "0.20.4.51522", + "templateHash": "543064191837640838" + }, + "name": "Role Definitions (All scopes)", + "description": "This module deploys a Role Definition at a Management Group, Subscription or Resource Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "roleName": { @@ -148,9 +151,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11312427522250634674" - } + "version": "0.20.4.51522", + "templateHash": "15321014984642305644" + }, + "name": "Role Definitions (Management Group scope)", + "description": "This module deploys a Role Definition at a Management Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "roleName": { @@ -307,9 +313,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "185323239353092830" - } + "version": "0.20.4.51522", + "templateHash": "9532889033437004469" + }, + "name": "Role Definitions (Subscription scope)", + "description": "This module deploys a Role Definition at a Subscription scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "roleName": { @@ -482,9 +491,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4111491640630713206" - } + "version": "0.20.4.51522", + "templateHash": "13735806028928031798" + }, + "name": "Role Definitions (Resource Group scope)", + "description": "This module deploys a Role Definition at a Resource Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "roleName": { diff --git a/modules/authorization/role-definition/management-group/main.json b/modules/authorization/role-definition/management-group/main.json index 2d18a95de6..cc28a185f9 100644 --- a/modules/authorization/role-definition/management-group/main.json +++ b/modules/authorization/role-definition/management-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11312427522250634674" - } + "version": "0.20.4.51522", + "templateHash": "15321014984642305644" + }, + "name": "Role Definitions (Management Group scope)", + "description": "This module deploys a Role Definition at a Management Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "roleName": { diff --git a/modules/authorization/role-definition/resource-group/main.json b/modules/authorization/role-definition/resource-group/main.json index f6151f2c60..734ae5e18c 100644 --- a/modules/authorization/role-definition/resource-group/main.json +++ b/modules/authorization/role-definition/resource-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4111491640630713206" - } + "version": "0.20.4.51522", + "templateHash": "13735806028928031798" + }, + "name": "Role Definitions (Resource Group scope)", + "description": "This module deploys a Role Definition at a Resource Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "roleName": { diff --git a/modules/authorization/role-definition/subscription/main.json b/modules/authorization/role-definition/subscription/main.json index 3a2863f299..13af925166 100644 --- a/modules/authorization/role-definition/subscription/main.json +++ b/modules/authorization/role-definition/subscription/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "185323239353092830" - } + "version": "0.20.4.51522", + "templateHash": "9532889033437004469" + }, + "name": "Role Definitions (Subscription scope)", + "description": "This module deploys a Role Definition at a Subscription scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "roleName": { diff --git a/modules/automation/automation-account/.test/common/dependencies.bicep b/modules/automation/automation-account/.test/common/dependencies.bicep index c9e11ef44b..c388f7bc4f 100644 --- a/modules/automation/automation-account/.test/common/dependencies.bicep +++ b/modules/automation/automation-account/.test/common/dependencies.bicep @@ -12,63 +12,63 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.azure-automation.net' - location: 'global' + name: 'privatelink.azure-automation.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource keyVault 'Microsoft.KeyVault/vaults@2022-07-01' = { - name: keyVaultName - location: location - properties: { - sku: { - family: 'A' - name: 'standard' - } - tenantId: tenant().tenantId - enablePurgeProtection: null - enabledForTemplateDeployment: true - enabledForDiskEncryption: true - enabledForDeployment: true - enableRbacAuthorization: true - accessPolicies: [] + name: keyVaultName + location: location + properties: { + sku: { + family: 'A' + name: 'standard' } + tenantId: tenant().tenantId + enablePurgeProtection: null + enabledForTemplateDeployment: true + enabledForDiskEncryption: true + enabledForDeployment: true + enableRbacAuthorization: true + accessPolicies: [] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/automation/automation-account/.test/common/main.test.bicep b/modules/automation/automation-account/.test/common/main.test.bicep index 0637bd5fad..461dfed416 100644 --- a/modules/automation/automation-account/.test/common/main.test.bicep +++ b/modules/automation/automation-account/.test/common/main.test.bicep @@ -65,7 +65,6 @@ module testDeployment '../../main.bicep' = { params: { enableDefaultTelemetry: enableDefaultTelemetry name: '${namePrefix}${serviceShort}001' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/automation/automation-account/README.md b/modules/automation/automation-account/README.md index 1099651b4d..896c504721 100644 --- a/modules/automation/automation-account/README.md +++ b/modules/automation/automation-account/README.md @@ -24,8 +24,8 @@ This module deploys an Azure Automation Account. | `Microsoft.Automation/automationAccounts/softwareUpdateConfigurations` | [2019-06-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Automation/2019-06-01/automationAccounts/softwareUpdateConfigurations) | | `Microsoft.Automation/automationAccounts/variables` | [2022-08-08](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Automation/2022-08-08/automationAccounts/variables) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | | `Microsoft.OperationalInsights/workspaces/linkedServices` | [2020-08-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.OperationalInsights/2020-08-01/workspaces/linkedServices) | | `Microsoft.OperationsManagement/solutions` | [2015-11-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.OperationsManagement/2015-11-01-preview/solutions) | @@ -53,7 +53,6 @@ This module deploys an Azure Automation Account. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, DscNodeStatus, JobLogs, JobStreams]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -409,7 +408,6 @@ module automationAccount './automation/automation-account/main.bicep' = { // Non-required parameters diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' disableLocalAuth: true @@ -613,9 +611,6 @@ module automationAccount './automation/automation-account/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/automation/automation-account/job-schedule/main.json b/modules/automation/automation-account/job-schedule/main.json index cba35529e9..5fee90a026 100644 --- a/modules/automation/automation-account/job-schedule/main.json +++ b/modules/automation/automation-account/job-schedule/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16536689871525046750" - } + "version": "0.20.4.51522", + "templateHash": "12038142052110102548" + }, + "name": "Automation Account Job Schedules", + "description": "This module deploys an Azure Automation Account Job Schedule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/automation/automation-account/main.bicep b/modules/automation/automation-account/main.bicep index b94b53b0d4..8f03f5f404 100644 --- a/modules/automation/automation-account/main.bicep +++ b/modules/automation/automation-account/main.bicep @@ -65,11 +65,6 @@ param disableLocalAuth bool = true @description('Optional. Configuration details for private endpoints. For security reasons, it is recommended to use private endpoints whenever possible.') param privateEndpoints array = [] -@minValue(0) -@maxValue(365) -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -133,20 +128,12 @@ var enableReferencedModulesTelemetry = false var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -154,10 +141,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var identityType = systemAssignedIdentity ? (!empty(userAssignedIdentities) ? 'SystemAssigned,UserAssigned' : 'SystemAssigned') : (!empty(userAssignedIdentities) ? 'UserAssigned' : 'None') diff --git a/modules/automation/automation-account/main.json b/modules/automation/automation-account/main.json index 46707efe42..bac8c5b284 100644 --- a/modules/automation/automation-account/main.json +++ b/modules/automation/automation-account/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9546518808928883376" - } + "version": "0.20.4.51522", + "templateHash": "16595917199403663446" + }, + "name": "Automation Accounts", + "description": "This module deploys an Azure Automation Account.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -143,15 +146,6 @@ "description": "Optional. Configuration details for private endpoints. For security reasons, it is recommended to use private endpoints whenever possible." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - }, - "maxValue": 365, - "minValue": 0 - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -197,14 +191,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -270,11 +264,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -283,16 +273,12 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], "enableReferencedModulesTelemetry": false, - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "identityType": "[if(parameters('systemAssignedIdentity'), if(not(empty(parameters('userAssignedIdentities'))), 'SystemAssigned,UserAssigned', 'SystemAssigned'), if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None'))]", "identity": "[if(not(equals(variables('identityType'), 'None')), createObject('type', variables('identityType'), 'userAssignedIdentities', if(not(empty(parameters('userAssignedIdentities'))), parameters('userAssignedIdentities'), null())), null())]" }, @@ -401,9 +387,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8461123692022561232" - } + "version": "0.20.4.51522", + "templateHash": "12776439865232935886" + }, + "name": "Automation Account Modules", + "description": "This module deploys an Azure Automation Account Module.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -555,9 +544,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15331115804969871270" - } + "version": "0.20.4.51522", + "templateHash": "5807574740331814274" + }, + "name": "Automation Account Schedules", + "description": "This module deploys an Azure Automation Account Schedule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -599,9 +591,6 @@ "frequency": { "type": "string", "defaultValue": "OneTime", - "metadata": { - "description": "Optional. The frequency of the schedule." - }, "allowedValues": [ "Day", "Hour", @@ -609,7 +598,10 @@ "Month", "OneTime", "Week" - ] + ], + "metadata": { + "description": "Optional. The frequency of the schedule." + } }, "interval": { "type": "int", @@ -748,9 +740,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4555370895939507576" - } + "version": "0.20.4.51522", + "templateHash": "123190998372280958" + }, + "name": "Automation Account Runbooks", + "description": "This module deploys an Azure Automation Account Runbook.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -767,16 +762,16 @@ }, "type": { "type": "string", - "metadata": { - "description": "Required. The type of the runbook." - }, "allowedValues": [ "Graph", "GraphPowerShell", "GraphPowerShellWorkflow", "PowerShell", "PowerShellWorkflow" - ] + ], + "metadata": { + "description": "Required. The type of the runbook." + } }, "description": { "type": "string", @@ -950,9 +945,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16536689871525046750" - } + "version": "0.20.4.51522", + "templateHash": "12038142052110102548" + }, + "name": "Automation Account Job Schedules", + "description": "This module deploys an Azure Automation Account Job Schedule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1099,9 +1097,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11841633230625073829" - } + "version": "0.20.4.51522", + "templateHash": "17684191295648041474" + }, + "name": "Automation Account Variables", + "description": "This module deploys an Azure Automation Account Variable.", + "owner": "Azure/module-maintainers" }, "parameters": { "automationAccountName": { @@ -1234,9 +1235,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9104010996147858950" - } + "version": "0.20.4.51522", + "templateHash": "6123492600831728521" + }, + "name": "Log Analytics Workspace Linked Services", + "description": "This module deploys a Log Analytics Workspace Linked Service.", + "owner": "Azure/module-maintainers" }, "parameters": { "logAnalyticsWorkspaceName": { @@ -1373,9 +1377,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6203827990364745107" - } + "version": "0.20.4.51522", + "templateHash": "16708625392312836324" + }, + "name": "Operations Management Solutions", + "description": "This module deploys an Operations Management Solution.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1556,9 +1563,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15383978378137872211" - } + "version": "0.20.4.51522", + "templateHash": "11844327136869535634" + }, + "name": "Automation Account Software Update Configurations", + "description": "This module deploys an Azure Automation Account Software Update Configuration.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -2027,9 +2037,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -2094,14 +2107,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -2159,7 +2172,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -2224,9 +2237,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -2237,8 +2253,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -2289,7 +2305,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -2359,8 +2375,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -2530,7 +2546,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -2573,8 +2589,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2412137951317227318" + "version": "0.20.4.51522", + "templateHash": "12807590367085737448" } }, "parameters": { diff --git a/modules/automation/automation-account/module/main.json b/modules/automation/automation-account/module/main.json index f192b8a39c..92e1b857bf 100644 --- a/modules/automation/automation-account/module/main.json +++ b/modules/automation/automation-account/module/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8461123692022561232" - } + "version": "0.20.4.51522", + "templateHash": "12776439865232935886" + }, + "name": "Automation Account Modules", + "description": "This module deploys an Azure Automation Account Module.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/automation/automation-account/runbook/main.json b/modules/automation/automation-account/runbook/main.json index cfab69c2ca..21cabe276d 100644 --- a/modules/automation/automation-account/runbook/main.json +++ b/modules/automation/automation-account/runbook/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4555370895939507576" - } + "version": "0.20.4.51522", + "templateHash": "123190998372280958" + }, + "name": "Automation Account Runbooks", + "description": "This module deploys an Azure Automation Account Runbook.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -23,16 +26,16 @@ }, "type": { "type": "string", - "metadata": { - "description": "Required. The type of the runbook." - }, "allowedValues": [ "Graph", "GraphPowerShell", "GraphPowerShellWorkflow", "PowerShell", "PowerShellWorkflow" - ] + ], + "metadata": { + "description": "Required. The type of the runbook." + } }, "description": { "type": "string", diff --git a/modules/automation/automation-account/schedule/main.json b/modules/automation/automation-account/schedule/main.json index 0ba8543543..b76ec06a61 100644 --- a/modules/automation/automation-account/schedule/main.json +++ b/modules/automation/automation-account/schedule/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15331115804969871270" - } + "version": "0.20.4.51522", + "templateHash": "5807574740331814274" + }, + "name": "Automation Account Schedules", + "description": "This module deploys an Azure Automation Account Schedule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -48,9 +51,6 @@ "frequency": { "type": "string", "defaultValue": "OneTime", - "metadata": { - "description": "Optional. The frequency of the schedule." - }, "allowedValues": [ "Day", "Hour", @@ -58,7 +58,10 @@ "Month", "OneTime", "Week" - ] + ], + "metadata": { + "description": "Optional. The frequency of the schedule." + } }, "interval": { "type": "int", diff --git a/modules/automation/automation-account/software-update-configuration/main.json b/modules/automation/automation-account/software-update-configuration/main.json index 0ea34a8293..f4305ddbf8 100644 --- a/modules/automation/automation-account/software-update-configuration/main.json +++ b/modules/automation/automation-account/software-update-configuration/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15383978378137872211" - } + "version": "0.20.4.51522", + "templateHash": "11844327136869535634" + }, + "name": "Automation Account Software Update Configurations", + "description": "This module deploys an Azure Automation Account Software Update Configuration.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/automation/automation-account/variable/main.json b/modules/automation/automation-account/variable/main.json index 76ff2b1a84..e0ffc7ec3a 100644 --- a/modules/automation/automation-account/variable/main.json +++ b/modules/automation/automation-account/variable/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11841633230625073829" - } + "version": "0.20.4.51522", + "templateHash": "17684191295648041474" + }, + "name": "Automation Account Variables", + "description": "This module deploys an Azure Automation Account Variable.", + "owner": "Azure/module-maintainers" }, "parameters": { "automationAccountName": { diff --git a/modules/batch/batch-account/.test/common/dependencies.bicep b/modules/batch/batch-account/.test/common/dependencies.bicep index cc88fbffef..b355d52cb3 100644 --- a/modules/batch/batch-account/.test/common/dependencies.bicep +++ b/modules/batch/batch-account/.test/common/dependencies.bicep @@ -13,53 +13,53 @@ param storageAccountName string var addressPrefix = '10.0.0.0/16' resource storageAccount 'Microsoft.Storage/storageAccounts@2021-09-01' = { - name: storageAccountName - location: location - sku: { - name: 'Standard_LRS' - } - kind: 'StorageV2' + name: storageAccountName + location: location + sku: { + name: 'Standard_LRS' + } + kind: 'StorageV2' } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.batch.azure.com' - location: 'global' + name: 'privatelink.batch.azure.com' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/batch/batch-account/.test/common/main.test.bicep b/modules/batch/batch-account/.test/common/main.test.bicep index f4fab0de97..b2fa9e7a62 100644 --- a/modules/batch/batch-account/.test/common/main.test.bicep +++ b/modules/batch/batch-account/.test/common/main.test.bicep @@ -66,7 +66,6 @@ module testDeployment '../../main.bicep' = { enableDefaultTelemetry: enableDefaultTelemetry name: '${namePrefix}${serviceShort}001' storageAccountId: nestedDependencies.outputs.storageAccountResourceId - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/batch/batch-account/.test/encr/dependencies.bicep b/modules/batch/batch-account/.test/encr/dependencies.bicep index fc58da5894..e6acb43c7c 100644 --- a/modules/batch/batch-account/.test/encr/dependencies.bicep +++ b/modules/batch/batch-account/.test/encr/dependencies.bicep @@ -16,89 +16,89 @@ param storageAccountName string var addressPrefix = '10.0.0.0/16' resource storageAccount 'Microsoft.Storage/storageAccounts@2021-09-01' = { - name: storageAccountName - location: location - sku: { - name: 'Standard_LRS' - } - kind: 'StorageV2' + name: storageAccountName + location: location + sku: { + name: 'Standard_LRS' + } + kind: 'StorageV2' } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.batch.azure.com' - location: 'global' + name: 'privatelink.batch.azure.com' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource keyVault 'Microsoft.KeyVault/vaults@2022-07-01' = { - name: keyVaultName - location: location - properties: { - sku: { - family: 'A' - name: 'standard' - } - tenantId: tenant().tenantId - enablePurgeProtection: true // Required by batch account - softDeleteRetentionInDays: 7 - enabledForTemplateDeployment: true - enabledForDiskEncryption: true - enabledForDeployment: true - enableRbacAuthorization: true - accessPolicies: [] + name: keyVaultName + location: location + properties: { + sku: { + family: 'A' + name: 'standard' } - - resource key 'keys@2022-07-01' = { - name: 'keyEncryptionKey' - properties: { - kty: 'RSA' - } + tenantId: tenant().tenantId + enablePurgeProtection: true // Required by batch account + softDeleteRetentionInDays: 7 + enabledForTemplateDeployment: true + enabledForDiskEncryption: true + enabledForDeployment: true + enableRbacAuthorization: true + accessPolicies: [] + } + + resource key 'keys@2022-07-01' = { + name: 'keyEncryptionKey' + properties: { + kty: 'RSA' } + } } resource keyPermissions 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid('msi-${keyVault::key.id}-${location}-${managedIdentity.id}-Key-Reader-RoleAssignment') - scope: keyVault::key - properties: { - principalId: managedIdentity.properties.principalId - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '12338af0-0e69-4776-bea7-57ae8d297424') // Key Vault Crypto User - principalType: 'ServicePrincipal' - } + name: guid('msi-${keyVault::key.id}-${location}-${managedIdentity.id}-Key-Reader-RoleAssignment') + scope: keyVault::key + properties: { + principalId: managedIdentity.properties.principalId + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '12338af0-0e69-4776-bea7-57ae8d297424') // Key Vault Crypto User + principalType: 'ServicePrincipal' + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/batch/batch-account/README.md b/modules/batch/batch-account/README.md index e27c76e1ca..85dcc30c05 100644 --- a/modules/batch/batch-account/README.md +++ b/modules/batch/batch-account/README.md @@ -18,8 +18,8 @@ This module deploys a Batch Account. | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Batch/batchAccounts` | [2022-06-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Batch/2022-06-01/batchAccounts) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | ## Parameters @@ -47,7 +47,6 @@ This module deploys a Batch Account. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, ServiceLog]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -281,7 +280,6 @@ module batchAccount './batch/batch-account/main.bicep' = { // Non-required parameters diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -348,9 +346,6 @@ module batchAccount './batch/batch-account/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/batch/batch-account/main.bicep b/modules/batch/batch-account/main.bicep index 6c1bbcb34e..092005e322 100644 --- a/modules/batch/batch-account/main.bicep +++ b/modules/batch/batch-account/main.bicep @@ -58,11 +58,6 @@ param networkProfileDefaultAction string = 'Deny' @description('Optional. Array of IP ranges to filter client IP address. It is only applicable when publicNetworkAccess is not explicitly disabled.') param networkProfileAllowedIpRanges array = [] -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -130,20 +125,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -151,10 +138,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var identityType = systemAssignedIdentity ? 'SystemAssigned' : !empty(userAssignedIdentities) ? 'UserAssigned' : 'None' diff --git a/modules/batch/batch-account/main.json b/modules/batch/batch-account/main.json index c63166c89b..b2ff4246cc 100644 --- a/modules/batch/batch-account/main.json +++ b/modules/batch/batch-account/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5392244196871219309" - } + "version": "0.20.4.51522", + "templateHash": "10210928254812932351" + }, + "name": "Batch Accounts", + "description": "This module deploys a Batch Account.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -45,13 +48,13 @@ "storageAuthenticationMode": { "type": "string", "defaultValue": "StorageKeys", - "metadata": { - "description": "Optional. The authentication mode which the Batch service will use to manage the auto-storage account." - }, "allowedValues": [ "BatchAccountManagedIdentity", "StorageKeys" - ] + ], + "metadata": { + "description": "Optional. The authentication mode which the Batch service will use to manage the auto-storage account." + } }, "storageAccessIdentity": { "type": "string", @@ -63,13 +66,13 @@ "poolAllocationMode": { "type": "string", "defaultValue": "BatchService", - "metadata": { - "description": "Optional. The allocation mode for creating pools in the Batch account. Determines which quota will be used." - }, "allowedValues": [ "BatchService", "UserSubscription" - ] + ], + "metadata": { + "description": "Optional. The allocation mode for creating pools in the Batch account. Determines which quota will be used." + } }, "keyVaultReferenceResourceId": { "type": "string", @@ -100,13 +103,13 @@ "networkProfileDefaultAction": { "type": "string", "defaultValue": "Deny", - "metadata": { - "description": "Optional. The network profile default action for endpoint access. It is only applicable when publicNetworkAccess is not explicitly disabled." - }, "allowedValues": [ "Allow", "Deny" - ] + ], + "metadata": { + "description": "Optional. The network profile default action for endpoint access. It is only applicable when publicNetworkAccess is not explicitly disabled." + } }, "networkProfileAllowedIpRanges": { "type": "array", @@ -115,15 +118,6 @@ "description": "Optional. Array of IP ranges to filter client IP address. It is only applicable when publicNetworkAccess is not explicitly disabled." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -155,14 +149,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "tags": { "type": "object", @@ -174,14 +168,14 @@ "allowedAuthenticationModes": { "type": "array", "defaultValue": [], - "metadata": { - "description": "Optional. List of allowed authentication modes for the Batch account that can be used to authenticate with the data plane." - }, "allowedValues": [ "AAD", "SharedKey", "TaskAuthenticationToken" - ] + ], + "metadata": { + "description": "Optional. List of allowed authentication modes for the Batch account that can be used to authenticate with the data plane." + } }, "cMKKeyVaultResourceId": { "type": "string", @@ -252,11 +246,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -265,11 +255,7 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -281,7 +267,7 @@ } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "identityType": "[if(parameters('systemAssignedIdentity'), 'SystemAssigned', if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None'))]", "identity": { "type": "[variables('identityType')]", @@ -407,9 +393,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -474,14 +463,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -539,7 +528,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -604,9 +593,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -617,8 +609,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -669,7 +661,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -739,8 +731,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -910,7 +902,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } diff --git a/modules/cache/redis/.test/common/dependencies.bicep b/modules/cache/redis/.test/common/dependencies.bicep index e3f77c7003..c6cfc38050 100644 --- a/modules/cache/redis/.test/common/dependencies.bicep +++ b/modules/cache/redis/.test/common/dependencies.bicep @@ -6,40 +6,40 @@ param virtualNetworkName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.azuresynapse.net' - location: 'global' + name: 'privatelink.azuresynapse.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/cache/redis/.test/common/main.test.bicep b/modules/cache/redis/.test/common/main.test.bicep index 8ad4bad1cc..bc976f33b7 100644 --- a/modules/cache/redis/.test/common/main.test.bicep +++ b/modules/cache/redis/.test/common/main.test.bicep @@ -64,7 +64,6 @@ module testDeployment '../../main.bicep' = { enableDefaultTelemetry: enableDefaultTelemetry name: '${namePrefix}${serviceShort}001' capacity: 2 - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/cache/redis/README.md b/modules/cache/redis/README.md index 94f11f48a3..b005689a95 100644 --- a/modules/cache/redis/README.md +++ b/modules/cache/redis/README.md @@ -18,8 +18,8 @@ This module deploys a Redis Cache. | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Cache/redis` | [2021-06-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Cache/2021-06-01/redis) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | ## Parameters @@ -37,7 +37,6 @@ This module deploys a Redis Cache. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, ConnectedClientList]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub. | @@ -375,7 +374,6 @@ module redis './cache/redis/main.bicep' = { capacity: 2 diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticSettingsName: 'redisdiagnostics' diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' @@ -441,9 +439,6 @@ module redis './cache/redis/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticSettingsName": { "value": "redisdiagnostics" }, diff --git a/modules/cache/redis/main.bicep b/modules/cache/redis/main.bicep index af50133fca..172c38fa44 100644 --- a/modules/cache/redis/main.bicep +++ b/modules/cache/redis/main.bicep @@ -110,11 +110,6 @@ param privateEndpoints array = [] @description('Optional. The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings".') param diagnosticSettingsName string = '' -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub.') param diagnosticStorageAccountId string = '' @@ -153,20 +148,12 @@ var availabilityZones = skuName == 'Premium' ? zoneRedundant ? !empty(zones) ? z var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -174,10 +161,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var identityType = systemAssignedIdentity ? 'SystemAssigned' : !empty(userAssignedIdentities) ? 'UserAssigned' : 'None' diff --git a/modules/cache/redis/main.json b/modules/cache/redis/main.json index bb9307ab94..3545e1c592 100644 --- a/modules/cache/redis/main.json +++ b/modules/cache/redis/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4085710170805862931" - } + "version": "0.20.4.51522", + "templateHash": "16190276129118056203" + }, + "name": "Redis Cache", + "description": "This module deploys a Redis Cache.", + "owner": "Azure/module-maintainers" }, "parameters": { "location": { @@ -25,14 +28,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -72,14 +75,14 @@ "minimumTlsVersion": { "type": "string", "defaultValue": "1.2", - "metadata": { - "description": "Optional. Requires clients to use a specified TLS version (or higher) to connect." - }, "allowedValues": [ "1.0", "1.1", "1.2" - ] + ], + "metadata": { + "description": "Optional. Requires clients to use a specified TLS version (or higher) to connect." + } }, "publicNetworkAccess": { "type": "string", @@ -103,44 +106,41 @@ "redisVersion": { "type": "string", "defaultValue": "6", - "metadata": { - "description": "Optional. Redis version. Only major version will be used in PUT/PATCH request with current valid values: (4, 6)." - }, "allowedValues": [ "4", "6" - ] + ], + "metadata": { + "description": "Optional. Redis version. Only major version will be used in PUT/PATCH request with current valid values: (4, 6)." + } }, "replicasPerMaster": { "type": "int", "defaultValue": 1, + "minValue": 1, "metadata": { "description": "Optional. The number of replicas to be created per primary." - }, - "minValue": 1 + } }, "replicasPerPrimary": { "type": "int", "defaultValue": 1, + "minValue": 1, "metadata": { "description": "Optional. The number of replicas to be created per primary." - }, - "minValue": 1 + } }, "shardCount": { "type": "int", "defaultValue": 1, + "minValue": 1, "metadata": { "description": "Optional. The number of shards to be created on a Premium Cluster Cache." - }, - "minValue": 1 + } }, "capacity": { "type": "int", "defaultValue": 1, - "metadata": { - "description": "Optional. The size of the Redis cache to deploy. Valid values: for C (Basic/Standard) family (0, 1, 2, 3, 4, 5, 6), for P (Premium) family (1, 2, 3, 4)." - }, "allowedValues": [ 0, 1, @@ -149,19 +149,22 @@ 4, 5, 6 - ] + ], + "metadata": { + "description": "Optional. The size of the Redis cache to deploy. Valid values: for C (Basic/Standard) family (0, 1, 2, 3, 4, 5, 6), for P (Premium) family (1, 2, 3, 4)." + } }, "skuName": { "type": "string", "defaultValue": "Basic", - "metadata": { - "description": "Optional. The type of Redis cache to deploy." - }, "allowedValues": [ "Basic", "Premium", "Standard" - ] + ], + "metadata": { + "description": "Optional. The type of Redis cache to deploy." + } }, "staticIP": { "type": "string", @@ -212,15 +215,6 @@ "description": "Optional. The name of the diagnostic setting, if deployed. If left empty, it defaults to \"-diagnosticSettings\"." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -290,11 +284,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -303,16 +293,12 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], "availabilityZones": "[if(equals(parameters('skuName'), 'Premium'), if(parameters('zoneRedundant'), if(not(empty(parameters('zones'))), parameters('zones'), pickZones('Microsoft.Cache', 'redis', parameters('location'), 3)), createArray()), createArray())]", - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "identityType": "[if(parameters('systemAssignedIdentity'), 'SystemAssigned', if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None'))]", "identity": { "type": "[variables('identityType')]", @@ -428,8 +414,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5092700248375657903" + "version": "0.20.4.51522", + "templateHash": "11568465556240097908" } }, "parameters": { @@ -591,9 +577,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -658,14 +647,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -723,7 +712,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -788,9 +777,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -801,8 +793,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -853,7 +845,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -923,8 +915,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -1094,7 +1086,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } diff --git a/modules/cdn/profile/README.md b/modules/cdn/profile/README.md index 55e1fda137..cdb4f0247b 100644 --- a/modules/cdn/profile/README.md +++ b/modules/cdn/profile/README.md @@ -27,7 +27,7 @@ This module deploys a CDN Profile. | Parameter Name | Type | Allowed Values | Description | | :-- | :-- | :-- | :-- | | `name` | string | | Name of the CDN profile. | -| `sku` | string | `[Custom_Akamai, Custom_ChinaCdn, Custom_Microsoft, Custom_Microsoft_AzureFrontDoor, Custom_Verizon, Premium_Akamai, Premium_ChinaCdn, Premium_Microsoft, Premium_Microsoft_AzureFrontDoor, Premium_Verizon, Standard_Akamai, Standard_ChinaCdn, Standard_Microsoft, Standard_Microsoft_AzureFrontDoor, Standard_Verizon, Standard_AzureFrontDoor, Premium_AzureFrontDoor ]` | The pricing tier (defines a CDN provider, feature list and rate) of the CDN profile. | +| `sku` | string | `[Custom_Akamai, Custom_ChinaCdn, Custom_Microsoft, Custom_Microsoft_AzureFrontDoor, Custom_Verizon, Premium_Akamai, Premium_AzureFrontDoor, Premium_ChinaCdn, Premium_Microsoft, Premium_Microsoft_AzureFrontDoor, Premium_Verizon, Standard_Akamai, Standard_AzureFrontDoor, Standard_ChinaCdn, Standard_Microsoft, Standard_Microsoft_AzureFrontDoor, Standard_Verizon]` | The pricing tier (defines a CDN provider, feature list and rate) of the CDN profile. | **Optional parameters** diff --git a/modules/cdn/profile/endpoint/main.json b/modules/cdn/profile/endpoint/main.json index 5f97baa1b4..c2ea25941e 100644 --- a/modules/cdn/profile/endpoint/main.json +++ b/modules/cdn/profile/endpoint/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15681386879611412018" - } + "version": "0.20.4.51522", + "templateHash": "17735453478116875585" + }, + "name": "CDN Profiles Endpoints", + "description": "This module deploys a CDN Profile Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "profileName": { @@ -122,9 +125,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16929017469298087182" - } + "version": "0.20.4.51522", + "templateHash": "16752439019054773130" + }, + "name": "CDN Profiles Endpoints Origins", + "description": "This module deploys a CDN Profile Endpoint Origin.", + "owner": "Azure/module-maintainers" }, "parameters": { "endpointName": { diff --git a/modules/cdn/profile/endpoint/origin/main.json b/modules/cdn/profile/endpoint/origin/main.json index d38c4338f8..8e4d8bf0e5 100644 --- a/modules/cdn/profile/endpoint/origin/main.json +++ b/modules/cdn/profile/endpoint/origin/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16929017469298087182" - } + "version": "0.20.4.51522", + "templateHash": "16752439019054773130" + }, + "name": "CDN Profiles Endpoints Origins", + "description": "This module deploys a CDN Profile Endpoint Origin.", + "owner": "Azure/module-maintainers" }, "parameters": { "endpointName": { diff --git a/modules/cognitive-services/account/.test/common/dependencies.bicep b/modules/cognitive-services/account/.test/common/dependencies.bicep index 257b8ac137..c9050e21ef 100644 --- a/modules/cognitive-services/account/.test/common/dependencies.bicep +++ b/modules/cognitive-services/account/.test/common/dependencies.bicep @@ -9,50 +9,50 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] + } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + serviceEndpoints: [ { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - serviceEndpoints: [ - { - service: 'Microsoft.CognitiveServices' - } - ] - } + service: 'Microsoft.CognitiveServices' } - ] - } + ] + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.cognitiveservices.azure.com' - location: 'global' + name: 'privatelink.cognitiveservices.azure.com' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/cognitive-services/account/.test/common/main.test.bicep b/modules/cognitive-services/account/.test/common/main.test.bicep index 556ce7e70f..7a61062ca0 100644 --- a/modules/cognitive-services/account/.test/common/main.test.bicep +++ b/modules/cognitive-services/account/.test/common/main.test.bicep @@ -66,7 +66,6 @@ module testDeployment '../../main.bicep' = { name: '${namePrefix}${serviceShort}001' kind: 'Face' customSubDomainName: '${namePrefix}xdomain' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/cognitive-services/account/.test/encr/dependencies.bicep b/modules/cognitive-services/account/.test/encr/dependencies.bicep index b18cd7e118..a37c49daaa 100644 --- a/modules/cognitive-services/account/.test/encr/dependencies.bicep +++ b/modules/cognitive-services/account/.test/encr/dependencies.bicep @@ -12,65 +12,65 @@ param keyVaultName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource keyVault 'Microsoft.KeyVault/vaults@2022-07-01' = { - name: keyVaultName - location: location - properties: { - sku: { - family: 'A' - name: 'standard' - } - tenantId: tenant().tenantId - enablePurgeProtection: true // Required by batch account - softDeleteRetentionInDays: 7 - enabledForTemplateDeployment: true - enabledForDiskEncryption: true - enabledForDeployment: true - enableRbacAuthorization: true - accessPolicies: [] + name: keyVaultName + location: location + properties: { + sku: { + family: 'A' + name: 'standard' } + tenantId: tenant().tenantId + enablePurgeProtection: true // Required by batch account + softDeleteRetentionInDays: 7 + enabledForTemplateDeployment: true + enabledForDiskEncryption: true + enabledForDeployment: true + enableRbacAuthorization: true + accessPolicies: [] + } - resource key 'keys@2022-07-01' = { - name: 'keyEncryptionKey' - properties: { - kty: 'RSA' - } + resource key 'keys@2022-07-01' = { + name: 'keyEncryptionKey' + properties: { + kty: 'RSA' } + } } resource keyPermissions 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid('msi-${keyVault::key.id}-${location}-${managedIdentity.id}-Key-Key-Vault-Crypto-User-RoleAssignment') - scope: keyVault::key - properties: { - principalId: managedIdentity.properties.principalId - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '12338af0-0e69-4776-bea7-57ae8d297424') // Key Vault Crypto User - principalType: 'ServicePrincipal' - } + name: guid('msi-${keyVault::key.id}-${location}-${managedIdentity.id}-Key-Key-Vault-Crypto-User-RoleAssignment') + scope: keyVault::key + properties: { + principalId: managedIdentity.properties.principalId + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '12338af0-0e69-4776-bea7-57ae8d297424') // Key Vault Crypto User + principalType: 'ServicePrincipal' + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/cognitive-services/account/.test/speech/dependencies.bicep b/modules/cognitive-services/account/.test/speech/dependencies.bicep index 9f1d9f6634..6c44dce491 100644 --- a/modules/cognitive-services/account/.test/speech/dependencies.bicep +++ b/modules/cognitive-services/account/.test/speech/dependencies.bicep @@ -9,45 +9,45 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.cognitiveservices.azure.com' - location: 'global' + name: 'privatelink.cognitiveservices.azure.com' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/cognitive-services/account/README.md b/modules/cognitive-services/account/README.md index 33ab28034c..ce8fb6197a 100644 --- a/modules/cognitive-services/account/README.md +++ b/modules/cognitive-services/account/README.md @@ -19,8 +19,8 @@ This module deploys a Cognitive Service. | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.CognitiveServices/accounts` | [2022-12-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.CognitiveServices/2022-12-01/accounts) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | ## Parameters @@ -51,7 +51,6 @@ This module deploys a Cognitive Service. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, Audit, RequestResponse]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -464,7 +463,6 @@ module account './cognitive-services/account/main.bicep' = { customSubDomainName: 'xdomain' diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -549,9 +547,6 @@ module account './cognitive-services/account/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/cognitive-services/account/main.bicep b/modules/cognitive-services/account/main.bicep index ffa145e7f9..a91549ef74 100644 --- a/modules/cognitive-services/account/main.bicep +++ b/modules/cognitive-services/account/main.bicep @@ -57,11 +57,6 @@ param sku string = 'S0' @description('Optional. Location for all Resources.') param location string = resourceGroup().location -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -175,20 +170,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -196,10 +183,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var enableReferencedModulesTelemetry = false diff --git a/modules/cognitive-services/account/main.json b/modules/cognitive-services/account/main.json index 86431278da..ab8819f327 100644 --- a/modules/cognitive-services/account/main.json +++ b/modules/cognitive-services/account/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13537365972823891615" - } + "version": "0.20.4.51522", + "templateHash": "3690928226777613324" + }, + "name": "Cognitive Services", + "description": "This module deploys a Cognitive Service.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -78,15 +81,6 @@ "description": "Optional. Location for all Resources." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -165,14 +159,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -321,11 +315,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -334,15 +324,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "enableReferencedModulesTelemetry": false, "identityType": "[if(parameters('systemAssignedIdentity'), if(not(empty(parameters('userAssignedIdentities'))), 'SystemAssigned,UserAssigned', 'SystemAssigned'), if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None'))]", "identity": "[if(not(equals(variables('identityType'), 'None')), createObject('type', variables('identityType'), 'userAssignedIdentities', if(not(empty(parameters('userAssignedIdentities'))), parameters('userAssignedIdentities'), null())), null())]" @@ -468,9 +454,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -535,14 +524,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -600,7 +589,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -665,9 +654,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -678,8 +670,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -730,7 +722,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -800,8 +792,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -971,7 +963,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -1014,8 +1006,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15138099271867749338" + "version": "0.20.4.51522", + "templateHash": "4975207925578075576" } }, "parameters": { diff --git a/modules/compute/availability-set/main.json b/modules/compute/availability-set/main.json index 26866c284d..0c3ce258ff 100644 --- a/modules/compute/availability-set/main.json +++ b/modules/compute/availability-set/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11509710715638918489" - } + "version": "0.20.4.51522", + "templateHash": "14627609112936541603" + }, + "name": "Availability Sets", + "description": "This module deploys an Availability Set.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -53,14 +56,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -162,8 +165,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13414727736673410356" + "version": "0.20.4.51522", + "templateHash": "2845847199363525157" } }, "parameters": { diff --git a/modules/compute/disk-encryption-set/main.json b/modules/compute/disk-encryption-set/main.json index 79ff57c1fc..4d470457e1 100644 --- a/modules/compute/disk-encryption-set/main.json +++ b/modules/compute/disk-encryption-set/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13941840651398754197" - } + "version": "0.20.4.51522", + "templateHash": "17994275321989817378" + }, + "name": "Disk Encryption Sets", + "description": "This module deploys a Disk Encryption Set.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -25,14 +28,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "keyVaultResourceId": { "type": "string", @@ -207,8 +210,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5266650210800919607" + "version": "0.20.4.51522", + "templateHash": "12898111153359655939" } }, "parameters": { @@ -283,8 +286,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15248304540243541293" + "version": "0.20.4.51522", + "templateHash": "10065918419981417666" } }, "parameters": { @@ -355,9 +358,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5956155025819321457" - } + "version": "0.20.4.51522", + "templateHash": "7542638391604115549" + }, + "name": "Key Vault Access Policies", + "description": "This module deploys a Key Vault Access Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "keyVaultName": { @@ -486,8 +492,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4632454948156980307" + "version": "0.20.4.51522", + "templateHash": "14948408905344933172" } }, "parameters": { diff --git a/modules/compute/disk/main.json b/modules/compute/disk/main.json index f61848be33..f3ea9a4781 100644 --- a/modules/compute/disk/main.json +++ b/modules/compute/disk/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10086023154618343477" - } + "version": "0.20.4.51522", + "templateHash": "3899309340586234055" + }, + "name": "Compute Disks", + "description": "This module deploys a Compute Disk", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -24,9 +27,6 @@ }, "sku": { "type": "string", - "metadata": { - "description": "Required. The disks sku name. Can be ." - }, "allowedValues": [ "Standard_LRS", "Premium_LRS", @@ -35,19 +35,22 @@ "Premium_ZRS", "Premium_ZRS", "PremiumV2_LRS" - ] + ], + "metadata": { + "description": "Required. The disks sku name. Can be ." + } }, "architecture": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. CPU architecture supported by an OS disk." - }, "allowedValues": [ "x64", "Arm64", "" - ] + ], + "metadata": { + "description": "Optional. CPU architecture supported by an OS disk." + } }, "burstingEnabled": { "type": "bool", @@ -66,9 +69,6 @@ "createOption": { "type": "string", "defaultValue": "Empty", - "metadata": { - "description": "Optional. Sources of a disk creation." - }, "allowedValues": [ "Attach", "Copy", @@ -80,7 +80,10 @@ "Restore", "Upload", "UploadPreparedSecure" - ] + ], + "metadata": { + "description": "Optional. Sources of a disk creation." + } }, "imageReferenceId": { "type": "string", @@ -155,13 +158,13 @@ "hyperVGeneration": { "type": "string", "defaultValue": "V2", - "metadata": { - "description": "Optional. The hypervisor generation of the Virtual Machine. Applicable to OS disks only." - }, "allowedValues": [ "V1", "V2" - ] + ], + "metadata": { + "description": "Optional. The hypervisor generation of the Virtual Machine. Applicable to OS disks only." + } }, "maxShares": { "type": "int", @@ -173,14 +176,14 @@ "networkAccessPolicy": { "type": "string", "defaultValue": "DenyAll", - "metadata": { - "description": "Optional. Policy for accessing the disk via network." - }, "allowedValues": [ "AllowAll", "AllowPrivate", "DenyAll" - ] + ], + "metadata": { + "description": "Optional. Policy for accessing the disk via network." + } }, "optimizedForFrequentAttach": { "type": "bool", @@ -192,25 +195,25 @@ "osType": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Sources of a disk creation." - }, "allowedValues": [ "Windows", "Linux", "" - ] + ], + "metadata": { + "description": "Optional. Sources of a disk creation." + } }, "publicNetworkAccess": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Policy for controlling export on the disk." - }, "allowedValues": [ "Disabled", "Enabled" - ] + ], + "metadata": { + "description": "Optional. Policy for controlling export on the disk." + } }, "acceleratedNetwork": { "type": "bool", @@ -222,14 +225,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -350,8 +353,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12749624585003590955" + "version": "0.20.4.51522", + "templateHash": "7275007937766234540" } }, "parameters": { diff --git a/modules/compute/gallery/application/main.json b/modules/compute/gallery/application/main.json index 9970d4592d..723172da86 100644 --- a/modules/compute/gallery/application/main.json +++ b/modules/compute/gallery/application/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4712377854140060080" - } + "version": "0.20.4.51522", + "templateHash": "302763326863799273" + }, + "name": "Compute Galleries Applications", + "description": "This module deploys an Azure Compute Gallery Application.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -169,8 +172,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "992879911082543993" + "version": "0.20.4.51522", + "templateHash": "3891555929973685105" } }, "parameters": { diff --git a/modules/compute/gallery/image/main.json b/modules/compute/gallery/image/main.json index 91e4fbd3fb..3cc4aa0a12 100644 --- a/modules/compute/gallery/image/main.json +++ b/modules/compute/gallery/image/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1301061718242455583" - } + "version": "0.20.4.51522", + "templateHash": "14112753208892308004" + }, + "name": "Compute Galleries Image Definitions", + "description": "This module deploys an Azure Compute Gallery Image Definition.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -82,8 +85,8 @@ "minRecommendedvCPUs": { "type": "int", "defaultValue": 1, - "maxValue": 128, "minValue": 1, + "maxValue": 128, "metadata": { "description": "Optional. The minimum number of the CPU cores recommended for this image." } @@ -91,8 +94,8 @@ "maxRecommendedvCPUs": { "type": "int", "defaultValue": 4, - "maxValue": 128, "minValue": 1, + "maxValue": 128, "metadata": { "description": "Optional. The maximum number of the CPU cores recommended for this image." } @@ -100,8 +103,8 @@ "minRecommendedMemory": { "type": "int", "defaultValue": 4, - "maxValue": 4000, "minValue": 1, + "maxValue": 4000, "metadata": { "description": "Optional. The minimum amount of RAM in GB recommended for this image." } @@ -109,8 +112,8 @@ "maxRecommendedMemory": { "type": "int", "defaultValue": 16, - "maxValue": 4000, "minValue": 1, + "maxValue": 4000, "metadata": { "description": "Optional. The maximum amount of RAM in GB recommended for this image." } @@ -330,8 +333,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16144820657592071665" + "version": "0.20.4.51522", + "templateHash": "5875220683176267757" } }, "parameters": { diff --git a/modules/compute/gallery/main.json b/modules/compute/gallery/main.json index cb95bb2bd6..cc5bd0ca1c 100644 --- a/modules/compute/gallery/main.json +++ b/modules/compute/gallery/main.json @@ -4,17 +4,20 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13901468473811502546" - } + "version": "0.20.4.51522", + "templateHash": "15984862915086923960" + }, + "name": "Azure Compute Galleries", + "description": "This module deploys an Azure Compute Gallery (formerly known as Shared Image Gallery).", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { "type": "string", + "minLength": 1, "metadata": { "description": "Required. Name of the Azure Compute Gallery." - }, - "minLength": 1 + } }, "location": { "type": "string", @@ -47,14 +50,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -155,8 +158,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12286644635375921182" + "version": "0.20.4.51522", + "templateHash": "889221691935593360" } }, "parameters": { @@ -330,9 +333,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4712377854140060080" - } + "version": "0.20.4.51522", + "templateHash": "302763326863799273" + }, + "name": "Compute Galleries Applications", + "description": "This module deploys an Azure Compute Gallery Application.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -495,8 +501,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "992879911082543993" + "version": "0.20.4.51522", + "templateHash": "3891555929973685105" } }, "parameters": { @@ -720,9 +726,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1301061718242455583" - } + "version": "0.20.4.51522", + "templateHash": "14112753208892308004" + }, + "name": "Compute Galleries Image Definitions", + "description": "This module deploys an Azure Compute Gallery Image Definition.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -798,8 +807,8 @@ "minRecommendedvCPUs": { "type": "int", "defaultValue": 1, - "maxValue": 128, "minValue": 1, + "maxValue": 128, "metadata": { "description": "Optional. The minimum number of the CPU cores recommended for this image." } @@ -807,8 +816,8 @@ "maxRecommendedvCPUs": { "type": "int", "defaultValue": 4, - "maxValue": 128, "minValue": 1, + "maxValue": 128, "metadata": { "description": "Optional. The maximum number of the CPU cores recommended for this image." } @@ -816,8 +825,8 @@ "minRecommendedMemory": { "type": "int", "defaultValue": 4, - "maxValue": 4000, "minValue": 1, + "maxValue": 4000, "metadata": { "description": "Optional. The minimum amount of RAM in GB recommended for this image." } @@ -825,8 +834,8 @@ "maxRecommendedMemory": { "type": "int", "defaultValue": 16, - "maxValue": 4000, "minValue": 1, + "maxValue": 4000, "metadata": { "description": "Optional. The maximum amount of RAM in GB recommended for this image." } @@ -1046,8 +1055,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16144820657592071665" + "version": "0.20.4.51522", + "templateHash": "5875220683176267757" } }, "parameters": { diff --git a/modules/compute/image/main.json b/modules/compute/image/main.json index e3c1fdd350..50b35bac9c 100644 --- a/modules/compute/image/main.json +++ b/modules/compute/image/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16025474284352958130" - } + "version": "0.20.4.51522", + "templateHash": "13634156293178921650" + }, + "name": "Images", + "description": "This module deploys a Compute Image.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -218,8 +221,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4688438158405140777" + "version": "0.20.4.51522", + "templateHash": "15836902918863510796" } }, "parameters": { diff --git a/modules/compute/proximity-placement-group/main.json b/modules/compute/proximity-placement-group/main.json index 2f59ba626a..9090e4109e 100644 --- a/modules/compute/proximity-placement-group/main.json +++ b/modules/compute/proximity-placement-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16971280078864146158" - } + "version": "0.20.4.51522", + "templateHash": "11762560439975541015" + }, + "name": "Proximity Placement Groups", + "description": "This module deploys a Proximity Placement Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -36,14 +39,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -164,8 +167,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1938170215691677826" + "version": "0.20.4.51522", + "templateHash": "2254381804917043935" } }, "parameters": { diff --git a/modules/compute/ssh-public-key/main.json b/modules/compute/ssh-public-key/main.json index 139033c803..0f9fec8cd7 100644 --- a/modules/compute/ssh-public-key/main.json +++ b/modules/compute/ssh-public-key/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16443022752471991339" - } + "version": "0.20.4.51522", + "templateHash": "3176936377185255192" + }, + "name": "Public SSH Keys", + "description": "This module deploys a Public SSH Key.\r\n\r\n> Note: The resource does not auto-generate the key for you.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -32,14 +35,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -136,8 +139,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3437555523644485146" + "version": "0.20.4.51522", + "templateHash": "15802588423286494574" } }, "parameters": { diff --git a/modules/compute/virtual-machine-scale-set/.test/linux.min/dependencies.bicep b/modules/compute/virtual-machine-scale-set/.test/linux.min/dependencies.bicep index b422cdfbe5..f524629de7 100644 --- a/modules/compute/virtual-machine-scale-set/.test/linux.min/dependencies.bicep +++ b/modules/compute/virtual-machine-scale-set/.test/linux.min/dependencies.bicep @@ -15,68 +15,68 @@ param sshKeyName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource msiRGContrRoleAssignment 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid(resourceGroup().id, 'Contributor', managedIdentity.id) - scope: resourceGroup() - properties: { - principalId: managedIdentity.properties.principalId - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'b24988ac-6180-42a0-ab88-20f7382dd24c') // Contributor - principalType: 'ServicePrincipal' - } + name: guid(resourceGroup().id, 'Contributor', managedIdentity.id) + scope: resourceGroup() + properties: { + principalId: managedIdentity.properties.principalId + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'b24988ac-6180-42a0-ab88-20f7382dd24c') // Contributor + principalType: 'ServicePrincipal' + } } resource sshDeploymentScript 'Microsoft.Resources/deploymentScripts@2020-10-01' = { - name: sshDeploymentScriptName - location: location - kind: 'AzurePowerShell' - identity: { - type: 'UserAssigned' - userAssignedIdentities: { - '${managedIdentity.id}': {} - } - } - properties: { - azPowerShellVersion: '9.0' - retentionInterval: 'P1D' - arguments: '-SSHKeyName "${sshKeyName}" -ResourceGroupName "${resourceGroup().name}"' - scriptContent: loadTextContent('../../../../.shared/.scripts/New-SSHKey.ps1') + name: sshDeploymentScriptName + location: location + kind: 'AzurePowerShell' + identity: { + type: 'UserAssigned' + userAssignedIdentities: { + '${managedIdentity.id}': {} } - dependsOn: [ - msiRGContrRoleAssignment - ] + } + properties: { + azPowerShellVersion: '9.0' + retentionInterval: 'P1D' + arguments: '-SSHKeyName "${sshKeyName}" -ResourceGroupName "${resourceGroup().name}"' + scriptContent: loadTextContent('../../../../.shared/.scripts/New-SSHKey.ps1') + } + dependsOn: [ + msiRGContrRoleAssignment + ] } resource sshKey 'Microsoft.Compute/sshPublicKeys@2022-03-01' = { - name: sshKeyName - location: location - properties: { - publicKey: sshDeploymentScript.properties.outputs.publicKey - } + name: sshKeyName + location: location + properties: { + publicKey: sshDeploymentScript.properties.outputs.publicKey + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/compute/virtual-machine-scale-set/.test/linux.ssecmk/dependencies.bicep b/modules/compute/virtual-machine-scale-set/.test/linux.ssecmk/dependencies.bicep index 4b1e9aa4f9..ac1e0c0114 100644 --- a/modules/compute/virtual-machine-scale-set/.test/linux.ssecmk/dependencies.bicep +++ b/modules/compute/virtual-machine-scale-set/.test/linux.ssecmk/dependencies.bicep @@ -21,7 +21,7 @@ param location string = resourceGroup().location var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkName location: location properties: { diff --git a/modules/compute/virtual-machine-scale-set/.test/linux/dependencies.bicep b/modules/compute/virtual-machine-scale-set/.test/linux/dependencies.bicep index 28cb5c9a71..139519d9ca 100644 --- a/modules/compute/virtual-machine-scale-set/.test/linux/dependencies.bicep +++ b/modules/compute/virtual-machine-scale-set/.test/linux/dependencies.bicep @@ -25,141 +25,141 @@ param sshKeyName string var storageAccountCSEFileName = 'scriptExtensionMasterInstaller.ps1' var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource keyVault 'Microsoft.KeyVault/vaults@2022-07-01' = { - name: keyVaultName - location: location - properties: { - sku: { - family: 'A' - name: 'standard' - } - tenantId: tenant().tenantId - enablePurgeProtection: null - enabledForTemplateDeployment: true - enabledForDiskEncryption: true - enabledForDeployment: true - enableRbacAuthorization: true - accessPolicies: [] + name: keyVaultName + location: location + properties: { + sku: { + family: 'A' + name: 'standard' } - - resource key 'keys@2022-07-01' = { - name: 'encryptionKey' - properties: { - kty: 'RSA' - } + tenantId: tenant().tenantId + enablePurgeProtection: null + enabledForTemplateDeployment: true + enabledForDiskEncryption: true + enabledForDeployment: true + enableRbacAuthorization: true + accessPolicies: [] + } + + resource key 'keys@2022-07-01' = { + name: 'encryptionKey' + properties: { + kty: 'RSA' } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource msiRGContrRoleAssignment 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid(resourceGroup().id, 'Contributor', managedIdentity.id) - scope: resourceGroup() - properties: { - principalId: managedIdentity.properties.principalId - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'b24988ac-6180-42a0-ab88-20f7382dd24c') // Contributor - principalType: 'ServicePrincipal' - } + name: guid(resourceGroup().id, 'Contributor', managedIdentity.id) + scope: resourceGroup() + properties: { + principalId: managedIdentity.properties.principalId + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'b24988ac-6180-42a0-ab88-20f7382dd24c') // Contributor + principalType: 'ServicePrincipal' + } } resource msiKVCryptoUserRoleAssignment 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid(keyVault::key.id, 'Key Vault Crypto User', managedIdentity.id) - scope: keyVault::key - properties: { - principalId: managedIdentity.properties.principalId - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '12338af0-0e69-4776-bea7-57ae8d297424') // Key Vault Crypto User - principalType: 'ServicePrincipal' - } + name: guid(keyVault::key.id, 'Key Vault Crypto User', managedIdentity.id) + scope: keyVault::key + properties: { + principalId: managedIdentity.properties.principalId + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '12338af0-0e69-4776-bea7-57ae8d297424') // Key Vault Crypto User + principalType: 'ServicePrincipal' + } } resource storageAccount 'Microsoft.Storage/storageAccounts@2021-09-01' = { - name: storageAccountName - location: location - sku: { - name: 'Standard_LRS' - } - kind: 'StorageV2' - - resource blobService 'blobServices@2021-09-01' = { - name: 'default' - - resource container 'containers@2021-09-01' = { - name: 'scripts' - } + name: storageAccountName + location: location + sku: { + name: 'Standard_LRS' + } + kind: 'StorageV2' + + resource blobService 'blobServices@2021-09-01' = { + name: 'default' + + resource container 'containers@2021-09-01' = { + name: 'scripts' } + } } resource storageUpload 'Microsoft.Resources/deploymentScripts@2020-10-01' = { - name: storageUploadDeploymentScriptName - location: location - kind: 'AzurePowerShell' - identity: { - type: 'UserAssigned' - userAssignedIdentities: { - '${managedIdentity.id}': {} - } - } - properties: { - azPowerShellVersion: '9.0' - retentionInterval: 'P1D' - arguments: '-StorageAccountName "${storageAccount.name}" -ResourceGroupName "${resourceGroup().name}" -ContainerName "${storageAccount::blobService::container.name}" -FileName "${storageAccountCSEFileName}"' - scriptContent: loadTextContent('../../../../.shared/.scripts/Set-BlobContent.ps1') + name: storageUploadDeploymentScriptName + location: location + kind: 'AzurePowerShell' + identity: { + type: 'UserAssigned' + userAssignedIdentities: { + '${managedIdentity.id}': {} } - dependsOn: [ - msiRGContrRoleAssignment - ] + } + properties: { + azPowerShellVersion: '9.0' + retentionInterval: 'P1D' + arguments: '-StorageAccountName "${storageAccount.name}" -ResourceGroupName "${resourceGroup().name}" -ContainerName "${storageAccount::blobService::container.name}" -FileName "${storageAccountCSEFileName}"' + scriptContent: loadTextContent('../../../../.shared/.scripts/Set-BlobContent.ps1') + } + dependsOn: [ + msiRGContrRoleAssignment + ] } resource sshDeploymentScript 'Microsoft.Resources/deploymentScripts@2020-10-01' = { - name: sshDeploymentScriptName - location: location - kind: 'AzurePowerShell' - identity: { - type: 'UserAssigned' - userAssignedIdentities: { - '${managedIdentity.id}': {} - } - } - properties: { - azPowerShellVersion: '9.0' - retentionInterval: 'P1D' - arguments: '-SSHKeyName "${sshKeyName}" -ResourceGroupName "${resourceGroup().name}"' - scriptContent: loadTextContent('../../../../.shared/.scripts/New-SSHKey.ps1') + name: sshDeploymentScriptName + location: location + kind: 'AzurePowerShell' + identity: { + type: 'UserAssigned' + userAssignedIdentities: { + '${managedIdentity.id}': {} } - dependsOn: [ - msiRGContrRoleAssignment - ] + } + properties: { + azPowerShellVersion: '9.0' + retentionInterval: 'P1D' + arguments: '-SSHKeyName "${sshKeyName}" -ResourceGroupName "${resourceGroup().name}"' + scriptContent: loadTextContent('../../../../.shared/.scripts/New-SSHKey.ps1') + } + dependsOn: [ + msiRGContrRoleAssignment + ] } resource sshKey 'Microsoft.Compute/sshPublicKeys@2022-03-01' = { - name: sshKeyName - location: location - properties: { - publicKey: sshDeploymentScript.properties.outputs.publicKey - } + name: sshKeyName + location: location + properties: { + publicKey: sshDeploymentScript.properties.outputs.publicKey + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/compute/virtual-machine-scale-set/.test/linux/main.test.bicep b/modules/compute/virtual-machine-scale-set/.test/linux/main.test.bicep index d119ea7240..08c5931815 100644 --- a/modules/compute/virtual-machine-scale-set/.test/linux/main.test.bicep +++ b/modules/compute/virtual-machine-scale-set/.test/linux/main.test.bicep @@ -111,7 +111,6 @@ module testDeployment '../../main.bicep' = { diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diagnosticEventHubName: diagnosticDependencies.outputs.eventHubNamespaceEventHubName - diagnosticLogsRetentionInDays: 7 disablePasswordAuthentication: true encryptionAtHost: false extensionCustomScriptConfig: { diff --git a/modules/compute/virtual-machine-scale-set/.test/windows.min/dependencies.bicep b/modules/compute/virtual-machine-scale-set/.test/windows.min/dependencies.bicep index 35801ed823..a163531213 100644 --- a/modules/compute/virtual-machine-scale-set/.test/windows.min/dependencies.bicep +++ b/modules/compute/virtual-machine-scale-set/.test/windows.min/dependencies.bicep @@ -6,24 +6,24 @@ param virtualNetworkName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/compute/virtual-machine-scale-set/.test/windows/dependencies.bicep b/modules/compute/virtual-machine-scale-set/.test/windows/dependencies.bicep index dc24396d8c..5392bb96c3 100644 --- a/modules/compute/virtual-machine-scale-set/.test/windows/dependencies.bicep +++ b/modules/compute/virtual-machine-scale-set/.test/windows/dependencies.bicep @@ -22,117 +22,117 @@ param proximityPlacementGroupName string var storageAccountCSEFileName = 'scriptExtensionMasterInstaller.ps1' var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource keyVault 'Microsoft.KeyVault/vaults@2022-07-01' = { - name: keyVaultName - location: location - properties: { - sku: { - family: 'A' - name: 'standard' - } - tenantId: tenant().tenantId - enablePurgeProtection: null - enabledForTemplateDeployment: true - enabledForDiskEncryption: true - enabledForDeployment: true - enableRbacAuthorization: true - accessPolicies: [] + name: keyVaultName + location: location + properties: { + sku: { + family: 'A' + name: 'standard' } - - resource key 'keys@2022-07-01' = { - name: 'encryptionKey' - properties: { - kty: 'RSA' - } + tenantId: tenant().tenantId + enablePurgeProtection: null + enabledForTemplateDeployment: true + enabledForDiskEncryption: true + enabledForDeployment: true + enableRbacAuthorization: true + accessPolicies: [] + } + + resource key 'keys@2022-07-01' = { + name: 'encryptionKey' + properties: { + kty: 'RSA' } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource msiRGContrRoleAssignment 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid(resourceGroup().id, 'Contributor', managedIdentity.id) - scope: resourceGroup() - properties: { - principalId: managedIdentity.properties.principalId - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'b24988ac-6180-42a0-ab88-20f7382dd24c') // Contributor - principalType: 'ServicePrincipal' - } + name: guid(resourceGroup().id, 'Contributor', managedIdentity.id) + scope: resourceGroup() + properties: { + principalId: managedIdentity.properties.principalId + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'b24988ac-6180-42a0-ab88-20f7382dd24c') // Contributor + principalType: 'ServicePrincipal' + } } resource msiKVCryptoUserRoleAssignment 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid(keyVault::key.id, 'Key Vault Crypto User', managedIdentity.id) - scope: keyVault::key - properties: { - principalId: managedIdentity.properties.principalId - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '12338af0-0e69-4776-bea7-57ae8d297424') // Key Vault Crypto User - principalType: 'ServicePrincipal' - } + name: guid(keyVault::key.id, 'Key Vault Crypto User', managedIdentity.id) + scope: keyVault::key + properties: { + principalId: managedIdentity.properties.principalId + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '12338af0-0e69-4776-bea7-57ae8d297424') // Key Vault Crypto User + principalType: 'ServicePrincipal' + } } resource storageAccount 'Microsoft.Storage/storageAccounts@2021-09-01' = { - name: storageAccountName - location: location - sku: { - name: 'Standard_LRS' - } - kind: 'StorageV2' - - resource blobService 'blobServices@2021-09-01' = { - name: 'default' - - resource container 'containers@2021-09-01' = { - name: 'scripts' - } + name: storageAccountName + location: location + sku: { + name: 'Standard_LRS' + } + kind: 'StorageV2' + + resource blobService 'blobServices@2021-09-01' = { + name: 'default' + + resource container 'containers@2021-09-01' = { + name: 'scripts' } + } } resource storageUpload 'Microsoft.Resources/deploymentScripts@2020-10-01' = { - name: storageUploadDeploymentScriptName - location: location - kind: 'AzurePowerShell' - identity: { - type: 'UserAssigned' - userAssignedIdentities: { - '${managedIdentity.id}': {} - } + name: storageUploadDeploymentScriptName + location: location + kind: 'AzurePowerShell' + identity: { + type: 'UserAssigned' + userAssignedIdentities: { + '${managedIdentity.id}': {} } - properties: { - azPowerShellVersion: '9.0' - retentionInterval: 'P1D' - arguments: '-StorageAccountName "${storageAccount.name}" -ResourceGroupName "${resourceGroup().name}" -ContainerName "${storageAccount::blobService::container.name}" -FileName "${storageAccountCSEFileName}"' - scriptContent: loadTextContent('../../../../.shared/.scripts/Set-BlobContent.ps1') - } - dependsOn: [ - msiRGContrRoleAssignment - ] + } + properties: { + azPowerShellVersion: '9.0' + retentionInterval: 'P1D' + arguments: '-StorageAccountName "${storageAccount.name}" -ResourceGroupName "${resourceGroup().name}" -ContainerName "${storageAccount::blobService::container.name}" -FileName "${storageAccountCSEFileName}"' + scriptContent: loadTextContent('../../../../.shared/.scripts/Set-BlobContent.ps1') + } + dependsOn: [ + msiRGContrRoleAssignment + ] } resource proximityPlacementGroup 'Microsoft.Compute/proximityPlacementGroups@2022-03-01' = { - name: proximityPlacementGroupName - location: location + name: proximityPlacementGroupName + location: location } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/compute/virtual-machine-scale-set/.test/windows/main.test.bicep b/modules/compute/virtual-machine-scale-set/.test/windows/main.test.bicep index 21a5d78570..c6694102a5 100644 --- a/modules/compute/virtual-machine-scale-set/.test/windows/main.test.bicep +++ b/modules/compute/virtual-machine-scale-set/.test/windows/main.test.bicep @@ -93,7 +93,6 @@ module testDeployment '../../main.bicep' = { diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diagnosticEventHubName: diagnosticDependencies.outputs.eventHubNamespaceEventHubName - diagnosticLogsRetentionInDays: 7 encryptionAtHost: false extensionAntiMalwareConfig: { enabled: true diff --git a/modules/compute/virtual-machine-scale-set/README.md b/modules/compute/virtual-machine-scale-set/README.md index 4ec607b828..b0384b82da 100644 --- a/modules/compute/virtual-machine-scale-set/README.md +++ b/modules/compute/virtual-machine-scale-set/README.md @@ -54,7 +54,6 @@ The following resources are required to be able to deploy this resource. | `dataDisks` | array | `[]` | | Specifies the data disks. For security reasons, it is recommended to specify DiskEncryptionSet into the dataDisk object. Restrictions: DiskEncryptionSet cannot be enabled if Azure Disk Encryption (guest-VM encryption using bitlocker/DM-Crypt) is enabled on your VM Scale sets. | | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | | `diagnosticWorkspaceId` | string | `''` | | Resource ID of the diagnostic log analytics workspace. | @@ -955,7 +954,6 @@ module virtualMachineScaleSet './compute/virtual-machine-scale-set/main.bicep' = ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' disablePasswordAuthentication: true @@ -1119,9 +1117,6 @@ module virtualMachineScaleSet './compute/virtual-machine-scale-set/main.bicep' = "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, @@ -1609,7 +1604,6 @@ module virtualMachineScaleSet './compute/virtual-machine-scale-set/main.bicep' = adminPassword: '' diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -1762,9 +1756,6 @@ module virtualMachineScaleSet './compute/virtual-machine-scale-set/main.bicep' = "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/compute/virtual-machine-scale-set/extension/main.json b/modules/compute/virtual-machine-scale-set/extension/main.json index 15f2398d22..14783762a8 100644 --- a/modules/compute/virtual-machine-scale-set/extension/main.json +++ b/modules/compute/virtual-machine-scale-set/extension/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16938226056341383577" - } + "version": "0.20.4.51522", + "templateHash": "3045861199823874082" + }, + "name": "Virtual Machine Scale Set Extensions", + "description": "This module deploys a Virtual Machine Scale Set Extension.", + "owner": "Azure/module-maintainers" }, "parameters": { "virtualMachineScaleSetName": { diff --git a/modules/compute/virtual-machine-scale-set/main.bicep b/modules/compute/virtual-machine-scale-set/main.bicep index 129d0fbec0..fbd688e838 100644 --- a/modules/compute/virtual-machine-scale-set/main.bicep +++ b/modules/compute/virtual-machine-scale-set/main.bicep @@ -134,11 +134,6 @@ param bootDiagnosticStorageAccountUri string = '.blob.${environment().suffixes.s @description('Optional. Storage account used to store boot diagnostic information. Boot diagnostics will be disabled if no value is provided.') param bootDiagnosticStorageAccountName string = '' -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -293,10 +288,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var publicKeysFormatted = [for publicKey in publicKeys: { diff --git a/modules/compute/virtual-machine-scale-set/main.json b/modules/compute/virtual-machine-scale-set/main.json index 5ee96b3421..89b7b6a2ca 100644 --- a/modules/compute/virtual-machine-scale-set/main.json +++ b/modules/compute/virtual-machine-scale-set/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4825093771557214886" - } + "version": "0.20.4.51522", + "templateHash": "7715429520805746473" + }, + "name": "Virtual Machine Scale Sets", + "description": "This module deploys a Virtual Machine Scale Set.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -270,15 +273,6 @@ "description": "Optional. Storage account used to store boot diagnostic information. Boot diagnostics will be disabled if no value is provided." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -310,14 +304,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "upgradePolicyMode": { "type": "string", @@ -390,8 +384,8 @@ "vmNamePrefix": { "type": "string", "defaultValue": "vmssvm", - "maxLength": 15, "minLength": 1, + "maxLength": 15, "metadata": { "description": "Optional. Specifies the computer name prefix for all of the virtual machines in the scale set." } @@ -598,11 +592,7 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -852,9 +842,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16938226056341383577" - } + "version": "0.20.4.51522", + "templateHash": "3045861199823874082" + }, + "name": "Virtual Machine Scale Set Extensions", + "description": "This module deploys a Virtual Machine Scale Set Extension.", + "owner": "Azure/module-maintainers" }, "parameters": { "virtualMachineScaleSetName": { @@ -1035,9 +1028,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16938226056341383577" - } + "version": "0.20.4.51522", + "templateHash": "3045861199823874082" + }, + "name": "Virtual Machine Scale Set Extensions", + "description": "This module deploys a Virtual Machine Scale Set Extension.", + "owner": "Azure/module-maintainers" }, "parameters": { "virtualMachineScaleSetName": { @@ -1223,9 +1219,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16938226056341383577" - } + "version": "0.20.4.51522", + "templateHash": "3045861199823874082" + }, + "name": "Virtual Machine Scale Set Extensions", + "description": "This module deploys a Virtual Machine Scale Set Extension.", + "owner": "Azure/module-maintainers" }, "parameters": { "virtualMachineScaleSetName": { @@ -1401,9 +1400,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16938226056341383577" - } + "version": "0.20.4.51522", + "templateHash": "3045861199823874082" + }, + "name": "Virtual Machine Scale Set Extensions", + "description": "This module deploys a Virtual Machine Scale Set Extension.", + "owner": "Azure/module-maintainers" }, "parameters": { "virtualMachineScaleSetName": { @@ -1579,9 +1581,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16938226056341383577" - } + "version": "0.20.4.51522", + "templateHash": "3045861199823874082" + }, + "name": "Virtual Machine Scale Set Extensions", + "description": "This module deploys a Virtual Machine Scale Set Extension.", + "owner": "Azure/module-maintainers" }, "parameters": { "virtualMachineScaleSetName": { @@ -1761,9 +1766,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16938226056341383577" - } + "version": "0.20.4.51522", + "templateHash": "3045861199823874082" + }, + "name": "Virtual Machine Scale Set Extensions", + "description": "This module deploys a Virtual Machine Scale Set Extension.", + "owner": "Azure/module-maintainers" }, "parameters": { "virtualMachineScaleSetName": { @@ -1949,9 +1957,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16938226056341383577" - } + "version": "0.20.4.51522", + "templateHash": "3045861199823874082" + }, + "name": "Virtual Machine Scale Set Extensions", + "description": "This module deploys a Virtual Machine Scale Set Extension.", + "owner": "Azure/module-maintainers" }, "parameters": { "virtualMachineScaleSetName": { @@ -2132,9 +2143,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16938226056341383577" - } + "version": "0.20.4.51522", + "templateHash": "3045861199823874082" + }, + "name": "Virtual Machine Scale Set Extensions", + "description": "This module deploys a Virtual Machine Scale Set Extension.", + "owner": "Azure/module-maintainers" }, "parameters": { "virtualMachineScaleSetName": { @@ -2312,8 +2326,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4840060024448665942" + "version": "0.20.4.51522", + "templateHash": "8957967426136290703" } }, "parameters": { diff --git a/modules/compute/virtual-machine/.bicep/nested_networkInterface.bicep b/modules/compute/virtual-machine/.bicep/nested_networkInterface.bicep index a89602200b..20386a51b8 100644 --- a/modules/compute/virtual-machine/.bicep/nested_networkInterface.bicep +++ b/modules/compute/virtual-machine/.bicep/nested_networkInterface.bicep @@ -12,7 +12,6 @@ param networkSecurityGroupResourceId string = '' param ipConfigurations array param lock string = '' param diagnosticStorageAccountId string -param diagnosticLogsRetentionInDays int param diagnosticWorkspaceId string param diagnosticEventHubAuthorizationRuleId string param diagnosticEventHubName string @@ -38,7 +37,6 @@ module networkInterface_publicIPAddresses '../../../network/public-ip-address/ma diagnosticEventHubAuthorizationRuleId: diagnosticEventHubAuthorizationRuleId diagnosticEventHubName: diagnosticEventHubName diagnosticLogCategoriesToEnable: pipdiagnosticLogCategoriesToEnable - diagnosticLogsRetentionInDays: diagnosticLogsRetentionInDays diagnosticMetricsToEnable: pipdiagnosticMetricsToEnable diagnosticSettingsName: pipDiagnosticSettingsName diagnosticStorageAccountId: diagnosticStorageAccountId @@ -80,7 +78,6 @@ module networkInterface '../../../network/network-interface/main.bicep' = { tags: tags diagnosticEventHubAuthorizationRuleId: diagnosticEventHubAuthorizationRuleId diagnosticEventHubName: diagnosticEventHubName - diagnosticLogsRetentionInDays: diagnosticLogsRetentionInDays diagnosticStorageAccountId: diagnosticStorageAccountId diagnosticMetricsToEnable: nicDiagnosticMetricsToEnable diagnosticSettingsName: nicDiagnosticSettingsName diff --git a/modules/compute/virtual-machine/.test/linux.atmg/dependencies.bicep b/modules/compute/virtual-machine/.test/linux.atmg/dependencies.bicep index 238e6cea30..bec794c98b 100644 --- a/modules/compute/virtual-machine/.test/linux.atmg/dependencies.bicep +++ b/modules/compute/virtual-machine/.test/linux.atmg/dependencies.bicep @@ -15,7 +15,7 @@ param location string = resourceGroup().location var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkName location: location properties: { diff --git a/modules/compute/virtual-machine/.test/linux.min/dependencies.bicep b/modules/compute/virtual-machine/.test/linux.min/dependencies.bicep index 0b8a697f07..c2785277dd 100644 --- a/modules/compute/virtual-machine/.test/linux.min/dependencies.bicep +++ b/modules/compute/virtual-machine/.test/linux.min/dependencies.bicep @@ -15,7 +15,7 @@ param location string = resourceGroup().location var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkName location: location properties: { diff --git a/modules/compute/virtual-machine/.test/linux/dependencies.bicep b/modules/compute/virtual-machine/.test/linux/dependencies.bicep index f3fbfcbf2b..7eada55540 100644 --- a/modules/compute/virtual-machine/.test/linux/dependencies.bicep +++ b/modules/compute/virtual-machine/.test/linux/dependencies.bicep @@ -34,7 +34,7 @@ param location string = resourceGroup().location var storageAccountCSEFileName = 'scriptExtensionMasterInstaller.ps1' var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkName location: location properties: { @@ -54,7 +54,7 @@ resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { } } -resource applicationSecurityGroup 'Microsoft.Network/applicationSecurityGroups@2022-01-01' = { +resource applicationSecurityGroup 'Microsoft.Network/applicationSecurityGroups@2023-04-01' = { name: applicationSecurityGroupName location: location } @@ -74,7 +74,7 @@ resource msiRGContrRoleAssignment 'Microsoft.Authorization/roleAssignments@2022- } } -resource loadBalancer 'Microsoft.Network/loadBalancers@2022-01-01' = { +resource loadBalancer 'Microsoft.Network/loadBalancers@2023-04-01' = { name: loadBalancerName location: location sku: { diff --git a/modules/compute/virtual-machine/.test/linux/main.test.bicep b/modules/compute/virtual-machine/.test/linux/main.test.bicep index fc8e3b07af..f85bc4d585 100644 --- a/modules/compute/virtual-machine/.test/linux/main.test.bicep +++ b/modules/compute/virtual-machine/.test/linux/main.test.bicep @@ -166,7 +166,6 @@ module testDeployment '../../main.bicep' = { diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diagnosticEventHubName: diagnosticDependencies.outputs.eventHubNamespaceEventHubName - diagnosticLogsRetentionInDays: 7 disablePasswordAuthentication: true encryptionAtHost: false extensionCustomScriptConfig: { diff --git a/modules/compute/virtual-machine/.test/windows.atmg/dependencies.bicep b/modules/compute/virtual-machine/.test/windows.atmg/dependencies.bicep index 51d5f6bb36..fb8e43c609 100644 --- a/modules/compute/virtual-machine/.test/windows.atmg/dependencies.bicep +++ b/modules/compute/virtual-machine/.test/windows.atmg/dependencies.bicep @@ -6,7 +6,7 @@ param location string = resourceGroup().location var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkName location: location properties: { diff --git a/modules/compute/virtual-machine/.test/windows.min/dependencies.bicep b/modules/compute/virtual-machine/.test/windows.min/dependencies.bicep index 4157fbe2b2..683dc9d4f4 100644 --- a/modules/compute/virtual-machine/.test/windows.min/dependencies.bicep +++ b/modules/compute/virtual-machine/.test/windows.min/dependencies.bicep @@ -6,7 +6,7 @@ param location string = resourceGroup().location var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkName location: location properties: { diff --git a/modules/compute/virtual-machine/.test/windows.ssecmk/dependencies.bicep b/modules/compute/virtual-machine/.test/windows.ssecmk/dependencies.bicep index 7f2ed7d2ce..05648243b5 100644 --- a/modules/compute/virtual-machine/.test/windows.ssecmk/dependencies.bicep +++ b/modules/compute/virtual-machine/.test/windows.ssecmk/dependencies.bicep @@ -12,7 +12,7 @@ param location string = resourceGroup().location var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkName location: location properties: { diff --git a/modules/compute/virtual-machine/.test/windows/dependencies.bicep b/modules/compute/virtual-machine/.test/windows/dependencies.bicep index d43b805cdf..7c37c57013 100644 --- a/modules/compute/virtual-machine/.test/windows/dependencies.bicep +++ b/modules/compute/virtual-machine/.test/windows/dependencies.bicep @@ -31,7 +31,7 @@ param location string = resourceGroup().location var storageAccountCSEFileName = 'scriptExtensionMasterInstaller.ps1' var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkName location: location properties: { @@ -51,7 +51,7 @@ resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { } } -resource applicationSecurityGroup 'Microsoft.Network/applicationSecurityGroups@2022-01-01' = { +resource applicationSecurityGroup 'Microsoft.Network/applicationSecurityGroups@2023-04-01' = { name: applicationSecurityGroupName location: location } @@ -71,7 +71,7 @@ resource msiRGContrRoleAssignment 'Microsoft.Authorization/roleAssignments@2022- } } -resource loadBalancer 'Microsoft.Network/loadBalancers@2022-01-01' = { +resource loadBalancer 'Microsoft.Network/loadBalancers@2023-04-01' = { name: loadBalancerName location: location sku: { diff --git a/modules/compute/virtual-machine/.test/windows/main.test.bicep b/modules/compute/virtual-machine/.test/windows/main.test.bicep index e39aa4f154..9e059f65ab 100644 --- a/modules/compute/virtual-machine/.test/windows/main.test.bicep +++ b/modules/compute/virtual-machine/.test/windows/main.test.bicep @@ -170,7 +170,6 @@ module testDeployment '../../main.bicep' = { diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diagnosticEventHubName: diagnosticDependencies.outputs.eventHubNamespaceEventHubName - diagnosticLogsRetentionInDays: 7 encryptionAtHost: false extensionAntiMalwareConfig: { enabled: true diff --git a/modules/compute/virtual-machine/README.md b/modules/compute/virtual-machine/README.md index 60d314cb5b..c5dcc52850 100644 --- a/modules/compute/virtual-machine/README.md +++ b/modules/compute/virtual-machine/README.md @@ -21,8 +21,8 @@ This module deploys a Virtual Machine with one or multiple NICs and optionally o | `Microsoft.Compute/virtualMachines` | [2022-11-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Compute/2022-11-01/virtualMachines) | | `Microsoft.Compute/virtualMachines/extensions` | [2022-11-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Compute/2022-11-01/virtualMachines/extensions) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/networkInterfaces` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/networkInterfaces) | -| `Microsoft.Network/publicIPAddresses` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/publicIPAddresses) | +| `Microsoft.Network/networkInterfaces` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/networkInterfaces) | +| `Microsoft.Network/publicIPAddresses` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/publicIPAddresses) | | `Microsoft.RecoveryServices/vaults/backupFabrics/protectionContainers/protectedItems` | [2023-01-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.RecoveryServices/2023-01-01/vaults/backupFabrics/protectionContainers/protectedItems) | ## Parameters @@ -61,7 +61,6 @@ This module deploys a Virtual Machine with one or multiple NICs and optionally o | `dedicatedHostId` | string | `''` | | Specifies resource ID about the dedicated host that the virtual machine resides in. | | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | | `diagnosticWorkspaceId` | string | `''` | | Resource ID of the diagnostic log analytics workspace. | | `disablePasswordAuthentication` | bool | `False` | | Specifies whether password authentication should be disabled. | @@ -1137,7 +1136,6 @@ module virtualMachine './compute/virtual-machine/main.bicep' = { ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' disablePasswordAuthentication: true @@ -1374,9 +1372,6 @@ module virtualMachine './compute/virtual-machine/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, @@ -1939,7 +1934,6 @@ module virtualMachine './compute/virtual-machine/main.bicep' = { ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableAutomaticUpdates: true @@ -2195,9 +2189,6 @@ module virtualMachine './compute/virtual-machine/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/compute/virtual-machine/main.bicep b/modules/compute/virtual-machine/main.bicep index bc4327b6af..3cd09f6b51 100644 --- a/modules/compute/virtual-machine/main.bicep +++ b/modules/compute/virtual-machine/main.bicep @@ -223,11 +223,6 @@ param extensionCustomScriptProtectedSetting object = {} @description('Optional. Location for all resources.') param location string = resourceGroup().location -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -399,7 +394,6 @@ module vm_nic '.bicep/nested_networkInterface.bicep' = [for (nicConfiguration, i ipConfigurations: nicConfiguration.ipConfigurations lock: lock diagnosticStorageAccountId: diagnosticStorageAccountId - diagnosticLogsRetentionInDays: diagnosticLogsRetentionInDays diagnosticWorkspaceId: diagnosticWorkspaceId diagnosticEventHubAuthorizationRuleId: diagnosticEventHubAuthorizationRuleId diagnosticEventHubName: diagnosticEventHubName diff --git a/modules/compute/virtual-machine/main.json b/modules/compute/virtual-machine/main.json index d54ab582ce..7c0d0faab1 100644 --- a/modules/compute/virtual-machine/main.json +++ b/modules/compute/virtual-machine/main.json @@ -5,7 +5,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "10649954371905940405" + "templateHash": "6083372606537708604" }, "name": "Virtual Machines", "description": "This module deploys a Virtual Machine with one or multiple NICs and optionally one or multiple public IPs.", @@ -432,15 +432,6 @@ "description": "Optional. Location for all resources." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "minValue": 0, - "maxValue": 365, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -821,9 +812,6 @@ "diagnosticStorageAccountId": { "value": "[parameters('diagnosticStorageAccountId')]" }, - "diagnosticLogsRetentionInDays": { - "value": "[parameters('diagnosticLogsRetentionInDays')]" - }, "diagnosticWorkspaceId": { "value": "[parameters('diagnosticWorkspaceId')]" }, @@ -857,7 +845,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "7198152300976797281" + "templateHash": "18368167306058144977" } }, "parameters": { @@ -902,9 +890,6 @@ "diagnosticStorageAccountId": { "type": "string" }, - "diagnosticLogsRetentionInDays": { - "type": "int" - }, "diagnosticWorkspaceId": { "type": "string" }, @@ -976,9 +961,6 @@ "diagnosticLogCategoriesToEnable": { "value": "[parameters('pipdiagnosticLogCategoriesToEnable')]" }, - "diagnosticLogsRetentionInDays": { - "value": "[parameters('diagnosticLogsRetentionInDays')]" - }, "diagnosticMetricsToEnable": { "value": "[parameters('pipdiagnosticMetricsToEnable')]" }, @@ -1018,7 +1000,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "14474619344547636171" + "templateHash": "7444990895328873286" }, "name": "Public IP Addresses", "description": "This module deploys a Public IP Address.", @@ -1089,15 +1071,6 @@ "description": "Optional. IP address version." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "minValue": 0, - "maxValue": 365, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -1133,6 +1106,20 @@ "description": "Optional. The domain name label. The concatenation of the domain name label and the regionalized DNS zone make up the fully qualified domain name associated with the public IP address. If a domain name label is specified, an A DNS record is created for the public IP in the Microsoft Azure DNS system." } }, + "domainNameLabelScope": { + "type": "string", + "defaultValue": "", + "allowedValues": [ + "", + "NoReuse", + "ResourceGroupReuse", + "SubscriptionReuse", + "TenantReuse" + ], + "metadata": { + "description": "Optional. The domain name label scope. If a domain name label and a domain name label scope are specified, an A DNS record is created for the public IP in the Microsoft Azure DNS system with a hashed value includes in FQDN." + } + }, "fqdn": { "type": "string", "defaultValue": "", @@ -1230,11 +1217,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -1243,15 +1226,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" }, "resources": [ { @@ -1270,7 +1249,7 @@ }, { "type": "Microsoft.Network/publicIPAddresses", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -1280,7 +1259,7 @@ }, "zones": "[parameters('zones')]", "properties": { - "dnsSettings": "[if(not(empty(parameters('domainNameLabel'))), createObject('domainNameLabel', parameters('domainNameLabel'), 'fqdn', parameters('fqdn'), 'reverseFqdn', parameters('reverseFqdn')), null())]", + "dnsSettings": "[if(not(empty(parameters('domainNameLabel'))), createObject('domainNameLabel', parameters('domainNameLabel'), 'domainNameLabelScope', parameters('domainNameLabelScope'), 'fqdn', parameters('fqdn'), 'reverseFqdn', parameters('reverseFqdn')), null())]", "publicIPAddressVersion": "[parameters('publicIPAddressVersion')]", "publicIPAllocationMethod": "[parameters('publicIPAllocationMethod')]", "publicIPPrefix": "[if(not(empty(parameters('publicIPPrefixResourceId'))), createObject('id', parameters('publicIPPrefixResourceId')), null())]", @@ -1525,14 +1504,14 @@ "metadata": { "description": "The public IP address of the public IP address resource." }, - "value": "[if(contains(reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2022-07-01'), 'ipAddress'), reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2022-07-01').ipAddress, '')]" + "value": "[if(contains(reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2023-04-01'), 'ipAddress'), reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2023-04-01').ipAddress, '')]" }, "location": { "type": "string", "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -1572,9 +1551,6 @@ "diagnosticEventHubName": { "value": "[parameters('diagnosticEventHubName')]" }, - "diagnosticLogsRetentionInDays": { - "value": "[parameters('diagnosticLogsRetentionInDays')]" - }, "diagnosticStorageAccountId": { "value": "[parameters('diagnosticStorageAccountId')]" }, @@ -1610,7 +1586,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "2671718918533328624" + "templateHash": "4973390307671682303" }, "name": "Network Interface", "description": "This module deploys a Network Interface.", @@ -1684,6 +1660,20 @@ "description": "Optional. Auxiliary mode of Network Interface resource. Not all regions are enabled for Auxiliary Mode Nic." } }, + "auxiliarySku": { + "type": "string", + "defaultValue": "None", + "allowedValues": [ + "A1", + "A2", + "A4", + "A8", + "None" + ], + "metadata": { + "description": "Optional. Auxiliary sku of Network Interface resource. Not all regions are enabled for Auxiliary Mode Nic." + } + }, "disableTcpStateTracking": { "type": "bool", "defaultValue": false, @@ -1716,15 +1706,6 @@ "description": "Optional. Array of role assignment objects that contain the 'roleDefinitionIdOrName' and 'principalId' to define RBAC role assignments on this resource. In the roleDefinitionIdOrName attribute, you can provide either the display name of the role definition, or its fully qualified ID in the following format: '/providers/Microsoft.Authorization/roleDefinitions/c2f4ef07-c644-48eb-af81-4b1b4947fb11'." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "minValue": 0, - "maxValue": 365, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -1781,11 +1762,7 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ] @@ -1807,7 +1784,7 @@ }, { "type": "Microsoft.Network/networkInterfaces", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -1838,6 +1815,7 @@ } ], "auxiliaryMode": "[parameters('auxiliaryMode')]", + "auxiliarySku": "[parameters('auxiliarySku')]", "disableTcpStateTracking": "[parameters('disableTcpStateTracking')]", "dnsSettings": "[if(not(empty(parameters('dnsServers'))), createObject('dnsServers', parameters('dnsServers')), null())]", "enableAcceleratedNetworking": "[parameters('enableAcceleratedNetworking')]", @@ -2081,7 +2059,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/networkInterfaces', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/networkInterfaces', parameters('name')), '2023-04-01', 'full').location]" } } } diff --git a/modules/consumption/budget/main.json b/modules/consumption/budget/main.json index 9e9d62b0c3..ef53563e18 100644 --- a/modules/consumption/budget/main.json +++ b/modules/consumption/budget/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "426286761409182782" - } + "version": "0.20.4.51522", + "templateHash": "1449481505821750821" + }, + "name": "Consumption Budgets", + "description": "This module deploys a Consumption Budget for Subscriptions.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -18,13 +21,13 @@ "category": { "type": "string", "defaultValue": "Cost", - "metadata": { - "description": "Optional. The category of the budget, whether the budget tracks cost or usage." - }, "allowedValues": [ "Cost", "Usage" - ] + ], + "metadata": { + "description": "Optional. The category of the budget, whether the budget tracks cost or usage." + } }, "amount": { "type": "int", @@ -35,9 +38,6 @@ "resetPeriod": { "type": "string", "defaultValue": "Monthly", - "metadata": { - "description": "Optional. The time covered by a budget. Tracking of the amount will be reset based on the time grain. BillingMonth, BillingQuarter, and BillingAnnual are only supported by WD customers." - }, "allowedValues": [ "Monthly", "Quarterly", @@ -45,7 +45,10 @@ "BillingMonth", "BillingQuarter", "BillingAnnual" - ] + ], + "metadata": { + "description": "Optional. The time covered by a budget. Tracking of the amount will be reset based on the time grain. BillingMonth, BillingQuarter, and BillingAnnual are only supported by WD customers." + } }, "startDate": { "type": "string", @@ -70,10 +73,10 @@ 100, 110 ], + "maxLength": 5, "metadata": { "description": "Optional. Percent thresholds of budget for when to get a notification. Can be up to 5 thresholds, where each must be between 1 and 1000." - }, - "maxLength": 5 + } }, "contactEmails": { "type": "array", diff --git a/modules/container-instance/container-group/.test/private/dependencies.bicep b/modules/container-instance/container-group/.test/private/dependencies.bicep index 2d569ac75c..ed78f60367 100644 --- a/modules/container-instance/container-group/.test/private/dependencies.bicep +++ b/modules/container-instance/container-group/.test/private/dependencies.bicep @@ -12,7 +12,7 @@ resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018- location: location } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkName location: location properties: { diff --git a/modules/container-instance/container-group/main.json b/modules/container-instance/container-group/main.json index 9e7029fba6..0cbb0f3e8d 100644 --- a/modules/container-instance/container-group/main.json +++ b/modules/container-instance/container-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8465029144420392889" - } + "version": "0.20.4.51522", + "templateHash": "15520115364290638727" + }, + "name": "Container Instances Container Groups", + "description": "This module deploys a Container Instance Container Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -38,25 +41,25 @@ "restartPolicy": { "type": "string", "defaultValue": "Always", - "metadata": { - "description": "Optional. Restart policy for all containers within the container group. - Always: Always restart. OnFailure: Restart on failure. Never: Never restart. - Always, OnFailure, Never." - }, "allowedValues": [ "Always", "OnFailure", "Never" - ] + ], + "metadata": { + "description": "Optional. Restart policy for all containers within the container group. - Always: Always restart. OnFailure: Restart on failure. Never: Never restart. - Always, OnFailure, Never." + } }, "ipAddressType": { "type": "string", "defaultValue": "Public", - "metadata": { - "description": "Optional. Specifies if the IP is exposed to the public internet or private VNET. - Public or Private." - }, "allowedValues": [ "Public", "Private" - ] + ], + "metadata": { + "description": "Optional. Specifies if the IP is exposed to the public internet or private VNET. - Public or Private." + } }, "imageRegistryCredentials": { "type": "array", @@ -75,16 +78,16 @@ "autoGeneratedDomainNameLabelScope": { "type": "string", "defaultValue": "TenantReuse", - "metadata": { - "description": "Optional. Specify level of protection of the domain name label." - }, "allowedValues": [ "Noreuse", "ResourceGroupReuse", "SubscriptionReuse", "TenantReuse", "Unsecure" - ] + ], + "metadata": { + "description": "Optional. Specify level of protection of the domain name label." + } }, "dnsNameLabel": { "type": "string", @@ -131,14 +134,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "systemAssignedIdentity": { "type": "bool", diff --git a/modules/container-registry/registry/.test/common/dependencies.bicep b/modules/container-registry/registry/.test/common/dependencies.bicep index a1cf849490..a758909a14 100644 --- a/modules/container-registry/registry/.test/common/dependencies.bicep +++ b/modules/container-registry/registry/.test/common/dependencies.bicep @@ -9,45 +9,45 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink${environment().suffixes.acrLoginServer}' - location: 'global' + name: 'privatelink${environment().suffixes.acrLoginServer}' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/container-registry/registry/.test/common/main.test.bicep b/modules/container-registry/registry/.test/common/main.test.bicep index 8460898be1..a2086f2f12 100644 --- a/modules/container-registry/registry/.test/common/main.test.bicep +++ b/modules/container-registry/registry/.test/common/main.test.bicep @@ -66,7 +66,6 @@ module testDeployment '../../main.bicep' = { name: '${namePrefix}${serviceShort}001' acrAdminUserEnabled: false acrSku: 'Premium' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/container-registry/registry/.test/encr/dependencies.bicep b/modules/container-registry/registry/.test/encr/dependencies.bicep index 1ccddcada9..9922e752af 100644 --- a/modules/container-registry/registry/.test/encr/dependencies.bicep +++ b/modules/container-registry/registry/.test/encr/dependencies.bicep @@ -12,66 +12,66 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource keyVault 'Microsoft.KeyVault/vaults@2022-07-01' = { - name: keyVaultName - location: location - properties: { - sku: { - family: 'A' - name: 'standard' - } - tenantId: tenant().tenantId - enablePurgeProtection: true // Required by batch account - softDeleteRetentionInDays: 7 - enabledForTemplateDeployment: true - enabledForDiskEncryption: true - enabledForDeployment: true - enableRbacAuthorization: true - accessPolicies: [] + name: keyVaultName + location: location + properties: { + sku: { + family: 'A' + name: 'standard' } + tenantId: tenant().tenantId + enablePurgeProtection: true // Required by batch account + softDeleteRetentionInDays: 7 + enabledForTemplateDeployment: true + enabledForDiskEncryption: true + enabledForDeployment: true + enableRbacAuthorization: true + accessPolicies: [] + } - resource key 'keys@2022-07-01' = { - name: 'keyEncryptionKey' - properties: { - kty: 'RSA' - } + resource key 'keys@2022-07-01' = { + name: 'keyEncryptionKey' + properties: { + kty: 'RSA' } + } } resource keyPermissions 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid('msi-${keyVault::key.id}-${location}-${managedIdentity.id}-Key-Reader-RoleAssignment') - scope: keyVault::key - properties: { - principalId: managedIdentity.properties.principalId - // Key Vault Crypto User - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '12338af0-0e69-4776-bea7-57ae8d297424') - principalType: 'ServicePrincipal' - } + name: guid('msi-${keyVault::key.id}-${location}-${managedIdentity.id}-Key-Reader-RoleAssignment') + scope: keyVault::key + properties: { + principalId: managedIdentity.properties.principalId + // Key Vault Crypto User + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '12338af0-0e69-4776-bea7-57ae8d297424') + principalType: 'ServicePrincipal' + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/container-registry/registry/.test/pe/dependencies.bicep b/modules/container-registry/registry/.test/pe/dependencies.bicep index b40eceeecc..6d9f2aa57a 100644 --- a/modules/container-registry/registry/.test/pe/dependencies.bicep +++ b/modules/container-registry/registry/.test/pe/dependencies.bicep @@ -6,40 +6,40 @@ param virtualNetworkName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink${environment().suffixes.acrLoginServer}' - location: 'global' + name: 'privatelink${environment().suffixes.acrLoginServer}' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/container-registry/registry/README.md b/modules/container-registry/registry/README.md index dc3bf65c9a..563a2e27b0 100644 --- a/modules/container-registry/registry/README.md +++ b/modules/container-registry/registry/README.md @@ -20,8 +20,8 @@ This module deploys an Azure Container Registry (ACR). | `Microsoft.ContainerRegistry/registries/replications` | [2022-02-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.ContainerRegistry/2022-02-01-preview/registries/replications) | | `Microsoft.ContainerRegistry/registries/webhooks` | [2022-02-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.ContainerRegistry/2022-02-01-preview/registries/webhooks) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | ## Parameters @@ -52,7 +52,6 @@ This module deploys an Azure Container Registry (ACR). | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, ContainerRegistryLoginEvents, ContainerRegistryRepositoryEvents]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -393,7 +392,6 @@ module registry './container-registry/registry/main.bicep' = { azureADAuthenticationAsArmPolicyStatus: 'enabled' diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -489,9 +487,6 @@ module registry './container-registry/registry/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/container-registry/registry/main.bicep b/modules/container-registry/registry/main.bicep index 68f470fdf9..74989bd260 100644 --- a/modules/container-registry/registry/main.bicep +++ b/modules/container-registry/registry/main.bicep @@ -155,11 +155,6 @@ param diagnosticMetricsToEnable array = [ 'AllMetrics' ] -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -193,20 +188,12 @@ param cMKUserAssignedIdentityResourceId string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -214,10 +201,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var identityType = systemAssignedIdentity ? (!empty(userAssignedIdentities) ? 'SystemAssigned,UserAssigned' : 'SystemAssigned') : (!empty(userAssignedIdentities) ? 'UserAssigned' : 'None') diff --git a/modules/container-registry/registry/main.json b/modules/container-registry/registry/main.json index 5990ccd39d..53c6af6abb 100644 --- a/modules/container-registry/registry/main.json +++ b/modules/container-registry/registry/main.json @@ -4,15 +4,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7144443471376224807" - } + "version": "0.20.4.51522", + "templateHash": "6969483115486766809" + }, + "name": "Azure Container Registries (ACR)", + "description": "This module deploys an Azure Container Registry (ACR).", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { "type": "string", - "maxLength": 50, "minLength": 5, + "maxLength": 50, "metadata": { "description": "Required. Name of your Azure container registry." } @@ -53,46 +56,46 @@ "exportPolicyStatus": { "type": "string", "defaultValue": "disabled", - "metadata": { - "description": "Optional. The value that indicates whether the export policy is enabled or not." - }, "allowedValues": [ "disabled", "enabled" - ] + ], + "metadata": { + "description": "Optional. The value that indicates whether the export policy is enabled or not." + } }, "quarantinePolicyStatus": { "type": "string", "defaultValue": "disabled", - "metadata": { - "description": "Optional. The value that indicates whether the quarantine policy is enabled or not." - }, "allowedValues": [ "disabled", "enabled" - ] + ], + "metadata": { + "description": "Optional. The value that indicates whether the quarantine policy is enabled or not." + } }, "trustPolicyStatus": { "type": "string", "defaultValue": "disabled", - "metadata": { - "description": "Optional. The value that indicates whether the trust policy is enabled or not." - }, "allowedValues": [ "disabled", "enabled" - ] + ], + "metadata": { + "description": "Optional. The value that indicates whether the trust policy is enabled or not." + } }, "retentionPolicyStatus": { "type": "string", "defaultValue": "enabled", - "metadata": { - "description": "Optional. The value that indicates whether the retention policy is enabled or not." - }, "allowedValues": [ "disabled", "enabled" - ] + ], + "metadata": { + "description": "Optional. The value that indicates whether the retention policy is enabled or not." + } }, "retentionPolicyDays": { "type": "int", @@ -104,24 +107,24 @@ "azureADAuthenticationAsArmPolicyStatus": { "type": "string", "defaultValue": "enabled", - "metadata": { - "description": "Optional. The value that indicates whether the policy for using ARM audience token for a container registr is enabled or not. Default is enabled." - }, "allowedValues": [ "disabled", "enabled" - ] + ], + "metadata": { + "description": "Optional. The value that indicates whether the policy for using ARM audience token for a container registr is enabled or not. Default is enabled." + } }, "softDeletePolicyStatus": { "type": "string", "defaultValue": "disabled", - "metadata": { - "description": "Optional. Soft Delete policy status. Default is disabled." - }, "allowedValues": [ "disabled", "enabled" - ] + ], + "metadata": { + "description": "Optional. Soft Delete policy status. Default is disabled." + } }, "softDeletePolicyDays": { "type": "int", @@ -152,24 +155,24 @@ "networkRuleBypassOptions": { "type": "string", "defaultValue": "AzureServices", - "metadata": { - "description": "Optional. Whether to allow trusted Azure services to access a network restricted registry." - }, "allowedValues": [ "AzureServices", "None" - ] + ], + "metadata": { + "description": "Optional. Whether to allow trusted Azure services to access a network restricted registry." + } }, "networkRuleSetDefaultAction": { "type": "string", "defaultValue": "Deny", - "metadata": { - "description": "Optional. The default action of allow or deny when no other rules match." - }, "allowedValues": [ "Allow", "Deny" - ] + ], + "metadata": { + "description": "Optional. The default action of allow or deny when no other rules match." + } }, "networkRuleSetIpRules": { "type": "array", @@ -188,13 +191,13 @@ "zoneRedundancy": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Whether or not zone redundancy is enabled for this container registry." - }, "allowedValues": [ "Disabled", "Enabled" - ] + ], + "metadata": { + "description": "Optional. Whether or not zone redundancy is enabled for this container registry." + } }, "replications": { "type": "array", @@ -213,14 +216,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "systemAssignedIdentity": { "type": "bool", @@ -277,15 +280,6 @@ "description": "Optional. The name of metrics that will be streamed." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -364,11 +358,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -377,15 +367,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "identityType": "[if(parameters('systemAssignedIdentity'), if(not(empty(parameters('userAssignedIdentities'))), 'SystemAssigned,UserAssigned', 'SystemAssigned'), if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None'))]", "identity": "[if(not(equals(variables('identityType'), 'None')), createObject('type', variables('identityType'), 'userAssignedIdentities', if(not(empty(parameters('userAssignedIdentities'))), parameters('userAssignedIdentities'), null())), null())]", "enableReferencedModulesTelemetry": false @@ -512,9 +498,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4732499637614328383" - } + "version": "0.20.4.51522", + "templateHash": "13921692097298323788" + }, + "name": "Azure Container Registry (ACR) Replications", + "description": "This module deploys an Azure Container Registry (ACR) Replication.", + "owner": "Azure/module-maintainers" }, "parameters": { "registryName": { @@ -553,13 +542,13 @@ "zoneRedundancy": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Whether or not zone redundancy is enabled for this container registry." - }, "allowedValues": [ "Disabled", "Enabled" - ] + ], + "metadata": { + "description": "Optional. Whether or not zone redundancy is enabled for this container registry." + } }, "enableDefaultTelemetry": { "type": "bool", @@ -668,9 +657,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2786725630837251417" - } + "version": "0.20.4.51522", + "templateHash": "939950579337463642" + }, + "name": "Azure Container Registry (ACR) Webhooks", + "description": "This module deploys an Azure Container Registry (ACR) Webhook.", + "owner": "Azure/module-maintainers" }, "parameters": { "registryName": { @@ -682,8 +674,8 @@ "name": { "type": "string", "defaultValue": "[format('{0}webhook', parameters('registryName'))]", - "maxLength": 50, "minLength": 5, + "maxLength": 50, "metadata": { "description": "Optional. The name of the registry webhook." } @@ -697,13 +689,13 @@ "status": { "type": "string", "defaultValue": "enabled", - "metadata": { - "description": "Optional. The status of the webhook at the time the operation was called." - }, "allowedValues": [ "disabled", "enabled" - ] + ], + "metadata": { + "description": "Optional. The status of the webhook at the time the operation was called." + } }, "action": { "type": "array", @@ -875,8 +867,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12128774062345830351" + "version": "0.20.4.51522", + "templateHash": "5342120260919416983" } }, "parameters": { @@ -1043,9 +1035,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1110,14 +1105,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -1175,7 +1170,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -1240,9 +1235,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -1253,8 +1251,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -1305,7 +1303,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -1375,8 +1373,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -1546,7 +1544,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } diff --git a/modules/container-registry/registry/replication/main.json b/modules/container-registry/registry/replication/main.json index a1712822aa..e6c678c98c 100644 --- a/modules/container-registry/registry/replication/main.json +++ b/modules/container-registry/registry/replication/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4732499637614328383" - } + "version": "0.20.4.51522", + "templateHash": "13921692097298323788" + }, + "name": "Azure Container Registry (ACR) Replications", + "description": "This module deploys an Azure Container Registry (ACR) Replication.", + "owner": "Azure/module-maintainers" }, "parameters": { "registryName": { @@ -45,13 +48,13 @@ "zoneRedundancy": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Whether or not zone redundancy is enabled for this container registry." - }, "allowedValues": [ "Disabled", "Enabled" - ] + ], + "metadata": { + "description": "Optional. Whether or not zone redundancy is enabled for this container registry." + } }, "enableDefaultTelemetry": { "type": "bool", diff --git a/modules/container-registry/registry/webhook/main.json b/modules/container-registry/registry/webhook/main.json index e69dac9056..2d53ae4942 100644 --- a/modules/container-registry/registry/webhook/main.json +++ b/modules/container-registry/registry/webhook/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2786725630837251417" - } + "version": "0.20.4.51522", + "templateHash": "939950579337463642" + }, + "name": "Azure Container Registry (ACR) Webhooks", + "description": "This module deploys an Azure Container Registry (ACR) Webhook.", + "owner": "Azure/module-maintainers" }, "parameters": { "registryName": { @@ -18,8 +21,8 @@ "name": { "type": "string", "defaultValue": "[format('{0}webhook', parameters('registryName'))]", - "maxLength": 50, "minLength": 5, + "maxLength": 50, "metadata": { "description": "Optional. The name of the registry webhook." } @@ -33,13 +36,13 @@ "status": { "type": "string", "defaultValue": "enabled", - "metadata": { - "description": "Optional. The status of the webhook at the time the operation was called." - }, "allowedValues": [ "disabled", "enabled" - ] + ], + "metadata": { + "description": "Optional. The status of the webhook at the time the operation was called." + } }, "action": { "type": "array", diff --git a/modules/container-service/managed-cluster/.test/azure/dependencies.bicep b/modules/container-service/managed-cluster/.test/azure/dependencies.bicep index 6f5cdb5111..8afe485d28 100644 --- a/modules/container-service/managed-cluster/.test/azure/dependencies.bicep +++ b/modules/container-service/managed-cluster/.test/azure/dependencies.bicep @@ -19,111 +19,111 @@ param proximityPlacementGroupName string @description('Required. The name of the DNS Zone to create.') param dnsZoneName string -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-09-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - '10.1.0.0/22' - ] - } - subnets: [ - { - name: 'systemSubnet' - properties: { - addressPrefix: '10.1.0.0/24' - } - } - { - name: 'userSubnet1' - properties: { - addressPrefix: '10.1.1.0/24' - } - } - { - name: 'userSubnet2' - properties: { - addressPrefix: '10.1.2.0/24' - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + '10.1.0.0/22' + ] } + subnets: [ + { + name: 'systemSubnet' + properties: { + addressPrefix: '10.1.0.0/24' + } + } + { + name: 'userSubnet1' + properties: { + addressPrefix: '10.1.1.0/24' + } + } + { + name: 'userSubnet2' + properties: { + addressPrefix: '10.1.2.0/24' + } + } + ] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource keyVault 'Microsoft.KeyVault/vaults@2022-11-01' = { - name: keyVaultName - location: location - properties: { - sku: { - family: 'A' - name: 'standard' - } - tenantId: tenant().tenantId - enablePurgeProtection: true // Required by nodepool vmss - softDeleteRetentionInDays: 7 - enabledForTemplateDeployment: true - enabledForDiskEncryption: true - enabledForDeployment: true - enableRbacAuthorization: true - accessPolicies: [] + name: keyVaultName + location: location + properties: { + sku: { + family: 'A' + name: 'standard' } - - resource key 'keys@2022-07-01' = { - name: 'encryptionKey' - properties: { - kty: 'RSA' - } + tenantId: tenant().tenantId + enablePurgeProtection: true // Required by nodepool vmss + softDeleteRetentionInDays: 7 + enabledForTemplateDeployment: true + enabledForDiskEncryption: true + enabledForDeployment: true + enableRbacAuthorization: true + accessPolicies: [] + } + + resource key 'keys@2022-07-01' = { + name: 'encryptionKey' + properties: { + kty: 'RSA' } + } } resource diskEncryptionSet 'Microsoft.Compute/diskEncryptionSets@2022-07-02' = { - name: diskEncryptionSetName - location: location - identity: { - type: 'SystemAssigned' - } - properties: { - activeKey: { - sourceVault: { - id: keyVault.id - } - keyUrl: keyVault::key.properties.keyUriWithVersion - } - encryptionType: 'EncryptionAtRestWithCustomerKey' + name: diskEncryptionSetName + location: location + identity: { + type: 'SystemAssigned' + } + properties: { + activeKey: { + sourceVault: { + id: keyVault.id + } + keyUrl: keyVault::key.properties.keyUriWithVersion } + encryptionType: 'EncryptionAtRestWithCustomerKey' + } } resource keyPermissions 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid('msi-${keyVault.id}-${location}-${managedIdentity.id}-KeyVault-Key-Read-RoleAssignment') - scope: keyVault - properties: { - principalId: diskEncryptionSet.identity.principalId - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'e147488a-f6f5-4113-8e2d-b22465e65bf6') // Key Vault Crypto Service Encryption User - principalType: 'ServicePrincipal' - } + name: guid('msi-${keyVault.id}-${location}-${managedIdentity.id}-KeyVault-Key-Read-RoleAssignment') + scope: keyVault + properties: { + principalId: diskEncryptionSet.identity.principalId + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'e147488a-f6f5-4113-8e2d-b22465e65bf6') // Key Vault Crypto Service Encryption User + principalType: 'ServicePrincipal' + } } resource proximityPlacementGroup 'Microsoft.Compute/proximityPlacementGroups@2022-03-01' = { - name: proximityPlacementGroupName - location: location + name: proximityPlacementGroupName + location: location } @description('The resource ID of the created Virtual Network Subnet.') output subnetResourceIds array = [ - virtualNetwork.properties.subnets[0].id - virtualNetwork.properties.subnets[1].id - virtualNetwork.properties.subnets[2].id + virtualNetwork.properties.subnets[0].id + virtualNetwork.properties.subnets[1].id + virtualNetwork.properties.subnets[2].id ] resource dnsZone 'Microsoft.Network/dnsZones@2018-05-01' = { - name: dnsZoneName - location: 'global' + name: dnsZoneName + location: 'global' } @description('The principal ID of the created Managed Identity.') diff --git a/modules/container-service/managed-cluster/.test/azure/main.test.bicep b/modules/container-service/managed-cluster/.test/azure/main.test.bicep index 53e453d441..ae463a55e5 100644 --- a/modules/container-service/managed-cluster/.test/azure/main.test.bicep +++ b/modules/container-service/managed-cluster/.test/azure/main.test.bicep @@ -147,7 +147,6 @@ module testDeployment '../../main.bicep' = { } ] aksClusterNetworkPlugin: 'azure' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/container-service/managed-cluster/.test/kubenet/main.test.bicep b/modules/container-service/managed-cluster/.test/kubenet/main.test.bicep index 617ca20c95..5faf01208e 100644 --- a/modules/container-service/managed-cluster/.test/kubenet/main.test.bicep +++ b/modules/container-service/managed-cluster/.test/kubenet/main.test.bicep @@ -135,7 +135,6 @@ module testDeployment '../../main.bicep' = { } ] aksClusterNetworkPlugin: 'kubenet' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/container-service/managed-cluster/.test/priv/dependencies.bicep b/modules/container-service/managed-cluster/.test/priv/dependencies.bicep index 45db73ed47..6e584a61cf 100644 --- a/modules/container-service/managed-cluster/.test/priv/dependencies.bicep +++ b/modules/container-service/managed-cluster/.test/priv/dependencies.bicep @@ -13,65 +13,65 @@ param virtualNetworkName string var addressPrefix = '10.0.0.0/16' resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2023-01-31' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource privateDnsZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: privateDnsZoneName - location: 'global' + name: privateDnsZoneName + location: 'global' } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZoneVNetLink 'Microsoft.Network/privateDnsZones/virtualNetworkLinks@2020-06-01' = { - name: 'pDnsLink-${virtualNetworkName}-${privateDnsZoneName}' - location: 'global' - parent: privateDnsZone - properties: { - registrationEnabled: true - virtualNetwork: { - id: virtualNetwork.id - } + name: 'pDnsLink-${virtualNetworkName}-${privateDnsZoneName}' + location: 'global' + parent: privateDnsZone + properties: { + registrationEnabled: true + virtualNetwork: { + id: virtualNetwork.id } + } } resource msiVnetRoleAssignment 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid(resourceGroup().id, 'NetworkContributor', managedIdentity.id) - scope: virtualNetwork - properties: { - principalId: managedIdentity.properties.principalId - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '4d97b98b-1d4f-4787-a291-c67834d212e7') // Network Contributor - principalType: 'ServicePrincipal' - } + name: guid(resourceGroup().id, 'NetworkContributor', managedIdentity.id) + scope: virtualNetwork + properties: { + principalId: managedIdentity.properties.principalId + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '4d97b98b-1d4f-4787-a291-c67834d212e7') // Network Contributor + principalType: 'ServicePrincipal' + } } resource msiPrivDnsZoneRoleAssignment 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid(resourceGroup().id, 'PrivateDNSZoneContributor', managedIdentity.id) - scope: privateDnsZone - properties: { - principalId: managedIdentity.properties.principalId - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'b12aa53e-6015-4669-85d0-8515ebb3ae7f') // Private DNS Zone Contributor - principalType: 'ServicePrincipal' - } + name: guid(resourceGroup().id, 'PrivateDNSZoneContributor', managedIdentity.id) + scope: privateDnsZone + properties: { + principalId: managedIdentity.properties.principalId + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'b12aa53e-6015-4669-85d0-8515ebb3ae7f') // Private DNS Zone Contributor + principalType: 'ServicePrincipal' + } } @description('The principal ID of the created Managed Identity.') diff --git a/modules/container-service/managed-cluster/.test/priv/main.test.bicep b/modules/container-service/managed-cluster/.test/priv/main.test.bicep index 13fb056ec4..c5ace56db5 100644 --- a/modules/container-service/managed-cluster/.test/priv/main.test.bicep +++ b/modules/container-service/managed-cluster/.test/priv/main.test.bicep @@ -142,7 +142,6 @@ module testDeployment '../../main.bicep' = { aksClusterSkuTier: 'Standard' aksClusterDnsServiceIP: '10.10.200.10' aksClusterServiceCidr: '10.10.200.0/24' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/container-service/managed-cluster/README.md b/modules/container-service/managed-cluster/README.md index a601b0f019..88b9e2c128 100644 --- a/modules/container-service/managed-cluster/README.md +++ b/modules/container-service/managed-cluster/README.md @@ -86,7 +86,6 @@ This module deploys an Azure Kubernetes Service (AKS) Managed Cluster. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, cluster-autoscaler, guard, kube-apiserver, kube-audit, kube-audit-admin, kube-controller-manager, kube-scheduler]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -476,7 +475,6 @@ module managedCluster './container-service/managed-cluster/main.bicep' = { aksClusterNetworkPlugin: 'azure' diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' diskEncryptionSetID: '' @@ -661,9 +659,6 @@ module managedCluster './container-service/managed-cluster/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, @@ -853,7 +848,6 @@ module managedCluster './container-service/managed-cluster/main.bicep' = { aksClusterNetworkPlugin: 'kubenet' diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -977,9 +971,6 @@ module managedCluster './container-service/managed-cluster/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, @@ -1176,7 +1167,6 @@ module managedCluster './container-service/managed-cluster/main.bicep' = { aksClusterSkuTier: 'Standard' diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -1304,9 +1294,6 @@ module managedCluster './container-service/managed-cluster/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/container-service/managed-cluster/agent-pool/main.json b/modules/container-service/managed-cluster/agent-pool/main.json index bc61a79771..51409f9928 100644 --- a/modules/container-service/managed-cluster/agent-pool/main.json +++ b/modules/container-service/managed-cluster/agent-pool/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14718876477350380320" - } + "version": "0.20.4.51522", + "templateHash": "9201392896338098875" + }, + "name": "Azure Kubernetes Service (AKS) Managed Cluster Agent Pools", + "description": "This module deploys an Azure Kubernetes Service (AKS) Managed Cluster Agent Pool.", + "owner": "Azure/module-maintainers" }, "parameters": { "managedClusterName": { @@ -31,8 +34,8 @@ "count": { "type": "int", "defaultValue": 1, - "maxValue": 1000, "minValue": 0, + "maxValue": 1000, "metadata": { "description": "Optional. Desired Number of agents (VMs) specified to host docker containers. Allowed values must be in the range of 0 to 1000 (inclusive) for user pools and in the range of 1 to 1000 (inclusive) for system pools. The default value is 1." } diff --git a/modules/container-service/managed-cluster/main.bicep b/modules/container-service/managed-cluster/main.bicep index 7a0abfa63f..a07026f84b 100644 --- a/modules/container-service/managed-cluster/main.bicep +++ b/modules/container-service/managed-cluster/main.bicep @@ -284,11 +284,6 @@ param diagnosticEventHubAuthorizationRuleId string = '' @description('Optional. Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category.') param diagnosticEventHubName string = '' -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Enable telemetry via a Globally Unique Identifier (GUID).') param enableDefaultTelemetry bool = true @@ -346,20 +341,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -367,10 +354,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var identityType = systemAssignedIdentity ? 'SystemAssigned' : (!empty(userAssignedIdentities) ? 'UserAssigned' : 'None') diff --git a/modules/container-service/managed-cluster/main.json b/modules/container-service/managed-cluster/main.json index 661bc502cb..505ad190f3 100644 --- a/modules/container-service/managed-cluster/main.json +++ b/modules/container-service/managed-cluster/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8485307659564095159" - } + "version": "0.20.4.51522", + "templateHash": "2499528815561589714" + }, + "name": "Azure Kubernetes Service (AKS) Managed Clusters", + "description": "This module deploys an Azure Kubernetes Service (AKS) Managed Cluster.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -362,13 +365,13 @@ "enableSecretRotation": { "type": "string", "defaultValue": "false", - "metadata": { - "description": "Optional. Specifies whether the KeyvaultSecretsProvider add-on uses secret rotation." - }, "allowedValues": [ "false", "true" - ] + ], + "metadata": { + "description": "Optional. Specifies whether the KeyvaultSecretsProvider add-on uses secret rotation." + } }, "autoScalerProfileScanInterval": { "type": "string", @@ -429,26 +432,26 @@ "autoScalerProfileBalanceSimilarNodeGroups": { "type": "string", "defaultValue": "false", - "metadata": { - "description": "Optional. Specifies the balance of similar node groups for the auto-scaler of the AKS cluster." - }, "allowedValues": [ "false", "true" - ] + ], + "metadata": { + "description": "Optional. Specifies the balance of similar node groups for the auto-scaler of the AKS cluster." + } }, "autoScalerProfileExpander": { "type": "string", "defaultValue": "random", - "metadata": { - "description": "Optional. Specifies the expand strategy for the auto-scaler of the AKS cluster." - }, "allowedValues": [ "least-waste", "most-pods", "priority", "random" - ] + ], + "metadata": { + "description": "Optional. Specifies the expand strategy for the auto-scaler of the AKS cluster." + } }, "autoScalerProfileMaxEmptyBulkDelete": { "type": "string", @@ -488,24 +491,24 @@ "autoScalerProfileSkipNodesWithLocalStorage": { "type": "string", "defaultValue": "true", - "metadata": { - "description": "Optional. Specifies if nodes with local storage should be skipped for the auto-scaler of the AKS cluster." - }, "allowedValues": [ "false", "true" - ] + ], + "metadata": { + "description": "Optional. Specifies if nodes with local storage should be skipped for the auto-scaler of the AKS cluster." + } }, "autoScalerProfileSkipNodesWithSystemPods": { "type": "string", "defaultValue": "true", - "metadata": { - "description": "Optional. Specifies if nodes with system pods should be skipped for the auto-scaler of the AKS cluster." - }, "allowedValues": [ "false", "true" - ] + ], + "metadata": { + "description": "Optional. Specifies if nodes with system pods should be skipped for the auto-scaler of the AKS cluster." + } }, "podIdentityProfileAllowNetworkPluginKubenet": { "type": "bool", @@ -598,15 +601,6 @@ "description": "Optional. Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "enableDefaultTelemetry": { "type": "bool", "defaultValue": true, @@ -624,14 +618,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "tags": { "type": "object", @@ -708,11 +702,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -721,15 +711,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "identityType": "[if(parameters('systemAssignedIdentity'), 'SystemAssigned', if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None'))]", "identity": { "type": "[variables('identityType')]", @@ -993,9 +979,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14718876477350380320" - } + "version": "0.20.4.51522", + "templateHash": "9201392896338098875" + }, + "name": "Azure Kubernetes Service (AKS) Managed Cluster Agent Pools", + "description": "This module deploys an Azure Kubernetes Service (AKS) Managed Cluster Agent Pool.", + "owner": "Azure/module-maintainers" }, "parameters": { "managedClusterName": { @@ -1020,8 +1009,8 @@ "count": { "type": "int", "defaultValue": 1, - "maxValue": 1000, "minValue": 0, + "maxValue": 1000, "metadata": { "description": "Optional. Desired Number of agents (VMs) specified to host docker containers. Allowed values must be in the range of 0 to 1000 (inclusive) for user pools and in the range of 1 to 1000 (inclusive) for system pools. The default value is 1." } @@ -1430,9 +1419,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9994137923318557139" - } + "version": "0.20.4.51522", + "templateHash": "14118650678014878152" + }, + "name": "Kubernetes Configuration Extensions", + "description": "This module deploys a Kubernetes Configuration Extension.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1590,9 +1582,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1433522452027494189" - } + "version": "0.20.4.51522", + "templateHash": "16353701795521321177" + }, + "name": "Kubernetes Configuration Flux Configurations", + "description": "This module deploys a Kubernetes Configuration Flux Configuration.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1657,23 +1652,23 @@ }, "scope": { "type": "string", - "metadata": { - "description": "Required. Scope at which the configuration will be installed." - }, "allowedValues": [ "cluster", "namespace" - ] + ], + "metadata": { + "description": "Required. Scope at which the configuration will be installed." + } }, "sourceKind": { "type": "string", - "metadata": { - "description": "Required. Source Kind to pull the configuration data from." - }, "allowedValues": [ "Bucket", "GitRepository" - ] + ], + "metadata": { + "description": "Required. Source Kind to pull the configuration data from." + } }, "suspend": { "type": "bool", @@ -1808,8 +1803,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16480761360924535352" + "version": "0.20.4.51522", + "templateHash": "4009331148405617632" } }, "parameters": { diff --git a/modules/data-factory/factory/.test/common/dependencies.bicep b/modules/data-factory/factory/.test/common/dependencies.bicep index 0a65641473..e83e155ace 100644 --- a/modules/data-factory/factory/.test/common/dependencies.bicep +++ b/modules/data-factory/factory/.test/common/dependencies.bicep @@ -15,93 +15,93 @@ param storageAccountName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.datafactory.azure.net' - location: 'global' + name: 'privatelink.datafactory.azure.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetworkName}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetworkName}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource keyVault 'Microsoft.KeyVault/vaults@2022-07-01' = { - name: keyVaultName - location: location - properties: { - sku: { - family: 'A' - name: 'standard' - } - tenantId: tenant().tenantId - enablePurgeProtection: null - enabledForTemplateDeployment: true - enabledForDiskEncryption: true - enabledForDeployment: true - enableRbacAuthorization: true - accessPolicies: [] + name: keyVaultName + location: location + properties: { + sku: { + family: 'A' + name: 'standard' } - - resource key 'keys@2022-07-01' = { - name: 'encryptionKey' - properties: { - kty: 'RSA' - } + tenantId: tenant().tenantId + enablePurgeProtection: null + enabledForTemplateDeployment: true + enabledForDiskEncryption: true + enabledForDeployment: true + enableRbacAuthorization: true + accessPolicies: [] + } + + resource key 'keys@2022-07-01' = { + name: 'encryptionKey' + properties: { + kty: 'RSA' } + } } resource keyPermissions 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid('msi-${keyVault::key.id}-${location}-${managedIdentity.id}-KeyVault-Key-Read-RoleAssignment') - scope: keyVault::key - properties: { - principalId: managedIdentity.properties.principalId - // Key Vault Crypto User - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '12338af0-0e69-4776-bea7-57ae8d297424') - principalType: 'ServicePrincipal' - } + name: guid('msi-${keyVault::key.id}-${location}-${managedIdentity.id}-KeyVault-Key-Read-RoleAssignment') + scope: keyVault::key + properties: { + principalId: managedIdentity.properties.principalId + // Key Vault Crypto User + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '12338af0-0e69-4776-bea7-57ae8d297424') + principalType: 'ServicePrincipal' + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource storageAccount 'Microsoft.Storage/storageAccounts@2021-08-01' = { - name: storageAccountName - location: location - kind: 'StorageV2' - sku: { - name: 'Standard_LRS' - } - properties: { - allowBlobPublicAccess: false - } + name: storageAccountName + location: location + kind: 'StorageV2' + sku: { + name: 'Standard_LRS' + } + properties: { + allowBlobPublicAccess: false + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/data-factory/factory/.test/common/main.test.bicep b/modules/data-factory/factory/.test/common/main.test.bicep index 5b1ea3f79e..522aa02ad1 100644 --- a/modules/data-factory/factory/.test/common/main.test.bicep +++ b/modules/data-factory/factory/.test/common/main.test.bicep @@ -69,7 +69,6 @@ module testDeployment '../../main.bicep' = { cMKKeyName: nestedDependencies.outputs.keyVaultEncryptionKeyName cMKKeyVaultResourceId: nestedDependencies.outputs.keyVaultResourceId cMKUserAssignedIdentityResourceId: nestedDependencies.outputs.managedIdentityResourceId - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/data-factory/factory/README.md b/modules/data-factory/factory/README.md index 01a81857c9..fedd12666c 100644 --- a/modules/data-factory/factory/README.md +++ b/modules/data-factory/factory/README.md @@ -21,8 +21,8 @@ This module deploys a Data Factory. | `Microsoft.DataFactory/factories/managedVirtualNetworks` | [2018-06-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.DataFactory/2018-06-01/factories/managedVirtualNetworks) | | `Microsoft.DataFactory/factories/managedVirtualNetworks/managedPrivateEndpoints` | [2018-06-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.DataFactory/2018-06-01/factories/managedVirtualNetworks/managedPrivateEndpoints) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | ## Parameters @@ -48,7 +48,6 @@ This module deploys a Data Factory. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', ActivityRuns, allLogs, PipelineRuns, SSISIntegrationRuntimeLogs, SSISPackageEventMessageContext, SSISPackageEventMessages, SSISPackageExecutableStatistics, SSISPackageExecutionComponentPhases, SSISPackageExecutionDataStatistics, TriggerRuns]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -403,7 +402,6 @@ module factory './data-factory/factory/main.bicep' = { cMKUserAssignedIdentityResourceId: '' diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -509,9 +507,6 @@ module factory './data-factory/factory/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/data-factory/factory/integration-runtime/main.json b/modules/data-factory/factory/integration-runtime/main.json index 8b3636511a..bb811c619f 100644 --- a/modules/data-factory/factory/integration-runtime/main.json +++ b/modules/data-factory/factory/integration-runtime/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4260654403827080373" - } + "version": "0.20.4.51522", + "templateHash": "3532154338917341406" + }, + "name": "Data Factory Integration RunTimes", + "description": "This module deploys a Data Factory Managed or Self-Hosted Integration Runtime.", + "owner": "Azure/module-maintainers" }, "parameters": { "dataFactoryName": { @@ -23,13 +26,13 @@ }, "type": { "type": "string", - "metadata": { - "description": "Required. The type of Integration Runtime." - }, "allowedValues": [ "Managed", "SelfHosted" - ] + ], + "metadata": { + "description": "Required. The type of Integration Runtime." + } }, "managedVirtualNetworkName": { "type": "string", diff --git a/modules/data-factory/factory/main.bicep b/modules/data-factory/factory/main.bicep index f4a7ae7072..ad5acd0751 100644 --- a/modules/data-factory/factory/main.bicep +++ b/modules/data-factory/factory/main.bicep @@ -55,11 +55,6 @@ param gitHostName string = '' @description('Optional. List of Global Parameters for the factory.') param globalParameters object = {} -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -133,20 +128,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -154,10 +141,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] @description('Optional. Array of role assignment objects that contain the \'roleDefinitionIdOrName\' and \'principalId\' to define RBAC role assignments on this resource. In the roleDefinitionIdOrName attribute, you can provide either the display name of the role definition, or its fully qualified ID in the following format: \'/providers/Microsoft.Authorization/roleDefinitions/c2f4ef07-c644-48eb-af81-4b1b4947fb11\'.') diff --git a/modules/data-factory/factory/main.json b/modules/data-factory/factory/main.json index e089a69881..f6dcaebbfa 100644 --- a/modules/data-factory/factory/main.json +++ b/modules/data-factory/factory/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17442896935715609244" - } + "version": "0.20.4.51522", + "templateHash": "10840135215067371071" + }, + "name": "Data Factories", + "description": "This module deploys a Data Factory.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -125,15 +128,6 @@ "description": "Optional. List of Global Parameters for the factory." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -165,14 +159,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "systemAssignedIdentity": { "type": "bool", @@ -293,11 +287,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -306,15 +296,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "identityType": "[if(parameters('systemAssignedIdentity'), if(not(empty(parameters('userAssignedIdentities'))), 'SystemAssigned,UserAssigned', 'SystemAssigned'), if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None'))]", "identity": "[if(not(equals(variables('identityType'), 'None')), createObject('type', variables('identityType'), 'userAssignedIdentities', if(not(empty(parameters('userAssignedIdentities'))), parameters('userAssignedIdentities'), null())), null())]", "enableReferencedModulesTelemetry": false @@ -410,9 +396,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1965875674709533586" - } + "version": "0.20.4.51522", + "templateHash": "12310194736024387290" + }, + "name": "Data Factory Managed Virtual Networks", + "description": "This module deploys a Data Factory Managed Virtual Network.", + "owner": "Azure/module-maintainers" }, "parameters": { "dataFactoryName": { @@ -508,9 +497,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15894355068813582548" - } + "version": "0.20.4.51522", + "templateHash": "17089196483393073819" + }, + "name": "Data Factory Managed Virtual Network Managed PrivateEndpoints", + "description": "This module deploys a Data Factory Managed Virtual Network Managed Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "dataFactoryName": { @@ -674,9 +666,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4260654403827080373" - } + "version": "0.20.4.51522", + "templateHash": "3532154338917341406" + }, + "name": "Data Factory Integration RunTimes", + "description": "This module deploys a Data Factory Managed or Self-Hosted Integration Runtime.", + "owner": "Azure/module-maintainers" }, "parameters": { "dataFactoryName": { @@ -693,13 +688,13 @@ }, "type": { "type": "string", - "metadata": { - "description": "Required. The type of Integration Runtime." - }, "allowedValues": [ "Managed", "SelfHosted" - ] + ], + "metadata": { + "description": "Required. The type of Integration Runtime." + } }, "managedVirtualNetworkName": { "type": "string", @@ -815,8 +810,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3903369935711152836" + "version": "0.20.4.51522", + "templateHash": "3166374464215651196" } }, "parameters": { @@ -978,9 +973,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1045,14 +1043,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -1110,7 +1108,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -1175,9 +1173,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -1188,8 +1189,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -1240,7 +1241,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -1310,8 +1311,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -1481,7 +1482,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } diff --git a/modules/data-factory/factory/managed-virtual-network/main.json b/modules/data-factory/factory/managed-virtual-network/main.json index 4c92b4ce02..2885cf59b4 100644 --- a/modules/data-factory/factory/managed-virtual-network/main.json +++ b/modules/data-factory/factory/managed-virtual-network/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1965875674709533586" - } + "version": "0.20.4.51522", + "templateHash": "12310194736024387290" + }, + "name": "Data Factory Managed Virtual Networks", + "description": "This module deploys a Data Factory Managed Virtual Network.", + "owner": "Azure/module-maintainers" }, "parameters": { "dataFactoryName": { @@ -102,9 +105,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15894355068813582548" - } + "version": "0.20.4.51522", + "templateHash": "17089196483393073819" + }, + "name": "Data Factory Managed Virtual Network Managed PrivateEndpoints", + "description": "This module deploys a Data Factory Managed Virtual Network Managed Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "dataFactoryName": { diff --git a/modules/data-factory/factory/managed-virtual-network/managed-private-endpoint/main.json b/modules/data-factory/factory/managed-virtual-network/managed-private-endpoint/main.json index 1992baa5aa..aa4a6643bf 100644 --- a/modules/data-factory/factory/managed-virtual-network/managed-private-endpoint/main.json +++ b/modules/data-factory/factory/managed-virtual-network/managed-private-endpoint/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15894355068813582548" - } + "version": "0.20.4.51522", + "templateHash": "17089196483393073819" + }, + "name": "Data Factory Managed Virtual Network Managed PrivateEndpoints", + "description": "This module deploys a Data Factory Managed Virtual Network Managed Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "dataFactoryName": { diff --git a/modules/data-protection/backup-vault/backup-policy/main.json b/modules/data-protection/backup-vault/backup-policy/main.json index 94f66a26e9..1cb063c808 100644 --- a/modules/data-protection/backup-vault/backup-policy/main.json +++ b/modules/data-protection/backup-vault/backup-policy/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15950464845862056522" - } + "version": "0.20.4.51522", + "templateHash": "3184455103711973064" + }, + "name": "Data Protection Backup Vault Backup Policies", + "description": "This module deploys a Data Protection Backup Vault Backup Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "backupVaultName": { diff --git a/modules/data-protection/backup-vault/main.json b/modules/data-protection/backup-vault/main.json index 5b8ffdb3f9..3685bc8291 100644 --- a/modules/data-protection/backup-vault/main.json +++ b/modules/data-protection/backup-vault/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1811109282711100098" - } + "version": "0.20.4.51522", + "templateHash": "16372850809886319091" + }, + "name": "Data Protection Backup Vaults", + "description": "This module deploys a Data Protection Backup Vault.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -39,14 +42,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "systemAssignedIdentity": { "type": "bool", @@ -89,13 +92,13 @@ "azureMonitorAlertSettingsAlertsForAllJobFailures": { "type": "string", "defaultValue": "Enabled", - "metadata": { - "description": "Optional. Settings for Azure Monitor based alerts for job failures." - }, "allowedValues": [ "Disabled", "Enabled" - ] + ], + "metadata": { + "description": "Optional. Settings for Azure Monitor based alerts for job failures." + } }, "backupPolicies": { "type": "array", @@ -193,9 +196,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15950464845862056522" - } + "version": "0.20.4.51522", + "templateHash": "3184455103711973064" + }, + "name": "Data Protection Backup Vault Backup Policies", + "description": "This module deploys a Data Protection Backup Vault Backup Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "backupVaultName": { @@ -311,8 +317,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7094311822465776729" + "version": "0.20.4.51522", + "templateHash": "10253116074794957898" } }, "parameters": { diff --git a/modules/databricks/workspace/.test/common/main.test.bicep b/modules/databricks/workspace/.test/common/main.test.bicep index cad178b102..ff502e457c 100644 --- a/modules/databricks/workspace/.test/common/main.test.bicep +++ b/modules/databricks/workspace/.test/common/main.test.bicep @@ -67,7 +67,6 @@ module testDeployment '../../main.bicep' = { diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diagnosticEventHubName: diagnosticDependencies.outputs.eventHubNamespaceEventHubName - diagnosticLogsRetentionInDays: 7 lock: 'CanNotDelete' roleAssignments: [ { diff --git a/modules/databricks/workspace/README.md b/modules/databricks/workspace/README.md index d8e0d0bd23..bb9d78a717 100644 --- a/modules/databricks/workspace/README.md +++ b/modules/databricks/workspace/README.md @@ -34,7 +34,6 @@ This module deploys an Azure Databricks Workspace. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', accounts, allLogs, clusters, dbfs, instancePools, jobs, notebook, secrets, sqlPermissions, ssh, workspace]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | | `diagnosticWorkspaceId` | string | `''` | | Resource ID of the diagnostic log analytics workspace. | @@ -248,7 +247,6 @@ module workspace './databricks/workspace/main.bicep' = { // Non-required parameters diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -293,9 +291,6 @@ module workspace './databricks/workspace/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/databricks/workspace/main.bicep b/modules/databricks/workspace/main.bicep index 5c306dbc5e..585ff24171 100644 --- a/modules/databricks/workspace/main.bicep +++ b/modules/databricks/workspace/main.bicep @@ -25,11 +25,6 @@ param roleAssignments array = [] @description('Optional. The workspace\'s custom parameters.') param parameters object = {} -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -81,20 +76,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified diff --git a/modules/databricks/workspace/main.json b/modules/databricks/workspace/main.json index 72214add59..2c5e42b8c7 100644 --- a/modules/databricks/workspace/main.json +++ b/modules/databricks/workspace/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15914648850876491078" - } + "version": "0.20.4.51522", + "templateHash": "17661847744091981452" + }, + "name": "Azure Databricks Workspaces", + "description": "This module deploys an Azure Databricks Workspace.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -55,15 +58,6 @@ "description": "Optional. The workspace's custom parameters." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -95,14 +89,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "tags": { "type": "object", @@ -156,15 +150,11 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "managedResourceGroupName": "[format('{0}-rg', parameters('name'))]", "managedResourceGroupIdVar": "[format('{0}/resourceGroups/{1}', subscription().id, variables('managedResourceGroupName'))]" }, @@ -262,8 +252,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13613915507747675582" + "version": "0.20.4.51522", + "templateHash": "11920634368378558628" } }, "parameters": { diff --git a/modules/db-for-my-sql/flexible-server/.test/private/dependencies.bicep b/modules/db-for-my-sql/flexible-server/.test/private/dependencies.bicep index 0cede161b9..28572498b4 100644 --- a/modules/db-for-my-sql/flexible-server/.test/private/dependencies.bicep +++ b/modules/db-for-my-sql/flexible-server/.test/private/dependencies.bicep @@ -9,53 +9,53 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-11-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] + } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + delegations: [ { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - delegations: [ - { - name: 'Microsoft.DBforMySQL.flexibleServers' - properties: { - serviceName: 'Microsoft.DBforMySQL/flexibleServers' - } - } - ] - } + name: 'Microsoft.DBforMySQL.flexibleServers' + properties: { + serviceName: 'Microsoft.DBforMySQL/flexibleServers' + } } - ] - } + ] + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'private.mysql.database.azure.com' - location: 'global' + name: 'private.mysql.database.azure.com' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2023-01-31' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/db-for-my-sql/flexible-server/.test/private/main.test.bicep b/modules/db-for-my-sql/flexible-server/.test/private/main.test.bicep index 7610bb027e..b231316e74 100644 --- a/modules/db-for-my-sql/flexible-server/.test/private/main.test.bicep +++ b/modules/db-for-my-sql/flexible-server/.test/private/main.test.bicep @@ -108,6 +108,5 @@ module testDeployment '../../main.bicep' = { diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diagnosticEventHubName: diagnosticDependencies.outputs.eventHubNamespaceEventHubName - diagnosticLogsRetentionInDays: 7 } } diff --git a/modules/db-for-my-sql/flexible-server/.test/public/main.test.bicep b/modules/db-for-my-sql/flexible-server/.test/public/main.test.bicep index 80e9fb5864..8c2c60ec0d 100644 --- a/modules/db-for-my-sql/flexible-server/.test/public/main.test.bicep +++ b/modules/db-for-my-sql/flexible-server/.test/public/main.test.bicep @@ -156,6 +156,5 @@ module testDeployment '../../main.bicep' = { diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diagnosticEventHubName: diagnosticDependencies.outputs.eventHubNamespaceEventHubName - diagnosticLogsRetentionInDays: 7 } } diff --git a/modules/db-for-my-sql/flexible-server/README.md b/modules/db-for-my-sql/flexible-server/README.md index b9be319b7a..f75e0ea4e7 100644 --- a/modules/db-for-my-sql/flexible-server/README.md +++ b/modules/db-for-my-sql/flexible-server/README.md @@ -61,7 +61,6 @@ This module deploys a DBforMySQL Flexible Server. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, MySqlAuditLogs, MySqlSlowLogs]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -324,7 +323,6 @@ module flexibleServer './db-for-my-sql/flexible-server/main.bicep' = { delegatedSubnetResourceId: '' diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -404,9 +402,6 @@ module flexibleServer './db-for-my-sql/flexible-server/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, @@ -503,7 +498,6 @@ module flexibleServer './db-for-my-sql/flexible-server/main.bicep' = { ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -619,9 +613,6 @@ module flexibleServer './db-for-my-sql/flexible-server/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/db-for-my-sql/flexible-server/main.bicep b/modules/db-for-my-sql/flexible-server/main.bicep index 17e2f6914d..1b2e3623cb 100644 --- a/modules/db-for-my-sql/flexible-server/main.bicep +++ b/modules/db-for-my-sql/flexible-server/main.bicep @@ -176,11 +176,6 @@ param firewallRules array = [] @description('Optional. Array of role assignment objects that contain the "roleDefinitionIdOrName" and "principalId" to define RBAC role assignments on this resource. In the roleDefinitionIdOrName attribute, you can provide either the display name of the role definition, or its fully qualified ID in the following format: "/providers/Microsoft.Authorization/roleDefinitions/c2f4ef07-c644-48eb-af81-4b1b4947fb11".') param roleAssignments array = [] -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -218,20 +213,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -239,10 +226,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] @description('Optional. Enable telemetry via a Globally Unique Identifier (GUID).') diff --git a/modules/db-for-my-sql/flexible-server/main.json b/modules/db-for-my-sql/flexible-server/main.json index 29bf3f0dc4..ecfa7bf36e 100644 --- a/modules/db-for-my-sql/flexible-server/main.json +++ b/modules/db-for-my-sql/flexible-server/main.json @@ -5,7 +5,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "10319315630521368786" + "templateHash": "8843810505050220871" }, "name": "DBforMySQL Flexible Servers", "description": "This module deploys a DBforMySQL Flexible Server.", @@ -324,15 +324,6 @@ "description": "Optional. Array of role assignment objects that contain the \"roleDefinitionIdOrName\" and \"principalId\" to define RBAC role assignments on this resource. In the roleDefinitionIdOrName attribute, you can provide either the display name of the role definition, or its fully qualified ID in the following format: \"/providers/Microsoft.Authorization/roleDefinitions/c2f4ef07-c644-48eb-af81-4b1b4947fb11\"." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "minValue": 0, - "maxValue": 365, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -410,11 +401,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -423,15 +410,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "identityType": "[if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None')]", "identity": "[if(not(equals(variables('identityType'), 'None')), createObject('type', variables('identityType'), 'userAssignedIdentities', if(not(empty(parameters('userAssignedIdentities'))), parameters('userAssignedIdentities'), null())), null())]", "enableReferencedModulesTelemetry": false diff --git a/modules/db-for-postgre-sql/flexible-server/.test/private/dependencies.bicep b/modules/db-for-postgre-sql/flexible-server/.test/private/dependencies.bicep index 59a6c539b6..8e1cbe19fd 100644 --- a/modules/db-for-postgre-sql/flexible-server/.test/private/dependencies.bicep +++ b/modules/db-for-postgre-sql/flexible-server/.test/private/dependencies.bicep @@ -9,53 +9,53 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] + } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + delegations: [ { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - delegations: [ - { - name: 'Microsoft.DBforPostgreSQL.flexibleServers' - properties: { - serviceName: 'Microsoft.DBforPostgreSQL/flexibleServers' - } - } - ] - } + name: 'Microsoft.DBforPostgreSQL.flexibleServers' + properties: { + serviceName: 'Microsoft.DBforPostgreSQL/flexibleServers' + } } - ] - } + ] + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: '${split(virtualNetworkName, '-')[1]}.postgres.database.azure.com' - location: 'global' + name: '${split(virtualNetworkName, '-')[1]}.postgres.database.azure.com' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/db-for-postgre-sql/flexible-server/.test/private/main.test.bicep b/modules/db-for-postgre-sql/flexible-server/.test/private/main.test.bicep index d4655ce3d2..1cf97fb1dd 100644 --- a/modules/db-for-postgre-sql/flexible-server/.test/private/main.test.bicep +++ b/modules/db-for-postgre-sql/flexible-server/.test/private/main.test.bicep @@ -99,7 +99,6 @@ module testDeployment '../../main.bicep' = { diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diagnosticEventHubName: diagnosticDependencies.outputs.eventHubNamespaceEventHubName - diagnosticLogsRetentionInDays: 7 geoRedundantBackup: 'Enabled' privateDnsZoneArmResourceId: nestedDependencies.outputs.privateDNSResourceId tags: { diff --git a/modules/db-for-postgre-sql/flexible-server/.test/public/main.test.bicep b/modules/db-for-postgre-sql/flexible-server/.test/public/main.test.bicep index 021cae61be..6738b412df 100644 --- a/modules/db-for-postgre-sql/flexible-server/.test/public/main.test.bicep +++ b/modules/db-for-postgre-sql/flexible-server/.test/public/main.test.bicep @@ -99,7 +99,6 @@ module testDeployment '../../main.bicep' = { diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diagnosticEventHubName: diagnosticDependencies.outputs.eventHubNamespaceEventHubName - diagnosticLogsRetentionInDays: 7 firewallRules: [ { endIpAddress: '0.0.0.0' diff --git a/modules/db-for-postgre-sql/flexible-server/README.md b/modules/db-for-postgre-sql/flexible-server/README.md index d6a9a3a6db..75d89467cf 100644 --- a/modules/db-for-postgre-sql/flexible-server/README.md +++ b/modules/db-for-postgre-sql/flexible-server/README.md @@ -59,7 +59,6 @@ This module deploys a DBforPostgreSQL Flexible Server. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, PostgreSQLFlexDatabaseXacts, PostgreSQLFlexQueryStoreRuntime, PostgreSQLFlexQueryStoreWaitStats, PostgreSQLFlexSessions, PostgreSQLFlexTableStats, PostgreSQLLogs]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -477,7 +476,6 @@ module flexibleServer './db-for-postgre-sql/flexible-server/main.bicep' = { delegatedSubnetResourceId: '' diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -555,9 +553,6 @@ module flexibleServer './db-for-postgre-sql/flexible-server/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, @@ -627,7 +622,6 @@ module flexibleServer './db-for-postgre-sql/flexible-server/main.bicep' = { ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -735,9 +729,6 @@ module flexibleServer './db-for-postgre-sql/flexible-server/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/db-for-postgre-sql/flexible-server/main.bicep b/modules/db-for-postgre-sql/flexible-server/main.bicep index 48ff43f1c2..ce8495ec2a 100644 --- a/modules/db-for-postgre-sql/flexible-server/main.bicep +++ b/modules/db-for-postgre-sql/flexible-server/main.bicep @@ -144,11 +144,6 @@ param tags object = {} @description('Optional. Enable telemetry via a Globally Unique Identifier (GUID).') param enableDefaultTelemetry bool = true -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -190,20 +185,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -211,10 +198,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var enableReferencedModulesTelemetry = false diff --git a/modules/db-for-postgre-sql/flexible-server/main.json b/modules/db-for-postgre-sql/flexible-server/main.json index 5cf324dc40..64868b74c1 100644 --- a/modules/db-for-postgre-sql/flexible-server/main.json +++ b/modules/db-for-postgre-sql/flexible-server/main.json @@ -5,7 +5,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "12231440430796984538" + "templateHash": "1801764410852262795" }, "name": "DBforPostgreSQL Flexible Servers", "description": "This module deploys a DBforPostgreSQL Flexible Server.", @@ -268,15 +268,6 @@ "description": "Optional. Enable telemetry via a Globally Unique Identifier (GUID)." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "minValue": 0, - "maxValue": 365, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -351,11 +342,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -364,15 +351,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "enableReferencedModulesTelemetry": false }, "resources": [ diff --git a/modules/desktop-virtualization/application-group/.test/common/main.test.bicep b/modules/desktop-virtualization/application-group/.test/common/main.test.bicep index 442aa41fdd..d49d0c91f9 100644 --- a/modules/desktop-virtualization/application-group/.test/common/main.test.bicep +++ b/modules/desktop-virtualization/application-group/.test/common/main.test.bicep @@ -85,7 +85,6 @@ module testDeployment '../../main.bicep' = { } ] description: 'This is my first Remote Applications bundle' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/desktop-virtualization/application-group/README.md b/modules/desktop-virtualization/application-group/README.md index 36c167f77a..0ea6d2af56 100644 --- a/modules/desktop-virtualization/application-group/README.md +++ b/modules/desktop-virtualization/application-group/README.md @@ -39,7 +39,6 @@ This module deploys an Azure Virtual Desktop (AVD) Application Group. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, Checkpoint, Error, Management]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | | `diagnosticWorkspaceId` | string | `''` | | Resource ID of log analytics. | @@ -207,7 +206,6 @@ module applicationGroup './desktop-virtualization/application-group/main.bicep' description: 'This is my first Remote Applications bundle' diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -283,9 +281,6 @@ module applicationGroup './desktop-virtualization/application-group/main.bicep' "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/desktop-virtualization/application-group/application/main.json b/modules/desktop-virtualization/application-group/application/main.json index 7d33859d90..2621a89ffe 100644 --- a/modules/desktop-virtualization/application-group/application/main.json +++ b/modules/desktop-virtualization/application-group/application/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11389546711531681509" - } + "version": "0.20.4.51522", + "templateHash": "7619639220591936340" + }, + "name": "Azure Virtual Desktop (AVD) Application Group Applications", + "description": "This module deploys an Azure Virtual Desktop (AVD) Application Group Application.", + "owner": "Azure/module-maintainers" }, "parameters": { "appGroupName": { @@ -43,14 +46,14 @@ "commandLineSetting": { "type": "string", "defaultValue": "DoNotAllow", - "metadata": { - "description": "Optional. Specifies whether this published application can be launched with command-line arguments provided by the client, command-line arguments specified at publish time, or no command-line arguments at all." - }, "allowedValues": [ "Allow", "DoNotAllow", "Require" - ] + ], + "metadata": { + "description": "Optional. Specifies whether this published application can be launched with command-line arguments provided by the client, command-line arguments specified at publish time, or no command-line arguments at all." + } }, "commandLineArguments": { "type": "string", diff --git a/modules/desktop-virtualization/application-group/main.bicep b/modules/desktop-virtualization/application-group/main.bicep index 4039305515..1323b46739 100644 --- a/modules/desktop-virtualization/application-group/main.bicep +++ b/modules/desktop-virtualization/application-group/main.bicep @@ -28,11 +28,6 @@ param description string = '' @sys.description('Optional. Array of role assignment objects that contain the \'roleDefinitionIdOrName\' and \'principalIds\' to define RBAC role assignments on this resource. In the roleDefinitionIdOrName attribute, you can provide either the display name of the role definition, or its fully qualified ID in the following format: \'/providers/Microsoft.Authorization/roleDefinitions/c2f4ef07-c644-48eb-af81-4b1b4947fb11\'.') param roleAssignments array = [] -@sys.description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @sys.description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -80,20 +75,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified diff --git a/modules/desktop-virtualization/application-group/main.json b/modules/desktop-virtualization/application-group/main.json index e2712a7f72..273ac199e1 100644 --- a/modules/desktop-virtualization/application-group/main.json +++ b/modules/desktop-virtualization/application-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3969197583590852781" - } + "version": "0.20.4.51522", + "templateHash": "14308484478858567050" + }, + "name": "Azure Virtual Desktop (AVD) Application Groups", + "description": "This module deploys an Azure Virtual Desktop (AVD) Application Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -60,15 +63,6 @@ "description": "Optional. Array of role assignment objects that contain the 'roleDefinitionIdOrName' and 'principalIds' to define RBAC role assignments on this resource. In the roleDefinitionIdOrName attribute, you can provide either the display name of the role definition, or its fully qualified ID in the following format: '/providers/Microsoft.Authorization/roleDefinitions/c2f4ef07-c644-48eb-af81-4b1b4947fb11'." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -100,14 +94,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "tags": { "type": "object", @@ -161,15 +155,11 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "enableReferencedModulesTelemetry": false }, "resources": [ @@ -271,9 +261,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11389546711531681509" - } + "version": "0.20.4.51522", + "templateHash": "7619639220591936340" + }, + "name": "Azure Virtual Desktop (AVD) Application Group Applications", + "description": "This module deploys an Azure Virtual Desktop (AVD) Application Group Application.", + "owner": "Azure/module-maintainers" }, "parameters": { "appGroupName": { @@ -310,14 +303,14 @@ "commandLineSetting": { "type": "string", "defaultValue": "DoNotAllow", - "metadata": { - "description": "Optional. Specifies whether this published application can be launched with command-line arguments provided by the client, command-line arguments specified at publish time, or no command-line arguments at all." - }, "allowedValues": [ "Allow", "DoNotAllow", "Require" - ] + ], + "metadata": { + "description": "Optional. Specifies whether this published application can be launched with command-line arguments provided by the client, command-line arguments specified at publish time, or no command-line arguments at all." + } }, "commandLineArguments": { "type": "string", @@ -449,8 +442,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15101328978713466551" + "version": "0.20.4.51522", + "templateHash": "1136039423442605560" } }, "parameters": { diff --git a/modules/desktop-virtualization/host-pool/.test/common/main.test.bicep b/modules/desktop-virtualization/host-pool/.test/common/main.test.bicep index 49e0912547..6fb06b4407 100644 --- a/modules/desktop-virtualization/host-pool/.test/common/main.test.bicep +++ b/modules/desktop-virtualization/host-pool/.test/common/main.test.bicep @@ -64,7 +64,6 @@ module testDeployment '../../main.bicep' = { enableDefaultTelemetry: enableDefaultTelemetry name: '${namePrefix}${serviceShort}001' customRdpProperty: 'audiocapturemode:i:1;audiomode:i:0;drivestoredirect:s:;redirectclipboard:i:1;redirectcomports:i:1;redirectprinters:i:1;redirectsmartcards:i:1;screen mode id:i:2;' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/desktop-virtualization/host-pool/README.md b/modules/desktop-virtualization/host-pool/README.md index cf9fecd33d..d12faf2c33 100644 --- a/modules/desktop-virtualization/host-pool/README.md +++ b/modules/desktop-virtualization/host-pool/README.md @@ -43,7 +43,6 @@ This module deploys an Azure Virtual Desktop (AVD) Host Pool. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', AgentHealthStatus, allLogs, Checkpoint, Connection, Error, HostRegistration, Management]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | | `diagnosticWorkspaceId` | string | `''` | | Resource ID of the diagnostic log analytics workspace. | @@ -312,7 +311,6 @@ module hostPool './desktop-virtualization/host-pool/main.bicep' = { description: 'My first AVD Host Pool' diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -403,9 +401,6 @@ module hostPool './desktop-virtualization/host-pool/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/desktop-virtualization/host-pool/main.bicep b/modules/desktop-virtualization/host-pool/main.bicep index 2d089de365..483e0faa44 100644 --- a/modules/desktop-virtualization/host-pool/main.bicep +++ b/modules/desktop-virtualization/host-pool/main.bicep @@ -56,11 +56,6 @@ param tokenValidityLength string = 'PT8H' @sys.description('Generated. Do not provide a value! This date value is used to generate a registration token.') param baseTime string = utcNow('u') -@sys.description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @sys.description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -147,7 +142,6 @@ param agentUpdate object = { useSessionHostLocalTime: agentUpdateUseSessionHostLocalTime } - @sys.description('Optional. The ring number of HostPool.') param ring int = -1 @@ -193,20 +187,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified diff --git a/modules/desktop-virtualization/host-pool/main.json b/modules/desktop-virtualization/host-pool/main.json index afe03f458b..fa73ba0804 100644 --- a/modules/desktop-virtualization/host-pool/main.json +++ b/modules/desktop-virtualization/host-pool/main.json @@ -4,8 +4,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.18.4.5664", - "templateHash": "8022860912421276738" + "version": "0.20.4.51522", + "templateHash": "11648715346210984085" }, "name": "Azure Virtual Desktop (AVD) Host Pools", "description": "This module deploys an Azure Virtual Desktop (AVD) Host Pool.", @@ -117,15 +117,6 @@ "description": "Generated. Do not provide a value! This date value is used to generate a registration token." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -157,14 +148,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "tags": { "type": "object", @@ -220,8 +211,8 @@ "agentUpdateMaintenanceWindowHour": { "type": "int", "defaultValue": 22, - "maxValue": 23, "minValue": 1, + "maxValue": 23, "metadata": { "description": "Optional. Update hour for scheduled agent updates." } @@ -356,15 +347,11 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "tokenExpirationTime": "[dateTimeAdd(parameters('baseTime'), parameters('tokenValidityLength'))]" }, "resources": [ @@ -478,8 +465,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.18.4.5664", - "templateHash": "14279396732857224845" + "version": "0.20.4.51522", + "templateHash": "18049817812681767445" } }, "parameters": { diff --git a/modules/desktop-virtualization/scaling-plan/.test/common/main.test.bicep b/modules/desktop-virtualization/scaling-plan/.test/common/main.test.bicep index d89579726b..e2704b6908 100644 --- a/modules/desktop-virtualization/scaling-plan/.test/common/main.test.bicep +++ b/modules/desktop-virtualization/scaling-plan/.test/common/main.test.bicep @@ -72,7 +72,6 @@ module testDeployment '../../main.bicep' = { principalType: 'ServicePrincipal' } ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/desktop-virtualization/scaling-plan/README.md b/modules/desktop-virtualization/scaling-plan/README.md index 28ec89ea82..b964c6f5bb 100644 --- a/modules/desktop-virtualization/scaling-plan/README.md +++ b/modules/desktop-virtualization/scaling-plan/README.md @@ -34,7 +34,6 @@ This module deploys an Azure Virtual Desktop (AVD) Scaling Plan. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, Autoscale]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | | `diagnosticWorkspaceId` | string | `''` | | Resource ID of the diagnostic log analytics workspace. | | `enableDefaultTelemetry` | bool | `True` | | Enable telemetry via a Globally Unique Identifier (GUID). | @@ -286,7 +285,6 @@ module scalingPlan './desktop-virtualization/scaling-plan/main.bicep' = { description: 'My Scaling Plan Description' diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -335,9 +333,6 @@ module scalingPlan './desktop-virtualization/scaling-plan/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/desktop-virtualization/scaling-plan/main.bicep b/modules/desktop-virtualization/scaling-plan/main.bicep index aca6eb13b3..dab1c3fff6 100644 --- a/modules/desktop-virtualization/scaling-plan/main.bicep +++ b/modules/desktop-virtualization/scaling-plan/main.bicep @@ -75,11 +75,6 @@ param hostPoolReferences array = [] @sys.description('Optional. Tags of the resource.') param tags object = {} -@sys.description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @sys.description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -111,20 +106,12 @@ param diagnosticLogCategoriesToEnable array = [ var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified diff --git a/modules/desktop-virtualization/scaling-plan/main.json b/modules/desktop-virtualization/scaling-plan/main.json index 365c521409..de51fe69a8 100644 --- a/modules/desktop-virtualization/scaling-plan/main.json +++ b/modules/desktop-virtualization/scaling-plan/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6860109665020209749" - } + "version": "0.20.4.51522", + "templateHash": "10391957957992354423" + }, + "name": "Azure Virtual Desktop (AVD) Scaling Plans", + "description": "This module deploys an Azure Virtual Desktop (AVD) Scaling Plan.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -47,12 +50,12 @@ "hostPoolType": { "type": "string", "defaultValue": "Pooled", - "metadata": { - "description": "Optional. The type of hostpool where this scaling plan should be applied." - }, "allowedValues": [ "Pooled" - ] + ], + "metadata": { + "description": "Optional. The type of hostpool where this scaling plan should be applied." + } }, "exclusionTag": { "type": "string", @@ -121,15 +124,6 @@ "description": "Optional. Tags of the resource." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -194,15 +188,11 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" }, "resources": [ { @@ -286,8 +276,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15871536856748411551" + "version": "0.20.4.51522", + "templateHash": "3278048928000577121" } }, "parameters": { diff --git a/modules/desktop-virtualization/workspace/.test/common/main.test.bicep b/modules/desktop-virtualization/workspace/.test/common/main.test.bicep index 8d0ec90d33..47db31d8fa 100644 --- a/modules/desktop-virtualization/workspace/.test/common/main.test.bicep +++ b/modules/desktop-virtualization/workspace/.test/common/main.test.bicep @@ -68,7 +68,6 @@ module testDeployment '../../main.bicep' = { appGroupResourceIds: [ nestedDependencies.outputs.applicationGroupResourceId ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/desktop-virtualization/workspace/README.md b/modules/desktop-virtualization/workspace/README.md index f1be8d6dec..dc530682df 100644 --- a/modules/desktop-virtualization/workspace/README.md +++ b/modules/desktop-virtualization/workspace/README.md @@ -36,7 +36,6 @@ This module deploys an Azure Virtual Desktop (AVD) Workspace. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, Checkpoint, Error, Feed, Management]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | | `diagnosticWorkspaceId` | string | `''` | | Resource ID of the diagnostic log analytics workspace. | @@ -187,7 +186,6 @@ module workspace './desktop-virtualization/workspace/main.bicep' = { description: 'This is my first AVD Workspace' diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -242,9 +240,6 @@ module workspace './desktop-virtualization/workspace/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/desktop-virtualization/workspace/main.bicep b/modules/desktop-virtualization/workspace/main.bicep index c3a018fa0e..6cf547dee5 100644 --- a/modules/desktop-virtualization/workspace/main.bicep +++ b/modules/desktop-virtualization/workspace/main.bicep @@ -17,11 +17,6 @@ param friendlyName string = '' @sys.description('Optional. The description of the Workspace to be created.') param description string = '' -@sys.description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @sys.description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -70,20 +65,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified diff --git a/modules/desktop-virtualization/workspace/main.json b/modules/desktop-virtualization/workspace/main.json index ad8bcfb2d3..04f72d5514 100644 --- a/modules/desktop-virtualization/workspace/main.json +++ b/modules/desktop-virtualization/workspace/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12702406365485231955" - } + "version": "0.20.4.51522", + "templateHash": "5583996217532008926" + }, + "name": "Azure Virtual Desktop (AVD) Workspaces", + "description": "This module deploys an Azure Virtual Desktop (AVD) Workspace.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -43,15 +46,6 @@ "description": "Optional. The description of the Workspace to be created." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -83,14 +77,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "tags": { "type": "object", @@ -145,15 +139,11 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" }, "resources": [ { @@ -247,8 +237,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18072016089387616568" + "version": "0.20.4.51522", + "templateHash": "9018764467732457380" } }, "parameters": { diff --git a/modules/dev-test-lab/lab/.test/common/dependencies.bicep b/modules/dev-test-lab/lab/.test/common/dependencies.bicep index ed9d63d47d..929699f11a 100644 --- a/modules/dev-test-lab/lab/.test/common/dependencies.bicep +++ b/modules/dev-test-lab/lab/.test/common/dependencies.bicep @@ -19,94 +19,94 @@ param virtualNetworkName string var addressPrefix = '10.0.0.0/16' resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource keyVault 'Microsoft.KeyVault/vaults@2022-07-01' = { - name: keyVaultName - location: location - properties: { - sku: { - family: 'A' - name: 'standard' - } - tenantId: tenant().tenantId - enablePurgeProtection: true // Required for encrption to work - softDeleteRetentionInDays: 7 - enabledForTemplateDeployment: true - enabledForDiskEncryption: true - enabledForDeployment: true - enableRbacAuthorization: true - accessPolicies: [] + name: keyVaultName + location: location + properties: { + sku: { + family: 'A' + name: 'standard' } - - resource key 'keys@2022-07-01' = { - name: 'encryptionKey' - properties: { - kty: 'RSA' - } + tenantId: tenant().tenantId + enablePurgeProtection: true // Required for encrption to work + softDeleteRetentionInDays: 7 + enabledForTemplateDeployment: true + enabledForDiskEncryption: true + enabledForDeployment: true + enableRbacAuthorization: true + accessPolicies: [] + } + + resource key 'keys@2022-07-01' = { + name: 'encryptionKey' + properties: { + kty: 'RSA' } + } } resource diskEncryptionSet 'Microsoft.Compute/diskEncryptionSets@2021-04-01' = { - name: diskEncryptionSetName - location: location - identity: { - type: 'SystemAssigned' - } - properties: { - activeKey: { - sourceVault: { - id: keyVault.id - } - keyUrl: keyVault::key.properties.keyUriWithVersion - } - encryptionType: 'EncryptionAtRestWithCustomerKey' + name: diskEncryptionSetName + location: location + identity: { + type: 'SystemAssigned' + } + properties: { + activeKey: { + sourceVault: { + id: keyVault.id + } + keyUrl: keyVault::key.properties.keyUriWithVersion } + encryptionType: 'EncryptionAtRestWithCustomerKey' + } } resource keyPermissions 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid('msi-${keyVault.id}-${location}-${diskEncryptionSet.id}-KeyVault-Key-Read-RoleAssignment') - scope: keyVault - properties: { - principalId: diskEncryptionSet.identity.principalId - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'e147488a-f6f5-4113-8e2d-b22465e65bf6') // Key Vault Crypto Service Encryption User - principalType: 'ServicePrincipal' - } + name: guid('msi-${keyVault.id}-${location}-${diskEncryptionSet.id}-KeyVault-Key-Read-RoleAssignment') + scope: keyVault + properties: { + principalId: diskEncryptionSet.identity.principalId + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'e147488a-f6f5-4113-8e2d-b22465e65bf6') // Key Vault Crypto Service Encryption User + principalType: 'ServicePrincipal' + } } resource storageAccount 'Microsoft.Storage/storageAccounts@2021-09-01' = { - name: storageAccountName - location: location - kind: 'StorageV2' - sku: { - name: 'Standard_LRS' - } - properties: { - allowBlobPublicAccess: false - publicNetworkAccess: 'Disabled' - } + name: storageAccountName + location: location + kind: 'StorageV2' + sku: { + name: 'Standard_LRS' + } + properties: { + allowBlobPublicAccess: false + publicNetworkAccess: 'Disabled' + } } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } @description('The name of the created Virtual Network.') diff --git a/modules/dev-test-lab/lab/artifactsource/main.json b/modules/dev-test-lab/lab/artifactsource/main.json index ae102ff2f1..9056139395 100644 --- a/modules/dev-test-lab/lab/artifactsource/main.json +++ b/modules/dev-test-lab/lab/artifactsource/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2705905798561744734" - } + "version": "0.20.4.51522", + "templateHash": "10765635521160351928" + }, + "name": "DevTest Lab Artifact Sources", + "description": "This module deploys a DevTest Lab Artifact Source.\r\n\r\nAn artifact source allows you to create custom artifacts for the VMs in the lab, or use Azure Resource Manager templates to create a custom test environment. You must add a private Git repository for the artifacts or Resource Manager templates that your team creates. The repository can be hosted on GitHub or on Azure DevOps Services.", + "owner": "Azure/module-maintainers" }, "parameters": { "labName": { @@ -66,26 +69,26 @@ "sourceType": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. The artifact source's type." - }, "allowedValues": [ "", "GitHub", "StorageAccount", "VsoGit" - ] + ], + "metadata": { + "description": "Optional. The artifact source's type." + } }, "status": { "type": "string", "defaultValue": "Enabled", - "metadata": { - "description": "Optional. Indicates if the artifact source is enabled (values: Enabled, Disabled). Default is \"Enabled\"." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Indicates if the artifact source is enabled (values: Enabled, Disabled). Default is \"Enabled\"." + } }, "uri": { "type": "string", diff --git a/modules/dev-test-lab/lab/cost/main.json b/modules/dev-test-lab/lab/cost/main.json index 5cd2d67273..5c385935d5 100644 --- a/modules/dev-test-lab/lab/cost/main.json +++ b/modules/dev-test-lab/lab/cost/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7115830072126257185" - } + "version": "0.20.4.51522", + "templateHash": "4166206931202072952" + }, + "name": "DevTest Lab Costs", + "description": "This module deploys a DevTest Lab Cost.\r\n\r\nManage lab costs by setting a spending target that can be viewed in the Monthly Estimated Cost Trend chart. DevTest Labs can send a notification when spending reaches the specified target threshold.", + "owner": "Azure/module-maintainers" }, "parameters": { "labName": { @@ -17,13 +20,13 @@ }, "cycleType": { "type": "string", - "metadata": { - "description": "Required. Reporting cycle type." - }, "allowedValues": [ "Custom", "CalendarMonth" - ] + ], + "metadata": { + "description": "Required. Reporting cycle type." + } }, "tags": { "type": "object", @@ -49,13 +52,13 @@ "status": { "type": "string", "defaultValue": "Enabled", - "metadata": { - "description": "Optional. Target cost status." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Target cost status." + } }, "target": { "type": "int", @@ -74,112 +77,112 @@ "thresholdValue25DisplayOnChart": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Target Cost threshold at 25% display on chart. Indicates whether this threshold will be displayed on cost charts." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Target Cost threshold at 25% display on chart. Indicates whether this threshold will be displayed on cost charts." + } }, "thresholdValue25SendNotificationWhenExceeded": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Target cost threshold at 25% send notification when exceeded. Indicates whether notifications will be sent when this threshold is exceeded." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Target cost threshold at 25% send notification when exceeded. Indicates whether notifications will be sent when this threshold is exceeded." + } }, "thresholdValue50DisplayOnChart": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Target Cost threshold at 50% display on chart. Indicates whether this threshold will be displayed on cost charts." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Target Cost threshold at 50% display on chart. Indicates whether this threshold will be displayed on cost charts." + } }, "thresholdValue50SendNotificationWhenExceeded": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Target cost threshold at 50% send notification when exceeded. Indicates whether notifications will be sent when this threshold is exceeded." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Target cost threshold at 50% send notification when exceeded. Indicates whether notifications will be sent when this threshold is exceeded." + } }, "thresholdValue75DisplayOnChart": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Target Cost threshold at 75% display on chart. Indicates whether this threshold will be displayed on cost charts." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Target Cost threshold at 75% display on chart. Indicates whether this threshold will be displayed on cost charts." + } }, "thresholdValue75SendNotificationWhenExceeded": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Target cost threshold at 75% send notification when exceeded. Indicates whether notifications will be sent when this threshold is exceeded." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Target cost threshold at 75% send notification when exceeded. Indicates whether notifications will be sent when this threshold is exceeded." + } }, "thresholdValue100DisplayOnChart": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Target Cost threshold at 100% display on chart. Indicates whether this threshold will be displayed on cost charts." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Target Cost threshold at 100% display on chart. Indicates whether this threshold will be displayed on cost charts." + } }, "thresholdValue100SendNotificationWhenExceeded": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Target cost threshold at 100% send notification when exceeded. Indicates whether notifications will be sent when this threshold is exceeded." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Target cost threshold at 100% send notification when exceeded. Indicates whether notifications will be sent when this threshold is exceeded." + } }, "thresholdValue125DisplayOnChart": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Target Cost threshold at 125% display on chart. Indicates whether this threshold will be displayed on cost charts." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Target Cost threshold at 125% display on chart. Indicates whether this threshold will be displayed on cost charts." + } }, "thresholdValue125SendNotificationWhenExceeded": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Target cost threshold at 125% send notification when exceeded. Indicates whether notifications will be sent when this threshold is exceeded." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Target cost threshold at 125% send notification when exceeded. Indicates whether notifications will be sent when this threshold is exceeded." + } }, "enableDefaultTelemetry": { "type": "bool", diff --git a/modules/dev-test-lab/lab/main.json b/modules/dev-test-lab/lab/main.json index a7c90cbc16..5160f5d5f1 100644 --- a/modules/dev-test-lab/lab/main.json +++ b/modules/dev-test-lab/lab/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15404563432190354" - } + "version": "0.20.4.51522", + "templateHash": "6928988461229718614" + }, + "name": "DevTest Labs", + "description": "This module deploys a DevTest Lab.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -25,14 +28,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -58,13 +61,13 @@ "environmentPermission": { "type": "string", "defaultValue": "Reader", - "metadata": { - "description": "Optional. The access rights to be granted to the user when provisioning an environment." - }, "allowedValues": [ "Contributor", "Reader" - ] + ], + "metadata": { + "description": "Optional. The access rights to be granted to the user when provisioning an environment." + } }, "extendedProperties": { "type": "object", @@ -76,14 +79,14 @@ "labStorageType": { "type": "string", "defaultValue": "Premium", - "metadata": { - "description": "Optional. Type of storage used by the lab. It can be either Premium or Standard." - }, "allowedValues": [ "Standard", "StandardSSD", "Premium" - ] + ], + "metadata": { + "description": "Optional. Type of storage used by the lab. It can be either Premium or Standard." + } }, "artifactsStorageAccount": { "type": "string", @@ -109,13 +112,13 @@ "premiumDataDisks": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. The setting to enable usage of premium data disks. When its value is \"Enabled\", creation of standard or premium data disks is allowed. When its value is \"Disabled\", only creation of standard data disks is allowed. Default is \"Disabled\"." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. The setting to enable usage of premium data disks. When its value is \"Enabled\", creation of standard or premium data disks is allowed. When its value is \"Disabled\", only creation of standard data disks is allowed. Default is \"Disabled\"." + } }, "support": { "type": "object", @@ -148,13 +151,13 @@ "browserConnect": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Enable browser connect on virtual machines if the lab's VNETs have configured Azure Bastion." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Enable browser connect on virtual machines if the lab's VNETs have configured Azure Bastion." + } }, "disableAutoUpgradeCseMinorVersion": { "type": "bool", @@ -166,24 +169,24 @@ "isolateLabResources": { "type": "string", "defaultValue": "Enabled", - "metadata": { - "description": "Optional. Enable lab resources isolation from the public internet." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Enable lab resources isolation from the public internet." + } }, "encryptionType": { "type": "string", "defaultValue": "EncryptionAtRestWithPlatformKey", - "metadata": { - "description": "Optional. Specify how OS and data disks created as part of the lab are encrypted." - }, "allowedValues": [ "EncryptionAtRestWithPlatformKey", "EncryptionAtRestWithCustomerKey" - ] + ], + "metadata": { + "description": "Optional. Specify how OS and data disks created as part of the lab are encrypted." + } }, "encryptionDiskEncryptionSetId": { "type": "string", @@ -344,9 +347,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10889431821569458862" - } + "version": "0.20.4.51522", + "templateHash": "3541849489263903716" + }, + "name": "DevTest Lab Virtual Networks", + "description": "This module deploys a DevTest Lab Virtual Network.\r\n\r\nLab virtual machines must be deployed into a virtual network. This resource type allows configuring the virtual network and subnet settings used for the lab virtual machines.", + "owner": "Azure/module-maintainers" }, "parameters": { "labName": { @@ -505,9 +511,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1906322712473031665" - } + "version": "0.20.4.51522", + "templateHash": "9961899772573814013" + }, + "name": "DevTest Lab Policy Sets Policies", + "description": "This module deploys a DevTest Lab Policy Sets Policy.\r\n\r\nDevTest lab policies are used to modify the lab settings such as only allowing certain VM Size SKUs, marketplace image types, number of VMs allowed per user and other settings.", + "owner": "Azure/module-maintainers" }, "parameters": { "labName": { @@ -545,13 +554,13 @@ }, "evaluatorType": { "type": "string", - "metadata": { - "description": "Required. The evaluator type of the policy (i.e. AllowedValuesPolicy, MaxValuePolicy)." - }, "allowedValues": [ "AllowedValuesPolicy", "MaxValuePolicy" - ] + ], + "metadata": { + "description": "Required. The evaluator type of the policy (i.e. AllowedValuesPolicy, MaxValuePolicy)." + } }, "factData": { "type": "string", @@ -562,9 +571,6 @@ }, "factName": { "type": "string", - "metadata": { - "description": "Required. The fact name of the policy." - }, "allowedValues": [ "EnvironmentTemplate", "GalleryImage", @@ -576,18 +582,21 @@ "UserOwnedLabPremiumVmCount", "UserOwnedLabVmCount", "UserOwnedLabVmCountInSubnet" - ] + ], + "metadata": { + "description": "Required. The fact name of the policy." + } }, "status": { "type": "string", "defaultValue": "Enabled", - "metadata": { - "description": "Optional. The status of the policy." - }, "allowedValues": [ "Disabled", "Enabled" - ] + ], + "metadata": { + "description": "Optional. The status of the policy." + } }, "threshold": { "type": "string", @@ -706,9 +715,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18085550684061495455" - } + "version": "0.20.4.51522", + "templateHash": "12427678703978539260" + }, + "name": "DevTest Lab Schedules", + "description": "This module deploys a DevTest Lab Schedule.\r\n\r\nLab schedules are used to modify the settings for auto-shutdown, auto-start for lab virtual machines.", + "owner": "Azure/module-maintainers" }, "parameters": { "labName": { @@ -719,23 +731,23 @@ }, "name": { "type": "string", - "metadata": { - "description": "Required. The name of the schedule." - }, "allowedValues": [ "LabVmsShutdown", "LabVmAutoStart" - ] + ], + "metadata": { + "description": "Required. The name of the schedule." + } }, "taskType": { "type": "string", - "metadata": { - "description": "Required. The task type of the schedule (e.g. LabVmsShutdownTask, LabVmsStartupTask)." - }, "allowedValues": [ "LabVmsShutdownTask", "LabVmsStartupTask" - ] + ], + "metadata": { + "description": "Required. The task type of the schedule (e.g. LabVmsShutdownTask, LabVmsStartupTask)." + } }, "tags": { "type": "object", @@ -768,13 +780,13 @@ "status": { "type": "string", "defaultValue": "Enabled", - "metadata": { - "description": "Optional. The status of the schedule (i.e. Enabled, Disabled)." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. The status of the schedule (i.e. Enabled, Disabled)." + } }, "targetResourceId": { "type": "string", @@ -793,13 +805,13 @@ "notificationSettingsStatus": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. If notifications are enabled for this schedule (i.e. Enabled, Disabled)." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. If notifications are enabled for this schedule (i.e. Enabled, Disabled)." + } }, "notificationSettingsTimeInMinutes": { "type": "int", @@ -917,9 +929,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16463919279899526398" - } + "version": "0.20.4.51522", + "templateHash": "16877948453352231958" + }, + "name": "DevTest Lab Notification Channels", + "description": "This module deploys a DevTest Lab Notification Channel.\r\n\r\nNotification channels are used by the schedule resource type in order to send notifications or events to email addresses and/or webhooks.", + "owner": "Azure/module-maintainers" }, "parameters": { "labName": { @@ -930,13 +945,13 @@ }, "name": { "type": "string", - "metadata": { - "description": "Required. The name of the notification channel." - }, "allowedValues": [ "autoShutdown", "costThreshold" - ] + ], + "metadata": { + "description": "Required. The name of the notification channel." + } }, "tags": { "type": "object", @@ -1088,9 +1103,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2705905798561744734" - } + "version": "0.20.4.51522", + "templateHash": "10765635521160351928" + }, + "name": "DevTest Lab Artifact Sources", + "description": "This module deploys a DevTest Lab Artifact Source.\r\n\r\nAn artifact source allows you to create custom artifacts for the VMs in the lab, or use Azure Resource Manager templates to create a custom test environment. You must add a private Git repository for the artifacts or Resource Manager templates that your team creates. The repository can be hosted on GitHub or on Azure DevOps Services.", + "owner": "Azure/module-maintainers" }, "parameters": { "labName": { @@ -1150,26 +1168,26 @@ "sourceType": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. The artifact source's type." - }, "allowedValues": [ "", "GitHub", "StorageAccount", "VsoGit" - ] + ], + "metadata": { + "description": "Optional. The artifact source's type." + } }, "status": { "type": "string", "defaultValue": "Enabled", - "metadata": { - "description": "Optional. Indicates if the artifact source is enabled (values: Enabled, Disabled). Default is \"Enabled\"." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Indicates if the artifact source is enabled (values: Enabled, Disabled). Default is \"Enabled\"." + } }, "uri": { "type": "string", @@ -1291,9 +1309,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7115830072126257185" - } + "version": "0.20.4.51522", + "templateHash": "4166206931202072952" + }, + "name": "DevTest Lab Costs", + "description": "This module deploys a DevTest Lab Cost.\r\n\r\nManage lab costs by setting a spending target that can be viewed in the Monthly Estimated Cost Trend chart. DevTest Labs can send a notification when spending reaches the specified target threshold.", + "owner": "Azure/module-maintainers" }, "parameters": { "labName": { @@ -1304,13 +1325,13 @@ }, "cycleType": { "type": "string", - "metadata": { - "description": "Required. Reporting cycle type." - }, "allowedValues": [ "Custom", "CalendarMonth" - ] + ], + "metadata": { + "description": "Required. Reporting cycle type." + } }, "tags": { "type": "object", @@ -1336,13 +1357,13 @@ "status": { "type": "string", "defaultValue": "Enabled", - "metadata": { - "description": "Optional. Target cost status." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Target cost status." + } }, "target": { "type": "int", @@ -1361,112 +1382,112 @@ "thresholdValue25DisplayOnChart": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Target Cost threshold at 25% display on chart. Indicates whether this threshold will be displayed on cost charts." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Target Cost threshold at 25% display on chart. Indicates whether this threshold will be displayed on cost charts." + } }, "thresholdValue25SendNotificationWhenExceeded": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Target cost threshold at 25% send notification when exceeded. Indicates whether notifications will be sent when this threshold is exceeded." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Target cost threshold at 25% send notification when exceeded. Indicates whether notifications will be sent when this threshold is exceeded." + } }, "thresholdValue50DisplayOnChart": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Target Cost threshold at 50% display on chart. Indicates whether this threshold will be displayed on cost charts." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Target Cost threshold at 50% display on chart. Indicates whether this threshold will be displayed on cost charts." + } }, "thresholdValue50SendNotificationWhenExceeded": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Target cost threshold at 50% send notification when exceeded. Indicates whether notifications will be sent when this threshold is exceeded." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Target cost threshold at 50% send notification when exceeded. Indicates whether notifications will be sent when this threshold is exceeded." + } }, "thresholdValue75DisplayOnChart": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Target Cost threshold at 75% display on chart. Indicates whether this threshold will be displayed on cost charts." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Target Cost threshold at 75% display on chart. Indicates whether this threshold will be displayed on cost charts." + } }, "thresholdValue75SendNotificationWhenExceeded": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Target cost threshold at 75% send notification when exceeded. Indicates whether notifications will be sent when this threshold is exceeded." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Target cost threshold at 75% send notification when exceeded. Indicates whether notifications will be sent when this threshold is exceeded." + } }, "thresholdValue100DisplayOnChart": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Target Cost threshold at 100% display on chart. Indicates whether this threshold will be displayed on cost charts." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Target Cost threshold at 100% display on chart. Indicates whether this threshold will be displayed on cost charts." + } }, "thresholdValue100SendNotificationWhenExceeded": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Target cost threshold at 100% send notification when exceeded. Indicates whether notifications will be sent when this threshold is exceeded." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Target cost threshold at 100% send notification when exceeded. Indicates whether notifications will be sent when this threshold is exceeded." + } }, "thresholdValue125DisplayOnChart": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Target Cost threshold at 125% display on chart. Indicates whether this threshold will be displayed on cost charts." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Target Cost threshold at 125% display on chart. Indicates whether this threshold will be displayed on cost charts." + } }, "thresholdValue125SendNotificationWhenExceeded": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Target cost threshold at 125% send notification when exceeded. Indicates whether notifications will be sent when this threshold is exceeded." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. Target cost threshold at 125% send notification when exceeded. Indicates whether notifications will be sent when this threshold is exceeded." + } }, "enableDefaultTelemetry": { "type": "bool", @@ -1615,8 +1636,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14668218410139786404" + "version": "0.20.4.51522", + "templateHash": "14124087164727132861" } }, "parameters": { diff --git a/modules/dev-test-lab/lab/notificationchannel/main.json b/modules/dev-test-lab/lab/notificationchannel/main.json index 4ba3408cee..0a723cda14 100644 --- a/modules/dev-test-lab/lab/notificationchannel/main.json +++ b/modules/dev-test-lab/lab/notificationchannel/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16463919279899526398" - } + "version": "0.20.4.51522", + "templateHash": "16877948453352231958" + }, + "name": "DevTest Lab Notification Channels", + "description": "This module deploys a DevTest Lab Notification Channel.\r\n\r\nNotification channels are used by the schedule resource type in order to send notifications or events to email addresses and/or webhooks.", + "owner": "Azure/module-maintainers" }, "parameters": { "labName": { @@ -17,13 +20,13 @@ }, "name": { "type": "string", - "metadata": { - "description": "Required. The name of the notification channel." - }, "allowedValues": [ "autoShutdown", "costThreshold" - ] + ], + "metadata": { + "description": "Required. The name of the notification channel." + } }, "tags": { "type": "object", diff --git a/modules/dev-test-lab/lab/policyset/policy/main.json b/modules/dev-test-lab/lab/policyset/policy/main.json index cf5f210223..5f4ddafad9 100644 --- a/modules/dev-test-lab/lab/policyset/policy/main.json +++ b/modules/dev-test-lab/lab/policyset/policy/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1906322712473031665" - } + "version": "0.20.4.51522", + "templateHash": "9961899772573814013" + }, + "name": "DevTest Lab Policy Sets Policies", + "description": "This module deploys a DevTest Lab Policy Sets Policy.\r\n\r\nDevTest lab policies are used to modify the lab settings such as only allowing certain VM Size SKUs, marketplace image types, number of VMs allowed per user and other settings.", + "owner": "Azure/module-maintainers" }, "parameters": { "labName": { @@ -44,13 +47,13 @@ }, "evaluatorType": { "type": "string", - "metadata": { - "description": "Required. The evaluator type of the policy (i.e. AllowedValuesPolicy, MaxValuePolicy)." - }, "allowedValues": [ "AllowedValuesPolicy", "MaxValuePolicy" - ] + ], + "metadata": { + "description": "Required. The evaluator type of the policy (i.e. AllowedValuesPolicy, MaxValuePolicy)." + } }, "factData": { "type": "string", @@ -61,9 +64,6 @@ }, "factName": { "type": "string", - "metadata": { - "description": "Required. The fact name of the policy." - }, "allowedValues": [ "EnvironmentTemplate", "GalleryImage", @@ -75,18 +75,21 @@ "UserOwnedLabPremiumVmCount", "UserOwnedLabVmCount", "UserOwnedLabVmCountInSubnet" - ] + ], + "metadata": { + "description": "Required. The fact name of the policy." + } }, "status": { "type": "string", "defaultValue": "Enabled", - "metadata": { - "description": "Optional. The status of the policy." - }, "allowedValues": [ "Disabled", "Enabled" - ] + ], + "metadata": { + "description": "Optional. The status of the policy." + } }, "threshold": { "type": "string", diff --git a/modules/dev-test-lab/lab/schedule/main.json b/modules/dev-test-lab/lab/schedule/main.json index 7cda200a3f..a4efd42401 100644 --- a/modules/dev-test-lab/lab/schedule/main.json +++ b/modules/dev-test-lab/lab/schedule/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18085550684061495455" - } + "version": "0.20.4.51522", + "templateHash": "12427678703978539260" + }, + "name": "DevTest Lab Schedules", + "description": "This module deploys a DevTest Lab Schedule.\r\n\r\nLab schedules are used to modify the settings for auto-shutdown, auto-start for lab virtual machines.", + "owner": "Azure/module-maintainers" }, "parameters": { "labName": { @@ -17,23 +20,23 @@ }, "name": { "type": "string", - "metadata": { - "description": "Required. The name of the schedule." - }, "allowedValues": [ "LabVmsShutdown", "LabVmAutoStart" - ] + ], + "metadata": { + "description": "Required. The name of the schedule." + } }, "taskType": { "type": "string", - "metadata": { - "description": "Required. The task type of the schedule (e.g. LabVmsShutdownTask, LabVmsStartupTask)." - }, "allowedValues": [ "LabVmsShutdownTask", "LabVmsStartupTask" - ] + ], + "metadata": { + "description": "Required. The task type of the schedule (e.g. LabVmsShutdownTask, LabVmsStartupTask)." + } }, "tags": { "type": "object", @@ -66,13 +69,13 @@ "status": { "type": "string", "defaultValue": "Enabled", - "metadata": { - "description": "Optional. The status of the schedule (i.e. Enabled, Disabled)." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. The status of the schedule (i.e. Enabled, Disabled)." + } }, "targetResourceId": { "type": "string", @@ -91,13 +94,13 @@ "notificationSettingsStatus": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. If notifications are enabled for this schedule (i.e. Enabled, Disabled)." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. If notifications are enabled for this schedule (i.e. Enabled, Disabled)." + } }, "notificationSettingsTimeInMinutes": { "type": "int", diff --git a/modules/dev-test-lab/lab/virtualnetwork/main.json b/modules/dev-test-lab/lab/virtualnetwork/main.json index 8ff199c35b..1449aed564 100644 --- a/modules/dev-test-lab/lab/virtualnetwork/main.json +++ b/modules/dev-test-lab/lab/virtualnetwork/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10889431821569458862" - } + "version": "0.20.4.51522", + "templateHash": "3541849489263903716" + }, + "name": "DevTest Lab Virtual Networks", + "description": "This module deploys a DevTest Lab Virtual Network.\r\n\r\nLab virtual machines must be deployed into a virtual network. This resource type allows configuring the virtual network and subnet settings used for the lab virtual machines.", + "owner": "Azure/module-maintainers" }, "parameters": { "labName": { diff --git a/modules/digital-twins/digital-twins-instance/.test/common/dependencies.bicep b/modules/digital-twins/digital-twins-instance/.test/common/dependencies.bicep index 1158799706..1e614d60b6 100644 --- a/modules/digital-twins/digital-twins-instance/.test/common/dependencies.bicep +++ b/modules/digital-twins/digital-twins-instance/.test/common/dependencies.bicep @@ -21,108 +21,108 @@ param eventGridDomainName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] + } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + serviceEndpoints: [ { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - serviceEndpoints: [ - { - service: 'Microsoft.KeyVault' - } - ] - } + service: 'Microsoft.KeyVault' } - ] - } + ] + } + } + ] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.digitaltwins.azure.net' - location: 'global' + name: 'privatelink.digitaltwins.azure.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource eventHubNamespace 'Microsoft.EventHub/namespaces@2022-10-01-preview' = { - name: eventHubNamespaceName - location: location - properties: { - zoneRedundant: false - isAutoInflateEnabled: false - maximumThroughputUnits: 0 - } - - resource eventHub 'eventhubs@2022-10-01-preview' = { - name: eventHubName - } + name: eventHubNamespaceName + location: location + properties: { + zoneRedundant: false + isAutoInflateEnabled: false + maximumThroughputUnits: 0 + } + + resource eventHub 'eventhubs@2022-10-01-preview' = { + name: eventHubName + } } resource serviceBus 'Microsoft.ServiceBus/namespaces@2022-10-01-preview' = { - name: serviceBusName - location: location - properties: { - zoneRedundant: false - } - - resource topic 'topics@2022-10-01-preview' = { - name: 'topic' - } + name: serviceBusName + location: location + properties: { + zoneRedundant: false + } + + resource topic 'topics@2022-10-01-preview' = { + name: 'topic' + } } resource eventGridDomain 'Microsoft.EventGrid/domains@2022-06-15' = { - name: eventGridDomainName - location: location - properties: { - disableLocalAuth: false - } - - resource topic 'topics@2022-06-15' = { - name: 'topic' - } + name: eventGridDomainName + location: location + properties: { + disableLocalAuth: false + } + + resource topic 'topics@2022-06-15' = { + name: 'topic' + } } resource eventHubNamespaceRbacAssignment 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid(managedIdentity.id, 'evhrbacAssignment') - scope: eventHubNamespace - properties: { - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '2b629674-e913-4c01-ae53-ef4638d8f975') //Azure Event Hubs Data Sender - principalId: managedIdentity.properties.principalId - principalType: 'ServicePrincipal' - } + name: guid(managedIdentity.id, 'evhrbacAssignment') + scope: eventHubNamespace + properties: { + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '2b629674-e913-4c01-ae53-ef4638d8f975') //Azure Event Hubs Data Sender + principalId: managedIdentity.properties.principalId + principalType: 'ServicePrincipal' + } } resource serviceBusRbacAssignment 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid(managedIdentity.id, 'sbrbacAssignment') - scope: serviceBus - properties: { - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '69a216fc-b8fb-44d8-bc22-1f3c2cd27a39') //Azure Service Bus Data Sender - principalId: managedIdentity.properties.principalId - principalType: 'ServicePrincipal' - } + name: guid(managedIdentity.id, 'sbrbacAssignment') + scope: serviceBus + properties: { + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '69a216fc-b8fb-44d8-bc22-1f3c2cd27a39') //Azure Service Bus Data Sender + principalId: managedIdentity.properties.principalId + principalType: 'ServicePrincipal' + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/digital-twins/digital-twins-instance/.test/common/main.test.bicep b/modules/digital-twins/digital-twins-instance/.test/common/main.test.bicep index 02d6f60bdb..e40037c573 100644 --- a/modules/digital-twins/digital-twins-instance/.test/common/main.test.bicep +++ b/modules/digital-twins/digital-twins-instance/.test/common/main.test.bicep @@ -87,7 +87,6 @@ module testDeployment '../../main.bicep' = { userAssignedIdentities: { '${nestedDependencies.outputs.managedIdentityResourceId}': {} } - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/digital-twins/digital-twins-instance/README.md b/modules/digital-twins/digital-twins-instance/README.md index 475adddc2f..43768dff83 100644 --- a/modules/digital-twins/digital-twins-instance/README.md +++ b/modules/digital-twins/digital-twins-instance/README.md @@ -20,8 +20,8 @@ This module deploys an Azure Digital Twins Instance. | `Microsoft.DigitalTwins/digitalTwinsInstances` | [2023-01-31](https://learn.microsoft.com/en-us/azure/templates/Microsoft.DigitalTwins/2023-01-31/digitalTwinsInstances) | | `Microsoft.DigitalTwins/digitalTwinsInstances/endpoints` | [2023-01-31](https://learn.microsoft.com/en-us/azure/templates/Microsoft.DigitalTwins/2023-01-31/digitalTwinsInstances/endpoints) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | ## Parameters @@ -38,7 +38,6 @@ This module deploys an Azure Digital Twins Instance. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, DataHistoryOperation, DigitalTwinsOperation, EventRoutesOperation, ModelsOperation, QueryOperation, ResourceProviderOperation]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `[format('{0}-diagnosticSettings', parameters('name'))]` | | The name of the diagnostic setting, if deployed. | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub. | @@ -458,7 +457,6 @@ module digitalTwinsInstance './digital-twins/digital-twins-instance/main.bicep' // Non-required parameters diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -533,9 +531,6 @@ module digitalTwinsInstance './digital-twins/digital-twins-instance/main.bicep' "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/digital-twins/digital-twins-instance/endpoint--event-grid/main.json b/modules/digital-twins/digital-twins-instance/endpoint--event-grid/main.json index a05d8b20ee..a1978b3907 100644 --- a/modules/digital-twins/digital-twins-instance/endpoint--event-grid/main.json +++ b/modules/digital-twins/digital-twins-instance/endpoint--event-grid/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13209746023702628221" - } + "version": "0.20.4.51522", + "templateHash": "7115177198919820190" + }, + "name": "Digital Twins Instance Event Grid Endpoints", + "description": "This module deploys a Digital Twins Instance Event Grid Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/digital-twins/digital-twins-instance/endpoint--event-hub/main.json b/modules/digital-twins/digital-twins-instance/endpoint--event-hub/main.json index 0ddaf11727..a964a1f125 100644 --- a/modules/digital-twins/digital-twins-instance/endpoint--event-hub/main.json +++ b/modules/digital-twins/digital-twins-instance/endpoint--event-hub/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11967486057366992053" - } + "version": "0.20.4.51522", + "templateHash": "10898754622351027742" + }, + "name": "Digital Twins Instance EventHub Endpoint", + "description": "This module deploys a Digital Twins Instance EventHub Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -25,13 +28,13 @@ "authenticationType": { "type": "string", "defaultValue": "IdentityBased", - "metadata": { - "description": "Optional. Specifies the authentication type being used for connecting to the endpoint. If 'KeyBased' is selected, a connection string must be specified (at least the primary connection string). If 'IdentityBased' is selected, the endpointUri and entityPath properties must be specified." - }, "allowedValues": [ "IdentityBased", "KeyBased" - ] + ], + "metadata": { + "description": "Optional. Specifies the authentication type being used for connecting to the endpoint. If 'KeyBased' is selected, a connection string must be specified (at least the primary connection string). If 'IdentityBased' is selected, the endpointUri and entityPath properties must be specified." + } }, "deadLetterSecret": { "type": "securestring", diff --git a/modules/digital-twins/digital-twins-instance/endpoint--service-bus/main.json b/modules/digital-twins/digital-twins-instance/endpoint--service-bus/main.json index 8301cecc7b..b1513fcf98 100644 --- a/modules/digital-twins/digital-twins-instance/endpoint--service-bus/main.json +++ b/modules/digital-twins/digital-twins-instance/endpoint--service-bus/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15643334991112942016" - } + "version": "0.20.4.51522", + "templateHash": "13127448885590640743" + }, + "name": "Digital Twins Instance ServiceBus Endpoint", + "description": "This module deploys a Digital Twins Instance ServiceBus Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -25,13 +28,13 @@ "authenticationType": { "type": "string", "defaultValue": "IdentityBased", - "metadata": { - "description": "Optional. Specifies the authentication type being used for connecting to the endpoint. If 'KeyBased' is selected, a connection string must be specified (at least the primary connection string). If 'IdentityBased' is selected, the endpointUri and entityPath properties must be specified." - }, "allowedValues": [ "IdentityBased", "KeyBased" - ] + ], + "metadata": { + "description": "Optional. Specifies the authentication type being used for connecting to the endpoint. If 'KeyBased' is selected, a connection string must be specified (at least the primary connection string). If 'IdentityBased' is selected, the endpointUri and entityPath properties must be specified." + } }, "deadLetterSecret": { "type": "securestring", diff --git a/modules/digital-twins/digital-twins-instance/main.bicep b/modules/digital-twins/digital-twins-instance/main.bicep index 63c51286ce..c2dd816a8d 100644 --- a/modules/digital-twins/digital-twins-instance/main.bicep +++ b/modules/digital-twins/digital-twins-instance/main.bicep @@ -53,11 +53,6 @@ param diagnosticSettingsName string = '${name}-diagnosticSettings' @description('Optional. Resource ID of the diagnostic storage account. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub.') param diagnosticStorageAccountId string = '' -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic log analytics workspace. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub.') param diagnosticWorkspaceId string = '' @@ -108,20 +103,12 @@ var identity = identityType != 'None' ? { var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -129,10 +116,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (enableDefaultTelemetry) { diff --git a/modules/digital-twins/digital-twins-instance/main.json b/modules/digital-twins/digital-twins-instance/main.json index f4cdcad468..3ea197b9bd 100644 --- a/modules/digital-twins/digital-twins-instance/main.json +++ b/modules/digital-twins/digital-twins-instance/main.json @@ -4,15 +4,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17940454545925305572" - } + "version": "0.20.4.51522", + "templateHash": "8772718651117933838" + }, + "name": "Digital Twins Instances", + "description": "This module deploys an Azure Digital Twins Instance.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { "type": "string", - "maxLength": 63, "minLength": 3, + "maxLength": 63, "metadata": { "description": "Required. The name of the Digital Twin Instance." } @@ -34,14 +37,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "systemAssignedIdentity": { "type": "bool", @@ -111,15 +114,6 @@ "description": "Optional. Resource ID of the diagnostic storage account. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticWorkspaceId": { "type": "string", "defaultValue": "", @@ -194,11 +188,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -207,18 +197,14 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], "enableReferencedModulesTelemetry": false, "identityType": "[if(parameters('systemAssignedIdentity'), if(not(empty(parameters('userAssignedIdentities'))), 'SystemAssigned, UserAssigned', 'SystemAssigned'), if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None'))]", "identity": "[if(not(equals(variables('identityType'), 'None')), createObject('type', variables('identityType'), 'userAssignedIdentities', if(not(empty(parameters('userAssignedIdentities'))), parameters('userAssignedIdentities'), null())), null())]", - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" }, "resources": [ { @@ -312,9 +298,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11967486057366992053" - } + "version": "0.20.4.51522", + "templateHash": "10898754622351027742" + }, + "name": "Digital Twins Instance EventHub Endpoint", + "description": "This module deploys a Digital Twins Instance EventHub Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -333,13 +322,13 @@ "authenticationType": { "type": "string", "defaultValue": "IdentityBased", - "metadata": { - "description": "Optional. Specifies the authentication type being used for connecting to the endpoint. If 'KeyBased' is selected, a connection string must be specified (at least the primary connection string). If 'IdentityBased' is selected, the endpointUri and entityPath properties must be specified." - }, "allowedValues": [ "IdentityBased", "KeyBased" - ] + ], + "metadata": { + "description": "Optional. Specifies the authentication type being used for connecting to the endpoint. If 'KeyBased' is selected, a connection string must be specified (at least the primary connection string). If 'IdentityBased' is selected, the endpointUri and entityPath properties must be specified." + } }, "deadLetterSecret": { "type": "securestring", @@ -499,9 +488,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13209746023702628221" - } + "version": "0.20.4.51522", + "templateHash": "7115177198919820190" + }, + "name": "Digital Twins Instance Event Grid Endpoints", + "description": "This module deploys a Digital Twins Instance Event Grid Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -644,9 +636,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15643334991112942016" - } + "version": "0.20.4.51522", + "templateHash": "13127448885590640743" + }, + "name": "Digital Twins Instance ServiceBus Endpoint", + "description": "This module deploys a Digital Twins Instance ServiceBus Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -665,13 +660,13 @@ "authenticationType": { "type": "string", "defaultValue": "IdentityBased", - "metadata": { - "description": "Optional. Specifies the authentication type being used for connecting to the endpoint. If 'KeyBased' is selected, a connection string must be specified (at least the primary connection string). If 'IdentityBased' is selected, the endpointUri and entityPath properties must be specified." - }, "allowedValues": [ "IdentityBased", "KeyBased" - ] + ], + "metadata": { + "description": "Optional. Specifies the authentication type being used for connecting to the endpoint. If 'KeyBased' is selected, a connection string must be specified (at least the primary connection string). If 'IdentityBased' is selected, the endpointUri and entityPath properties must be specified." + } }, "deadLetterSecret": { "type": "securestring", @@ -847,9 +842,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -914,14 +912,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -979,7 +977,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -1044,9 +1042,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -1057,8 +1058,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -1109,7 +1110,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -1179,8 +1180,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -1350,7 +1351,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -1393,8 +1394,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17162400653836540515" + "version": "0.20.4.51522", + "templateHash": "7097043325579895545" } }, "parameters": { diff --git a/modules/document-db/database-account/.test/gremlindb/main.test.bicep b/modules/document-db/database-account/.test/gremlindb/main.test.bicep index 8d67918a57..98abd55438 100644 --- a/modules/document-db/database-account/.test/gremlindb/main.test.bicep +++ b/modules/document-db/database-account/.test/gremlindb/main.test.bicep @@ -82,7 +82,6 @@ module testDeployment '../../main.bicep' = { diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diagnosticEventHubName: diagnosticDependencies.outputs.eventHubNamespaceEventHubName - diagnosticLogsRetentionInDays: 7 gremlinDatabases: [ { graphs: [ diff --git a/modules/document-db/database-account/.test/mongodb/main.test.bicep b/modules/document-db/database-account/.test/mongodb/main.test.bicep index 287ff5759c..bd0e8f4fa8 100644 --- a/modules/document-db/database-account/.test/mongodb/main.test.bicep +++ b/modules/document-db/database-account/.test/mongodb/main.test.bicep @@ -79,7 +79,6 @@ module testDeployment '../../main.bicep' = { diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diagnosticEventHubName: diagnosticDependencies.outputs.eventHubNamespaceEventHubName - diagnosticLogsRetentionInDays: 7 location: location mongodbDatabases: [ { diff --git a/modules/document-db/database-account/.test/plain/main.test.bicep b/modules/document-db/database-account/.test/plain/main.test.bicep index d0a7345316..23071b8799 100644 --- a/modules/document-db/database-account/.test/plain/main.test.bicep +++ b/modules/document-db/database-account/.test/plain/main.test.bicep @@ -79,7 +79,6 @@ module testDeployment '../../main.bicep' = { diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diagnosticEventHubName: diagnosticDependencies.outputs.eventHubNamespaceEventHubName - diagnosticLogsRetentionInDays: 7 lock: 'CanNotDelete' roleAssignments: [ { diff --git a/modules/document-db/database-account/.test/sqldb/dependencies.bicep b/modules/document-db/database-account/.test/sqldb/dependencies.bicep index 520130acf4..50a1ace621 100644 --- a/modules/document-db/database-account/.test/sqldb/dependencies.bicep +++ b/modules/document-db/database-account/.test/sqldb/dependencies.bicep @@ -10,44 +10,44 @@ param virtualNetworkName string var addressPrefix = '10.0.0.0/16' resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2023-01-31' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.documents.azure.com' - location: 'global' + name: 'privatelink.documents.azure.com' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } @description('The principal ID of the created Managed Identity.') diff --git a/modules/document-db/database-account/.test/sqldb/main.test.bicep b/modules/document-db/database-account/.test/sqldb/main.test.bicep index 711dfcf861..ba9288205b 100644 --- a/modules/document-db/database-account/.test/sqldb/main.test.bicep +++ b/modules/document-db/database-account/.test/sqldb/main.test.bicep @@ -80,7 +80,6 @@ module testDeployment '../../main.bicep' = { diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diagnosticEventHubName: diagnosticDependencies.outputs.eventHubNamespaceEventHubName - diagnosticLogsRetentionInDays: 7 location: location privateEndpoints: [ { diff --git a/modules/document-db/database-account/README.md b/modules/document-db/database-account/README.md index e0f3ad0023..72f4640a8a 100644 --- a/modules/document-db/database-account/README.md +++ b/modules/document-db/database-account/README.md @@ -24,8 +24,8 @@ This module deploys a DocumentDB Database Account. | `Microsoft.DocumentDB/databaseAccounts/sqlDatabases` | [2023-04-15](https://learn.microsoft.com/en-us/azure/templates/Microsoft.DocumentDB/2023-04-15/databaseAccounts/sqlDatabases) | | `Microsoft.DocumentDB/databaseAccounts/sqlDatabases/containers` | [2023-04-15](https://learn.microsoft.com/en-us/azure/templates/Microsoft.DocumentDB/2023-04-15/databaseAccounts/sqlDatabases/containers) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | ## Parameters @@ -52,7 +52,6 @@ This module deploys a DocumentDB Database Account. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, CassandraRequests, ControlPlaneRequests, DataPlaneRequests, GremlinRequests, MongoRequests, PartitionKeyRUConsumption, PartitionKeyStatistics, QueryRuntimeStatistics, TableApiRequests]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[Requests]` | `[Requests]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -682,7 +681,6 @@ module databaseAccount './document-db/database-account/main.bicep' = { ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -795,9 +793,6 @@ module databaseAccount './document-db/database-account/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, @@ -914,7 +909,6 @@ module databaseAccount './document-db/database-account/main.bicep' = { // Non-required parameters diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -1158,9 +1152,6 @@ module databaseAccount './document-db/database-account/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, @@ -1413,7 +1404,6 @@ module databaseAccount './document-db/database-account/main.bicep' = { // Non-required parameters diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -1472,9 +1462,6 @@ module databaseAccount './document-db/database-account/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, @@ -1538,7 +1525,6 @@ module databaseAccount './document-db/database-account/main.bicep' = { // Non-required parameters diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -1691,9 +1677,6 @@ module databaseAccount './document-db/database-account/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/document-db/database-account/gremlin-database/graph/main.json b/modules/document-db/database-account/gremlin-database/graph/main.json index 480334ee13..d02a60bd22 100644 --- a/modules/document-db/database-account/gremlin-database/graph/main.json +++ b/modules/document-db/database-account/gremlin-database/graph/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "105866141402179587" - } + "version": "0.20.4.51522", + "templateHash": "3593445264917455012" + }, + "name": "DocumentDB Database Accounts Gremlin Databases Graphs", + "description": "This module deploys a DocumentDB Database Accounts Gremlin Database Graph.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/document-db/database-account/gremlin-database/main.json b/modules/document-db/database-account/gremlin-database/main.json index e709363984..f3df7da63e 100644 --- a/modules/document-db/database-account/gremlin-database/main.json +++ b/modules/document-db/database-account/gremlin-database/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8691476614330099391" - } + "version": "0.20.4.51522", + "templateHash": "4256328904115204005" + }, + "name": "DocumentDB Database Account Gremlin Databases", + "description": "This module deploys a Gremlin Database within a CosmosDB Account.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -138,9 +141,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "105866141402179587" - } + "version": "0.20.4.51522", + "templateHash": "3593445264917455012" + }, + "name": "DocumentDB Database Accounts Gremlin Databases Graphs", + "description": "This module deploys a DocumentDB Database Accounts Gremlin Database Graph.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/document-db/database-account/main.bicep b/modules/document-db/database-account/main.bicep index c4e5faface..9d148d775c 100644 --- a/modules/document-db/database-account/main.bicep +++ b/modules/document-db/database-account/main.bicep @@ -84,11 +84,6 @@ param lock string = '' @description('Optional. Array of role assignment objects that contain the \'roleDefinitionIdOrName\' and \'principalIds\' to define RBAC role assignments on this resource. In the roleDefinitionIdOrName attribute, you can provide either the display name of the role definition, or its fully qualified ID in the following format: \'/providers/Microsoft.Authorization/roleDefinitions/c2f4ef07-c644-48eb-af81-4b1b4947fb11\'.') param roleAssignments array = [] -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -179,20 +174,12 @@ param privateEndpoints array = [] var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -200,10 +187,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var identityType = systemAssignedIdentity ? (!empty(userAssignedIdentities) ? 'SystemAssigned, UserAssigned' : 'SystemAssigned') : (!empty(userAssignedIdentities) ? 'UserAssigned' : 'None') diff --git a/modules/document-db/database-account/main.json b/modules/document-db/database-account/main.json index 33948cd93c..c5f9ce0bac 100644 --- a/modules/document-db/database-account/main.json +++ b/modules/document-db/database-account/main.json @@ -4,8 +4,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3491055673573321477" + "version": "0.20.4.51522", + "templateHash": "17230929813729114087" }, "name": "DocumentDB Database Accounts", "description": "This module deploys a DocumentDB Database Account.", @@ -65,16 +65,16 @@ "defaultConsistencyLevel": { "type": "string", "defaultValue": "Session", - "metadata": { - "description": "Optional. The default consistency level of the Cosmos DB account." - }, "allowedValues": [ "Eventual", "ConsistentPrefix", "Session", "BoundedStaleness", "Strong" - ] + ], + "metadata": { + "description": "Optional. The default consistency level of the Cosmos DB account." + } }, "automaticFailover": { "type": "bool", @@ -93,20 +93,20 @@ "maxStalenessPrefix": { "type": "int", "defaultValue": 100000, + "minValue": 10, + "maxValue": 2147483647, "metadata": { "description": "Optional. Max stale requests. Required for BoundedStaleness. Valid ranges, Single Region: 10 to 1000000. Multi Region: 100000 to 1000000." - }, - "maxValue": 2147483647, - "minValue": 10 + } }, "maxIntervalInSeconds": { "type": "int", "defaultValue": 300, + "minValue": 5, + "maxValue": 86400, "metadata": { "description": "Optional. Max lag time (minutes). Required for BoundedStaleness. Valid ranges, Single Region: 5 to 84600. Multi Region: 300 to 86400." - }, - "maxValue": 86400, - "minValue": 5 + } }, "serverVersion": { "type": "string", @@ -152,14 +152,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -168,15 +168,6 @@ "description": "Optional. Array of role assignment objects that contain the 'roleDefinitionIdOrName' and 'principalIds' to define RBAC role assignments on this resource. In the roleDefinitionIdOrName attribute, you can provide either the display name of the role definition, or its fully qualified ID in the following format: '/providers/Microsoft.Authorization/roleDefinitions/c2f4ef07-c644-48eb-af81-4b1b4947fb11'." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -249,9 +240,6 @@ "capabilitiesToAdd": { "type": "array", "defaultValue": [], - "metadata": { - "description": "Optional. List of Cosmos DB capabilities for the account." - }, "allowedValues": [ "EnableCassandra", "EnableTable", @@ -259,59 +247,62 @@ "EnableMongo", "DisableRateLimitingResponses", "EnableServerless" - ] + ], + "metadata": { + "description": "Optional. List of Cosmos DB capabilities for the account." + } }, "backupPolicyType": { "type": "string", "defaultValue": "Continuous", - "metadata": { - "description": "Optional. Describes the mode of backups." - }, "allowedValues": [ "Periodic", "Continuous" - ] + ], + "metadata": { + "description": "Optional. Describes the mode of backups." + } }, "backupPolicyContinuousTier": { "type": "string", "defaultValue": "Continuous30Days", - "metadata": { - "description": "Optional. Configuration values for continuous mode backup." - }, "allowedValues": [ "Continuous30Days", "Continuous7Days" - ] + ], + "metadata": { + "description": "Optional. Configuration values for continuous mode backup." + } }, "backupIntervalInMinutes": { "type": "int", "defaultValue": 240, + "minValue": 60, + "maxValue": 1440, "metadata": { "description": "Optional. An integer representing the interval in minutes between two backups. Only applies to periodic backup type." - }, - "maxValue": 1440, - "minValue": 60 + } }, "backupRetentionIntervalInHours": { "type": "int", "defaultValue": 8, + "minValue": 2, + "maxValue": 720, "metadata": { "description": "Optional. An integer representing the time (in hours) that each backup is retained. Only applies to periodic backup type." - }, - "maxValue": 720, - "minValue": 2 + } }, "backupStorageRedundancy": { "type": "string", "defaultValue": "Local", - "metadata": { - "description": "Optional. Enum to indicate type of backup residency. Only applies to periodic backup type." - }, "allowedValues": [ "Geo", "Local", "Zone" - ] + ], + "metadata": { + "description": "Optional. Enum to indicate type of backup residency. Only applies to periodic backup type." + } }, "privateEndpoints": { "type": "array", @@ -328,11 +319,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -341,11 +328,7 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -365,7 +348,7 @@ } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "identityType": "[if(parameters('systemAssignedIdentity'), if(not(empty(parameters('userAssignedIdentities'))), 'SystemAssigned, UserAssigned', 'SystemAssigned'), if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None'))]", "identity": "[if(not(equals(variables('identityType'), 'None')), createObject('type', variables('identityType'), 'userAssignedIdentities', if(not(empty(parameters('userAssignedIdentities'))), parameters('userAssignedIdentities'), null())), null())]", "consistencyPolicy": { @@ -483,8 +466,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15105512277629326341" + "version": "0.20.4.51522", + "templateHash": "9062930380498217256" } }, "parameters": { @@ -635,8 +618,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9165958576985328916" + "version": "0.20.4.51522", + "templateHash": "3181306638327423907" }, "name": "DocumentDB Database Account SQL Databases", "description": "This module deploys a SQL Database in a CosmosDB Account.", @@ -763,8 +746,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11426208730264271754" + "version": "0.20.4.51522", + "templateHash": "14315455818011845279" }, "name": "DocumentDB Database Account SQL Database Containers", "description": "This module deploys a SQL Database Container in a CosmosDB Account.", @@ -806,11 +789,11 @@ "defaultTtl": { "type": "int", "defaultValue": -1, + "minValue": -1, + "maxValue": 2147483647, "metadata": { "description": "Optional. Default time to live (in seconds). With Time to Live or TTL, Azure Cosmos DB provides the ability to delete items automatically from a container after a certain time period. If the value is set to \"-1\", it is equal to infinity, and items dont expire by default." - }, - "minValue": -1, - "maxValue": 2147483647 + } }, "throughput": { "type": "int", @@ -822,10 +805,10 @@ "autoscaleSettingsMaxThroughput": { "type": "int", "defaultValue": -1, + "maxValue": 1000000, "metadata": { "description": "Optional. Specifies the Autoscale settings and represents maximum throughput, the resource can scale up to. The autoscale throughput should have valid throughput values between 1000 and 1000000 inclusive in increments of 1000. If value is set to -1, then the property will be set to null and autoscale will be disabled." - }, - "maxValue": 1000000 + } }, "tags": { "type": "object", @@ -1002,8 +985,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2085063402479874129" + "version": "0.20.4.51522", + "templateHash": "13972019361365434498" }, "name": "DocumentDB Database Account MongoDB Databases", "description": "This module deploys a MongoDB Database within a CosmosDB Account.", @@ -1120,8 +1103,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18146087628954569143" + "version": "0.20.4.51522", + "templateHash": "12957080003676592321" }, "name": "DocumentDB Database Account MongoDB Database Collections", "description": "This module deploys a MongoDB Database Collection.", @@ -1292,8 +1275,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14580792451038416315" + "version": "0.20.4.51522", + "templateHash": "4256328904115204005" }, "name": "DocumentDB Database Account Gremlin Databases", "description": "This module deploys a Gremlin Database within a CosmosDB Account.", @@ -1429,8 +1412,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7554276634599299832" + "version": "0.20.4.51522", + "templateHash": "3593445264917455012" }, "name": "DocumentDB Database Accounts Gremlin Databases Graphs", "description": "This module deploys a DocumentDB Database Accounts Gremlin Database Graph.", @@ -1622,8 +1605,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15343651026946310931" + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" }, "name": "Private Endpoints", "description": "This module deploys a Private Endpoint.", @@ -1692,14 +1675,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -1757,7 +1740,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -1822,8 +1805,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5406224106432076575" + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" }, "name": "Private Endpoint Private DNS Zone Groups", "description": "This module deploys a Private Endpoint Private DNS Zone Group.", @@ -1838,8 +1821,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -1890,7 +1873,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -1960,8 +1943,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -2131,7 +2114,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } diff --git a/modules/document-db/database-account/mongodb-database/collection/main.json b/modules/document-db/database-account/mongodb-database/collection/main.json index 61a59a5fb6..a6fa0bc567 100644 --- a/modules/document-db/database-account/mongodb-database/collection/main.json +++ b/modules/document-db/database-account/mongodb-database/collection/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17023323765982935979" - } + "version": "0.20.4.51522", + "templateHash": "12957080003676592321" + }, + "name": "DocumentDB Database Account MongoDB Database Collections", + "description": "This module deploys a MongoDB Database Collection.", + "owner": "Azure/module-maintainers" }, "parameters": { "databaseAccountName": { diff --git a/modules/document-db/database-account/mongodb-database/main.json b/modules/document-db/database-account/mongodb-database/main.json index f412e3d556..3446932229 100644 --- a/modules/document-db/database-account/mongodb-database/main.json +++ b/modules/document-db/database-account/mongodb-database/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10478774274627200406" - } + "version": "0.20.4.51522", + "templateHash": "13972019361365434498" + }, + "name": "DocumentDB Database Account MongoDB Databases", + "description": "This module deploys a MongoDB Database within a CosmosDB Account.", + "owner": "Azure/module-maintainers" }, "parameters": { "databaseAccountName": { @@ -119,9 +122,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17023323765982935979" - } + "version": "0.20.4.51522", + "templateHash": "12957080003676592321" + }, + "name": "DocumentDB Database Account MongoDB Database Collections", + "description": "This module deploys a MongoDB Database Collection.", + "owner": "Azure/module-maintainers" }, "parameters": { "databaseAccountName": { diff --git a/modules/document-db/database-account/sql-database/container/main.json b/modules/document-db/database-account/sql-database/container/main.json index f4c487ffac..6986286959 100644 --- a/modules/document-db/database-account/sql-database/container/main.json +++ b/modules/document-db/database-account/sql-database/container/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7895705651487538293" - } + "version": "0.20.4.51522", + "templateHash": "14315455818011845279" + }, + "name": "DocumentDB Database Account SQL Database Containers", + "description": "This module deploys a SQL Database Container in a CosmosDB Account.", + "owner": "Azure/module-maintainers" }, "parameters": { "databaseAccountName": { @@ -44,11 +47,11 @@ "defaultTtl": { "type": "int", "defaultValue": -1, + "minValue": -1, + "maxValue": 2147483647, "metadata": { "description": "Optional. Default time to live (in seconds). With Time to Live or TTL, Azure Cosmos DB provides the ability to delete items automatically from a container after a certain time period. If the value is set to \"-1\", it is equal to infinity, and items dont expire by default." - }, - "minValue": -1, - "maxValue": 2147483647 + } }, "throughput": { "type": "int", @@ -60,10 +63,10 @@ "autoscaleSettingsMaxThroughput": { "type": "int", "defaultValue": -1, + "maxValue": 1000000, "metadata": { "description": "Optional. Specifies the Autoscale settings and represents maximum throughput, the resource can scale up to. The autoscale throughput should have valid throughput values between 1000 and 1000000 inclusive in increments of 1000. If value is set to -1, then the property will be set to null and autoscale will be disabled." - }, - "maxValue": 1000000 + } }, "tags": { "type": "object", diff --git a/modules/document-db/database-account/sql-database/main.json b/modules/document-db/database-account/sql-database/main.json index 28e4e55973..145a1881bc 100644 --- a/modules/document-db/database-account/sql-database/main.json +++ b/modules/document-db/database-account/sql-database/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12220674864217683327" - } + "version": "0.20.4.51522", + "templateHash": "3181306638327423907" + }, + "name": "DocumentDB Database Account SQL Databases", + "description": "This module deploys a SQL Database in a CosmosDB Account.", + "owner": "Azure/module-maintainers" }, "parameters": { "databaseAccountName": { @@ -129,9 +132,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7895705651487538293" - } + "version": "0.20.4.51522", + "templateHash": "14315455818011845279" + }, + "name": "DocumentDB Database Account SQL Database Containers", + "description": "This module deploys a SQL Database Container in a CosmosDB Account.", + "owner": "Azure/module-maintainers" }, "parameters": { "databaseAccountName": { @@ -169,11 +175,11 @@ "defaultTtl": { "type": "int", "defaultValue": -1, + "minValue": -1, + "maxValue": 2147483647, "metadata": { "description": "Optional. Default time to live (in seconds). With Time to Live or TTL, Azure Cosmos DB provides the ability to delete items automatically from a container after a certain time period. If the value is set to \"-1\", it is equal to infinity, and items dont expire by default." - }, - "minValue": -1, - "maxValue": 2147483647 + } }, "throughput": { "type": "int", @@ -185,10 +191,10 @@ "autoscaleSettingsMaxThroughput": { "type": "int", "defaultValue": -1, + "maxValue": 1000000, "metadata": { "description": "Optional. Specifies the Autoscale settings and represents maximum throughput, the resource can scale up to. The autoscale throughput should have valid throughput values between 1000 and 1000000 inclusive in increments of 1000. If value is set to -1, then the property will be set to null and autoscale will be disabled." - }, - "maxValue": 1000000 + } }, "tags": { "type": "object", diff --git a/modules/event-grid/domain/.test/common/dependencies.bicep b/modules/event-grid/domain/.test/common/dependencies.bicep index c4d9640171..9ae6106fca 100644 --- a/modules/event-grid/domain/.test/common/dependencies.bicep +++ b/modules/event-grid/domain/.test/common/dependencies.bicep @@ -9,45 +9,45 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/24' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.eventgrid.azure.net' - location: 'global' + name: 'privatelink.eventgrid.azure.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/event-grid/domain/.test/common/main.test.bicep b/modules/event-grid/domain/.test/common/main.test.bicep index 062266742e..2bbe444ed6 100644 --- a/modules/event-grid/domain/.test/common/main.test.bicep +++ b/modules/event-grid/domain/.test/common/main.test.bicep @@ -64,7 +64,6 @@ module testDeployment '../../main.bicep' = { params: { enableDefaultTelemetry: enableDefaultTelemetry name: '${namePrefix}${serviceShort}001' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/event-grid/domain/.test/pe/dependencies.bicep b/modules/event-grid/domain/.test/pe/dependencies.bicep index 0013cdcdfd..b4da965a54 100644 --- a/modules/event-grid/domain/.test/pe/dependencies.bicep +++ b/modules/event-grid/domain/.test/pe/dependencies.bicep @@ -6,40 +6,40 @@ param virtualNetworkName string var addressPrefix = '10.0.0.0/24' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.eventgrid.azure.net' - location: 'global' + name: 'privatelink.eventgrid.azure.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/event-grid/domain/README.md b/modules/event-grid/domain/README.md index 622fb2af80..97d325a857 100644 --- a/modules/event-grid/domain/README.md +++ b/modules/event-grid/domain/README.md @@ -19,8 +19,8 @@ This module deploys an Event Grid Domain. | `Microsoft.EventGrid/domains` | [2022-06-15](https://learn.microsoft.com/en-us/azure/templates/Microsoft.EventGrid/2022-06-15/domains) | | `Microsoft.EventGrid/domains/topics` | [2022-06-15](https://learn.microsoft.com/en-us/azure/templates/Microsoft.EventGrid/2022-06-15/domains/topics) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | ## Parameters @@ -39,7 +39,6 @@ This module deploys an Event Grid Domain. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, DeliveryFailures, PublishFailures]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -294,7 +293,6 @@ module domain './event-grid/domain/main.bicep' = { // Non-required parameters diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -363,9 +361,6 @@ module domain './event-grid/domain/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/event-grid/domain/main.bicep b/modules/event-grid/domain/main.bicep index 91dac314a3..853973234c 100644 --- a/modules/event-grid/domain/main.bicep +++ b/modules/event-grid/domain/main.bicep @@ -25,11 +25,6 @@ param autoDeleteTopicWithLastSubscription bool = true @description('Optional. This can be used to restrict traffic from specific IPs instead of all IPs. Note: These are considered only if PublicNetworkAccess is enabled.') param inboundIpRules array = [] -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -92,20 +87,12 @@ var enableReferencedModulesTelemetry = false var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -113,10 +100,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (enableDefaultTelemetry) { diff --git a/modules/event-grid/domain/main.json b/modules/event-grid/domain/main.json index ee003cb8dc..3c01e2fcef 100644 --- a/modules/event-grid/domain/main.json +++ b/modules/event-grid/domain/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13835175854435646864" - } + "version": "0.20.4.51522", + "templateHash": "15864855878909112039" + }, + "name": "Event Grid Domains", + "description": "This module deploys an Event Grid Domain.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -55,15 +58,6 @@ "description": "Optional. This can be used to restrict traffic from specific IPs instead of all IPs. Note: These are considered only if PublicNetworkAccess is enabled." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -109,14 +103,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "tags": { "type": "object", @@ -181,11 +175,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -194,16 +184,12 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], "enableReferencedModulesTelemetry": false, - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" }, "resources": [ { @@ -298,9 +284,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1958901830516383626" - } + "version": "0.20.4.51522", + "templateHash": "15871414282174794846" + }, + "name": "Event Grid Domain Topics", + "description": "This module deploys an Event Grid Domain Topic.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -428,9 +417,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -495,14 +487,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -560,7 +552,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -625,9 +617,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -638,8 +633,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -690,7 +685,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -760,8 +755,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -931,7 +926,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -974,8 +969,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "115357666483455741" + "version": "0.20.4.51522", + "templateHash": "13076781654377390405" } }, "parameters": { diff --git a/modules/event-grid/domain/topic/main.json b/modules/event-grid/domain/topic/main.json index 10b535da1e..8b821bd6f1 100644 --- a/modules/event-grid/domain/topic/main.json +++ b/modules/event-grid/domain/topic/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1958901830516383626" - } + "version": "0.20.4.51522", + "templateHash": "15871414282174794846" + }, + "name": "Event Grid Domain Topics", + "description": "This module deploys an Event Grid Domain Topic.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/event-grid/system-topic/.test/common/main.test.bicep b/modules/event-grid/system-topic/.test/common/main.test.bicep index e115ce165c..3499151049 100644 --- a/modules/event-grid/system-topic/.test/common/main.test.bicep +++ b/modules/event-grid/system-topic/.test/common/main.test.bicep @@ -89,7 +89,6 @@ module testDeployment '../../main.bicep' = { } } } ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/event-grid/system-topic/README.md b/modules/event-grid/system-topic/README.md index cb654ff3eb..a2e2b0e2e0 100644 --- a/modules/event-grid/system-topic/README.md +++ b/modules/event-grid/system-topic/README.md @@ -37,7 +37,6 @@ This module deploys an Event Grid System Topic. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, DeliveryFailures]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -296,7 +295,6 @@ module systemTopic './event-grid/system-topic/main.bicep' = { // Non-required parameters diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -371,9 +369,6 @@ module systemTopic './event-grid/system-topic/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/event-grid/system-topic/event-subscription/main.json b/modules/event-grid/system-topic/event-subscription/main.json index b6efb6b3c5..d01d0b7544 100644 --- a/modules/event-grid/system-topic/event-subscription/main.json +++ b/modules/event-grid/system-topic/event-subscription/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6312139785830942393" - } + "version": "0.20.4.51522", + "templateHash": "2662254923590356448" + }, + "name": "Event Grid System Topic Event Subscriptions", + "description": "This module deploys an Event Grid System Topic Event Subscription.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/event-grid/system-topic/main.bicep b/modules/event-grid/system-topic/main.bicep index 1b94c2cc93..5358a5ea6f 100644 --- a/modules/event-grid/system-topic/main.bicep +++ b/modules/event-grid/system-topic/main.bicep @@ -17,11 +17,6 @@ param topicType string @description('Optional. Event subscriptions to deploy.') param eventSubscriptions array = [] -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -88,20 +83,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -109,10 +96,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (enableDefaultTelemetry) { diff --git a/modules/event-grid/system-topic/main.json b/modules/event-grid/system-topic/main.json index f6eb732795..a00048c3e8 100644 --- a/modules/event-grid/system-topic/main.json +++ b/modules/event-grid/system-topic/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15016048767972452581" - } + "version": "0.20.4.51522", + "templateHash": "16335082464583916112" + }, + "name": "Event Grid System Topics", + "description": "This module deploys an Event Grid System Topic.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -41,15 +44,6 @@ "description": "Optional. Event subscriptions to deploy." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -88,14 +82,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "systemAssignedIdentity": { "type": "bool", @@ -166,11 +160,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -179,17 +169,13 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], "identityType": "[if(parameters('systemAssignedIdentity'), if(not(empty(parameters('userAssignedIdentities'))), 'SystemAssigned,UserAssigned', 'SystemAssigned'), if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None'))]", "identity": "[if(not(equals(variables('identityType'), 'None')), createObject('type', variables('identityType'), 'userAssignedIdentities', if(not(empty(parameters('userAssignedIdentities'))), parameters('userAssignedIdentities'), null())), null())]", - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" }, "resources": [ { @@ -290,9 +276,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6312139785830942393" - } + "version": "0.20.4.51522", + "templateHash": "2662254923590356448" + }, + "name": "Event Grid System Topic Event Subscriptions", + "description": "This module deploys an Event Grid System Topic Event Subscription.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -492,8 +481,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14619209932195450330" + "version": "0.20.4.51522", + "templateHash": "7084319761637070874" } }, "parameters": { diff --git a/modules/event-grid/topic/.test/common/dependencies.bicep b/modules/event-grid/topic/.test/common/dependencies.bicep index 30384d73fa..6f09643d9e 100644 --- a/modules/event-grid/topic/.test/common/dependencies.bicep +++ b/modules/event-grid/topic/.test/common/dependencies.bicep @@ -15,62 +15,62 @@ param storageQueueName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.eventgrid.azure.net' - location: 'global' + name: 'privatelink.eventgrid.azure.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource storageAccount 'Microsoft.Storage/storageAccounts@2022-05-01' = { - name: storageAccountName - location: location - sku: { - name: 'Standard_LRS' - } - kind: 'StorageV2' - - resource queueService 'queueServices@2022-09-01' = { - name: 'default' - - resource queue 'queues@2022-09-01' = { - name: storageQueueName - } + name: storageAccountName + location: location + sku: { + name: 'Standard_LRS' + } + kind: 'StorageV2' + + resource queueService 'queueServices@2022-09-01' = { + name: 'default' + + resource queue 'queues@2022-09-01' = { + name: storageQueueName } + } } @description('The name of the created Storage Account Queue.') diff --git a/modules/event-grid/topic/.test/common/main.test.bicep b/modules/event-grid/topic/.test/common/main.test.bicep index 5bc6af6b1b..0b2f474962 100644 --- a/modules/event-grid/topic/.test/common/main.test.bicep +++ b/modules/event-grid/topic/.test/common/main.test.bicep @@ -66,7 +66,6 @@ module testDeployment '../../main.bicep' = { params: { enableDefaultTelemetry: enableDefaultTelemetry name: '${namePrefix}${serviceShort}001' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/event-grid/topic/.test/pe/dependencies.bicep b/modules/event-grid/topic/.test/pe/dependencies.bicep index 36760779bc..3b3a2bc528 100644 --- a/modules/event-grid/topic/.test/pe/dependencies.bicep +++ b/modules/event-grid/topic/.test/pe/dependencies.bicep @@ -6,40 +6,40 @@ param virtualNetworkName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.eventgrid.azure.net' - location: 'global' + name: 'privatelink.eventgrid.azure.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/event-grid/topic/README.md b/modules/event-grid/topic/README.md index f41ed493f2..f6adfeea5f 100644 --- a/modules/event-grid/topic/README.md +++ b/modules/event-grid/topic/README.md @@ -19,8 +19,8 @@ This module deploys an Event Grid Topic. | `Microsoft.EventGrid/topics` | [2020-06-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.EventGrid/2020-06-01/topics) | | `Microsoft.EventGrid/topics/eventSubscriptions` | [2022-06-15](https://learn.microsoft.com/en-us/azure/templates/Microsoft.EventGrid/2022-06-15/topics/eventSubscriptions) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | ## Parameters @@ -37,7 +37,6 @@ This module deploys an Event Grid Topic. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, DeliveryFailures, PublishFailures]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -365,7 +364,6 @@ module topic './event-grid/topic/main.bicep' = { // Non-required parameters diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -455,9 +453,6 @@ module topic './event-grid/topic/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/event-grid/topic/event-subscription/main.json b/modules/event-grid/topic/event-subscription/main.json index 76143407a5..37e87b702f 100644 --- a/modules/event-grid/topic/event-subscription/main.json +++ b/modules/event-grid/topic/event-subscription/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13659394716816957331" - } + "version": "0.20.4.51522", + "templateHash": "1847712751203709530" + }, + "name": "EventGrid Topic Event Subscriptions", + "description": "This module deploys an Event Grid Topic Event Subscription.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/event-grid/topic/main.bicep b/modules/event-grid/topic/main.bicep index 7329c82707..fffa608311 100644 --- a/modules/event-grid/topic/main.bicep +++ b/modules/event-grid/topic/main.bicep @@ -22,11 +22,6 @@ param inboundIpRules array = [] @description('Optional. Event subscriptions to deploy.') param eventSubscriptions array = [] -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -86,20 +81,12 @@ var enableReferencedModulesTelemetry = false var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -107,10 +94,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (enableDefaultTelemetry) { diff --git a/modules/event-grid/topic/main.json b/modules/event-grid/topic/main.json index dfad1d9342..967a18689a 100644 --- a/modules/event-grid/topic/main.json +++ b/modules/event-grid/topic/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9717433644580355259" - } + "version": "0.20.4.51522", + "templateHash": "14089220073124056591" + }, + "name": "Event Grid Topics", + "description": "This module deploys an Event Grid Topic.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -48,15 +51,6 @@ "description": "Optional. Event subscriptions to deploy." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -102,14 +96,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "tags": { "type": "object", @@ -167,11 +161,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -180,16 +170,12 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], "enableReferencedModulesTelemetry": false, - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" }, "resources": [ { @@ -289,9 +275,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13659394716816957331" - } + "version": "0.20.4.51522", + "templateHash": "1847712751203709530" + }, + "name": "EventGrid Topic Event Subscriptions", + "description": "This module deploys an Event Grid Topic Event Subscription.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -505,9 +494,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -572,14 +564,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -637,7 +629,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -702,9 +694,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -715,8 +710,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -767,7 +762,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -837,8 +832,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -1008,7 +1003,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -1051,8 +1046,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16959172094631561093" + "version": "0.20.4.51522", + "templateHash": "1040861789592039077" } }, "parameters": { diff --git a/modules/event-hub/namespace/.test/common/dependencies.bicep b/modules/event-hub/namespace/.test/common/dependencies.bicep index c0ea09afc0..c7365e40bf 100644 --- a/modules/event-hub/namespace/.test/common/dependencies.bicep +++ b/modules/event-hub/namespace/.test/common/dependencies.bicep @@ -12,59 +12,59 @@ param storageAccountName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] + } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + serviceEndpoints: [ { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - serviceEndpoints: [ - { - service: 'Microsoft.EventHub' - } - ] - } + service: 'Microsoft.EventHub' } - ] - } + ] + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.servicebus.windows.net' - location: 'global' + name: 'privatelink.servicebus.windows.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource storageAccount 'Microsoft.Storage/storageAccounts@2022-05-01' = { - name: storageAccountName - location: location - sku: { - name: 'Standard_LRS' - } - kind: 'StorageV2' + name: storageAccountName + location: location + sku: { + name: 'Standard_LRS' + } + kind: 'StorageV2' } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/event-hub/namespace/.test/common/main.test.bicep b/modules/event-hub/namespace/.test/common/main.test.bicep index 9c7069c23f..14a778ca76 100644 --- a/modules/event-hub/namespace/.test/common/main.test.bicep +++ b/modules/event-hub/namespace/.test/common/main.test.bicep @@ -83,7 +83,6 @@ module testDeployment '../../main.bicep' = { ] } ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/event-hub/namespace/.test/encr/dependencies.bicep b/modules/event-hub/namespace/.test/encr/dependencies.bicep index e633816ab3..2c83533cb5 100644 --- a/modules/event-hub/namespace/.test/encr/dependencies.bicep +++ b/modules/event-hub/namespace/.test/encr/dependencies.bicep @@ -13,65 +13,65 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource keyVault 'Microsoft.KeyVault/vaults@2022-07-01' = { - name: keyVaultName - location: location - properties: { - sku: { - family: 'A' - name: 'standard' - } - tenantId: tenant().tenantId - enablePurgeProtection: true // Required by event hub namespace - softDeleteRetentionInDays: 7 - enabledForTemplateDeployment: true - enabledForDiskEncryption: true - enabledForDeployment: true - enableRbacAuthorization: true - accessPolicies: [] + name: keyVaultName + location: location + properties: { + sku: { + family: 'A' + name: 'standard' } + tenantId: tenant().tenantId + enablePurgeProtection: true // Required by event hub namespace + softDeleteRetentionInDays: 7 + enabledForTemplateDeployment: true + enabledForDiskEncryption: true + enabledForDeployment: true + enableRbacAuthorization: true + accessPolicies: [] + } - resource key 'keys@2022-07-01' = { - name: 'keyEncryptionKey' - properties: { - kty: 'RSA' - } + resource key 'keys@2022-07-01' = { + name: 'keyEncryptionKey' + properties: { + kty: 'RSA' } + } } resource keyPermissions 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid('msi-${keyVault::key.id}-${location}-${managedIdentity.id}-Key-Reader-RoleAssignment') - scope: keyVault::key - properties: { - principalId: managedIdentity.properties.principalId - // Key Vault Crypto User - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '12338af0-0e69-4776-bea7-57ae8d297424') - principalType: 'ServicePrincipal' - } + name: guid('msi-${keyVault::key.id}-${location}-${managedIdentity.id}-Key-Reader-RoleAssignment') + scope: keyVault::key + properties: { + principalId: managedIdentity.properties.principalId + // Key Vault Crypto User + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '12338af0-0e69-4776-bea7-57ae8d297424') + principalType: 'ServicePrincipal' + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/event-hub/namespace/.test/pe/dependencies.bicep b/modules/event-hub/namespace/.test/pe/dependencies.bicep index a5642c092a..fad0edce0d 100644 --- a/modules/event-hub/namespace/.test/pe/dependencies.bicep +++ b/modules/event-hub/namespace/.test/pe/dependencies.bicep @@ -6,45 +6,45 @@ param virtualNetworkName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] + } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + serviceEndpoints: [ { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - serviceEndpoints: [ - { - service: 'Microsoft.EventHub' - } - ] - } + service: 'Microsoft.EventHub' } - ] - } + ] + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.servicebus.windows.net' - location: 'global' + name: 'privatelink.servicebus.windows.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/event-hub/namespace/README.md b/modules/event-hub/namespace/README.md index 72dc8fbd40..7e094550a1 100644 --- a/modules/event-hub/namespace/README.md +++ b/modules/event-hub/namespace/README.md @@ -24,8 +24,8 @@ This module deploys an Event Hub Namespace. | `Microsoft.EventHub/namespaces/eventhubs/consumergroups` | [2022-01-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.EventHub/2022-01-01-preview/namespaces/eventhubs/consumergroups) | | `Microsoft.EventHub/namespaces/networkRuleSets` | [2022-01-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.EventHub/2022-01-01-preview/namespaces/networkRuleSets) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | ## Parameters @@ -52,7 +52,6 @@ This module deploys an Event Hub Namespace. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, ApplicationMetricsLogs, ArchiveLogs, AutoScaleLogs, CustomerManagedKeyUserLogs, EventHubVNetConnectionEvent, KafkaCoordinatorLogs, KafkaUserErrorLogs, OperationalLogs, RuntimeAuditLogs]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -370,7 +369,6 @@ module namespace './event-hub/namespace/main.bicep' = { ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' disableLocalAuth: true @@ -532,9 +530,6 @@ module namespace './event-hub/namespace/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/event-hub/namespace/authorization-rule/main.json b/modules/event-hub/namespace/authorization-rule/main.json index 0bda3db3de..edf5ee0c75 100644 --- a/modules/event-hub/namespace/authorization-rule/main.json +++ b/modules/event-hub/namespace/authorization-rule/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6503914993415142731" - } + "version": "0.20.4.51522", + "templateHash": "689013755293429510" + }, + "name": "Event Hub Namespace Authorization Rule", + "description": "This module deploys an Event Hub Namespace Authorization Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { diff --git a/modules/event-hub/namespace/disaster-recovery-config/main.json b/modules/event-hub/namespace/disaster-recovery-config/main.json index 60df62485e..b0f147b649 100644 --- a/modules/event-hub/namespace/disaster-recovery-config/main.json +++ b/modules/event-hub/namespace/disaster-recovery-config/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12261142567387877163" - } + "version": "0.20.4.51522", + "templateHash": "6638470700293836073" + }, + "name": "Event Hub Namespace Disaster Recovery Configs", + "description": "This module deploys an Event Hub Namespace Disaster Recovery Config.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { diff --git a/modules/event-hub/namespace/eventhub/authorization-rule/main.json b/modules/event-hub/namespace/eventhub/authorization-rule/main.json index 4031395e3d..52cd823720 100644 --- a/modules/event-hub/namespace/eventhub/authorization-rule/main.json +++ b/modules/event-hub/namespace/eventhub/authorization-rule/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14445239246751091520" - } + "version": "0.20.4.51522", + "templateHash": "12984183065402367529" + }, + "name": "Event Hub Namespace Event Hub Authorization Rules", + "description": "This module deploys an Event Hub Namespace Event Hub Authorization Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { diff --git a/modules/event-hub/namespace/eventhub/consumergroup/main.json b/modules/event-hub/namespace/eventhub/consumergroup/main.json index 5f73edaab9..4da93ab1ab 100644 --- a/modules/event-hub/namespace/eventhub/consumergroup/main.json +++ b/modules/event-hub/namespace/eventhub/consumergroup/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6857373991807692104" - } + "version": "0.20.4.51522", + "templateHash": "4223870259264150873" + }, + "name": "Event Hub Namespace Event Hub Consumer Groups", + "description": "This module deploys an Event Hub Namespace Event Hub Consumer Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { diff --git a/modules/event-hub/namespace/eventhub/main.json b/modules/event-hub/namespace/eventhub/main.json index a0ea3c37e2..623ef00653 100644 --- a/modules/event-hub/namespace/eventhub/main.json +++ b/modules/event-hub/namespace/eventhub/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3518513774222730388" - } + "version": "0.20.4.51522", + "templateHash": "443948940379129513" + }, + "name": "Event Hub Namespace Event Hubs", + "description": "This module deploys an Event Hub Namespace Event Hub.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { @@ -40,8 +43,8 @@ "messageRetentionInDays": { "type": "int", "defaultValue": 1, - "maxValue": 7, "minValue": 1, + "maxValue": 7, "metadata": { "description": "Optional. Number of days to retain the events for this Event Hub, value should be 1 to 7 days." } @@ -49,8 +52,8 @@ "partitionCount": { "type": "int", "defaultValue": 2, - "maxValue": 32, "minValue": 1, + "maxValue": 32, "metadata": { "description": "Optional. Number of partitions created for the Event Hub, allowed values are from 1 to 32 partitions." } @@ -87,14 +90,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -152,8 +155,8 @@ "captureDescriptionIntervalInSeconds": { "type": "int", "defaultValue": 300, - "maxValue": 900, "minValue": 60, + "maxValue": 900, "metadata": { "description": "Optional. The time window allows you to set the frequency with which the capture to Azure Blobs will happen." } @@ -161,8 +164,8 @@ "captureDescriptionSizeLimitInBytes": { "type": "int", "defaultValue": 314572800, - "maxValue": 524288000, "minValue": 10485760, + "maxValue": 524288000, "metadata": { "description": "Optional. The size window defines the amount of data built up in your Event Hub before an capture operation." } @@ -279,9 +282,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6857373991807692104" - } + "version": "0.20.4.51522", + "templateHash": "4223870259264150873" + }, + "name": "Event Hub Namespace Event Hub Consumer Groups", + "description": "This module deploys an Event Hub Namespace Event Hub Consumer Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { @@ -404,9 +410,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14445239246751091520" - } + "version": "0.20.4.51522", + "templateHash": "12984183065402367529" + }, + "name": "Event Hub Namespace Event Hub Authorization Rules", + "description": "This module deploys an Event Hub Namespace Event Hub Authorization Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { @@ -534,8 +543,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12158134836363662242" + "version": "0.20.4.51522", + "templateHash": "14745150939607150150" } }, "parameters": { diff --git a/modules/event-hub/namespace/main.bicep b/modules/event-hub/namespace/main.bicep index d87e07f38b..3bd583c6f8 100644 --- a/modules/event-hub/namespace/main.bicep +++ b/modules/event-hub/namespace/main.bicep @@ -74,11 +74,6 @@ param privateEndpoints array = [] @description('Optional. Configure networking options. This object contains IPs/Subnets to allow or restrict access to private endpoints only. For security reasons, it is recommended to configure this object on the Namespace.') param networkRuleSets object = {} -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -169,20 +164,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -190,10 +177,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var identityType = systemAssignedIdentity ? (!empty(userAssignedIdentities) ? 'SystemAssigned,UserAssigned' : 'SystemAssigned') : (!empty(userAssignedIdentities) ? 'UserAssigned' : 'None') diff --git a/modules/event-hub/namespace/main.json b/modules/event-hub/namespace/main.json index db25ac2115..eb66431aef 100644 --- a/modules/event-hub/namespace/main.json +++ b/modules/event-hub/namespace/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10213151462333101909" - } + "version": "0.20.4.51522", + "templateHash": "13452463340225550490" + }, + "name": "Event Hub Namespaces", + "description": "This module deploys an Event Hub Namespace.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -38,8 +41,8 @@ "skuCapacity": { "type": "int", "defaultValue": 1, - "maxValue": 20, "minValue": 1, + "maxValue": 20, "metadata": { "description": "Optional. The Event Hub's throughput units for Basic or Standard tiers, where value should be 0 to 20 throughput units. The Event Hubs premium units for Premium tier, where value should be 0 to 10 premium units." } @@ -61,8 +64,8 @@ "maximumThroughputUnits": { "type": "int", "defaultValue": 1, - "maxValue": 20, "minValue": 0, + "maxValue": 20, "metadata": { "description": "Optional. Upper limit of throughput units when AutoInflate is enabled, value should be within 0 to 20 throughput units." } @@ -100,14 +103,14 @@ "minimumTlsVersion": { "type": "string", "defaultValue": "1.2", - "metadata": { - "description": "Optional. The minimum TLS version for the cluster to support." - }, "allowedValues": [ "1.0", "1.1", "1.2" - ] + ], + "metadata": { + "description": "Optional. The minimum TLS version for the cluster to support." + } }, "publicNetworkAccess": { "type": "string", @@ -136,15 +139,6 @@ "description": "Optional. Configure networking options. This object contains IPs/Subnets to allow or restrict access to private endpoints only. For security reasons, it is recommended to configure this object on the Namespace." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -176,14 +170,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "systemAssignedIdentity": { "type": "bool", @@ -318,11 +312,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -331,16 +321,12 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], "maximumThroughputUnitsVar": "[if(not(parameters('isAutoInflateEnabled')), 0, parameters('maximumThroughputUnits'))]", - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "identityType": "[if(parameters('systemAssignedIdentity'), if(not(empty(parameters('userAssignedIdentities'))), 'SystemAssigned,UserAssigned', 'SystemAssigned'), if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None'))]", "identity": "[if(not(equals(variables('identityType'), 'None')), createObject('type', variables('identityType'), 'userAssignedIdentities', if(not(empty(parameters('userAssignedIdentities'))), parameters('userAssignedIdentities'), null())), null())]", "enableReferencedModulesTelemetry": false @@ -446,9 +432,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6503914993415142731" - } + "version": "0.20.4.51522", + "templateHash": "689013755293429510" + }, + "name": "Event Hub Namespace Authorization Rule", + "description": "This module deploys an Event Hub Namespace Authorization Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { @@ -564,9 +553,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12261142567387877163" - } + "version": "0.20.4.51522", + "templateHash": "6638470700293836073" + }, + "name": "Event Hub Namespace Disaster Recovery Configs", + "description": "This module deploys an Event Hub Namespace Disaster Recovery Config.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { @@ -695,9 +687,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3518513774222730388" - } + "version": "0.20.4.51522", + "templateHash": "443948940379129513" + }, + "name": "Event Hub Namespace Event Hubs", + "description": "This module deploys an Event Hub Namespace Event Hub.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { @@ -731,8 +726,8 @@ "messageRetentionInDays": { "type": "int", "defaultValue": 1, - "maxValue": 7, "minValue": 1, + "maxValue": 7, "metadata": { "description": "Optional. Number of days to retain the events for this Event Hub, value should be 1 to 7 days." } @@ -740,8 +735,8 @@ "partitionCount": { "type": "int", "defaultValue": 2, - "maxValue": 32, "minValue": 1, + "maxValue": 32, "metadata": { "description": "Optional. Number of partitions created for the Event Hub, allowed values are from 1 to 32 partitions." } @@ -778,14 +773,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -843,8 +838,8 @@ "captureDescriptionIntervalInSeconds": { "type": "int", "defaultValue": 300, - "maxValue": 900, "minValue": 60, + "maxValue": 900, "metadata": { "description": "Optional. The time window allows you to set the frequency with which the capture to Azure Blobs will happen." } @@ -852,8 +847,8 @@ "captureDescriptionSizeLimitInBytes": { "type": "int", "defaultValue": 314572800, - "maxValue": 524288000, "minValue": 10485760, + "maxValue": 524288000, "metadata": { "description": "Optional. The size window defines the amount of data built up in your Event Hub before an capture operation." } @@ -970,9 +965,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6857373991807692104" - } + "version": "0.20.4.51522", + "templateHash": "4223870259264150873" + }, + "name": "Event Hub Namespace Event Hub Consumer Groups", + "description": "This module deploys an Event Hub Namespace Event Hub Consumer Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { @@ -1095,9 +1093,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14445239246751091520" - } + "version": "0.20.4.51522", + "templateHash": "12984183065402367529" + }, + "name": "Event Hub Namespace Event Hub Authorization Rules", + "description": "This module deploys an Event Hub Namespace Event Hub Authorization Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { @@ -1225,8 +1226,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12158134836363662242" + "version": "0.20.4.51522", + "templateHash": "14745150939607150150" } }, "parameters": { @@ -1410,9 +1411,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15545902637890611885" - } + "version": "0.20.4.51522", + "templateHash": "2572752048492506478" + }, + "name": "Event Hub Namespace Network Rule Sets", + "description": "This module deploys an Event Hub Namespace Network Rule Set.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { @@ -1424,24 +1428,24 @@ "publicNetworkAccess": { "type": "string", "defaultValue": "Enabled", - "metadata": { - "description": "Optional. This determines if traffic is allowed over public network. Default is \"Enabled\". If set to \"Disabled\", traffic to this namespace will be restricted over Private Endpoints only and network rules will not be applied." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. This determines if traffic is allowed over public network. Default is \"Enabled\". If set to \"Disabled\", traffic to this namespace will be restricted over Private Endpoints only and network rules will not be applied." + } }, "defaultAction": { "type": "string", "defaultValue": "Allow", - "metadata": { - "description": "Optional. Default Action for Network Rule Set. Default is \"Allow\". It will not be set if publicNetworkAccess is \"Disabled\". Otherwise, it will be set to \"Deny\" if ipRules or virtualNetworkRules are being used." - }, "allowedValues": [ "Allow", "Deny" - ] + ], + "metadata": { + "description": "Optional. Default Action for Network Rule Set. Default is \"Allow\". It will not be set if publicNetworkAccess is \"Disabled\". Otherwise, it will be set to \"Deny\" if ipRules or virtualNetworkRules are being used." + } }, "trustedServiceAccessEnabled": { "type": "bool", @@ -1589,9 +1593,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1656,14 +1663,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -1721,7 +1728,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -1786,9 +1793,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -1799,8 +1809,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -1851,7 +1861,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -1921,8 +1931,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -2092,7 +2102,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -2135,8 +2145,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17034984261540376802" + "version": "0.20.4.51522", + "templateHash": "4105980417580811499" } }, "parameters": { diff --git a/modules/event-hub/namespace/network-rule-set/main.json b/modules/event-hub/namespace/network-rule-set/main.json index 7a03dca7ca..a83b70e250 100644 --- a/modules/event-hub/namespace/network-rule-set/main.json +++ b/modules/event-hub/namespace/network-rule-set/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15545902637890611885" - } + "version": "0.20.4.51522", + "templateHash": "2572752048492506478" + }, + "name": "Event Hub Namespace Network Rule Sets", + "description": "This module deploys an Event Hub Namespace Network Rule Set.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { @@ -18,24 +21,24 @@ "publicNetworkAccess": { "type": "string", "defaultValue": "Enabled", - "metadata": { - "description": "Optional. This determines if traffic is allowed over public network. Default is \"Enabled\". If set to \"Disabled\", traffic to this namespace will be restricted over Private Endpoints only and network rules will not be applied." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. This determines if traffic is allowed over public network. Default is \"Enabled\". If set to \"Disabled\", traffic to this namespace will be restricted over Private Endpoints only and network rules will not be applied." + } }, "defaultAction": { "type": "string", "defaultValue": "Allow", - "metadata": { - "description": "Optional. Default Action for Network Rule Set. Default is \"Allow\". It will not be set if publicNetworkAccess is \"Disabled\". Otherwise, it will be set to \"Deny\" if ipRules or virtualNetworkRules are being used." - }, "allowedValues": [ "Allow", "Deny" - ] + ], + "metadata": { + "description": "Optional. Default Action for Network Rule Set. Default is \"Allow\". It will not be set if publicNetworkAccess is \"Disabled\". Otherwise, it will be set to \"Deny\" if ipRules or virtualNetworkRules are being used." + } }, "trustedServiceAccessEnabled": { "type": "bool", diff --git a/modules/health-bot/health-bot/main.json b/modules/health-bot/health-bot/main.json index 08645af7d5..87c7891ad5 100644 --- a/modules/health-bot/health-bot/main.json +++ b/modules/health-bot/health-bot/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "596039493256474889" - } + "version": "0.20.4.51522", + "templateHash": "11057494810956244402" + }, + "name": "Azure Health Bots", + "description": "This module deploys an Azure Health Bot.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -17,14 +20,14 @@ }, "sku": { "type": "string", - "metadata": { - "description": "Required. The name of the Azure Health Bot SKU." - }, "allowedValues": [ "C0", "F0", "S1" - ] + ], + "metadata": { + "description": "Required. The name of the Azure Health Bot SKU." + } }, "userAssignedIdentities": { "type": "object", @@ -43,14 +46,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -153,8 +156,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5579132809486468278" + "version": "0.20.4.51522", + "templateHash": "4578446478829376129" } }, "parameters": { diff --git a/modules/healthcare-apis/workspace/.test/common/main.test.bicep b/modules/healthcare-apis/workspace/.test/common/main.test.bicep index be3dd87f8f..97b443e50b 100644 --- a/modules/healthcare-apis/workspace/.test/common/main.test.bicep +++ b/modules/healthcare-apis/workspace/.test/common/main.test.bicep @@ -79,7 +79,6 @@ module testDeployment '../../main.bicep' = { corsMaxAge: 600 corsAllowCredentials: false location: location - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId @@ -115,7 +114,6 @@ module testDeployment '../../main.bicep' = { corsMaxAge: 600 corsAllowCredentials: false location: location - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/healthcare-apis/workspace/README.md b/modules/healthcare-apis/workspace/README.md index c1eea8d1d8..cd1fffafdc 100644 --- a/modules/healthcare-apis/workspace/README.md +++ b/modules/healthcare-apis/workspace/README.md @@ -67,7 +67,6 @@ Create a FHIR service with the workspace. "corsMaxAge": 600, "corsAllowCredentials": false, "location": "[[location]]", - "diagnosticLogsRetentionInDays": 7, "diagnosticStorageAccountId": "[[storageAccountResourceId]]", "diagnosticWorkspaceId": "[[logAnalyticsWorkspaceResourceId]]", "diagnosticEventHubAuthorizationRuleId": "[[eventHubAuthorizationRuleId]]", @@ -114,7 +113,6 @@ fhirServices: [ corsMaxAge: 600 corsAllowCredentials: false location: location - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId @@ -165,7 +163,6 @@ Create a DICOM service with the workspace. "corsMaxAge": 600, "corsAllowCredentials": false, "location": "[[location]]", - "diagnosticLogsRetentionInDays": 7, "diagnosticStorageAccountId": "[[storageAccountResourceId]]", "diagnosticWorkspaceId": "[[logAnalyticsWorkspaceResourceId]]", "diagnosticEventHubAuthorizationRuleId": "[[eventHubAuthorizationRuleId]]", @@ -198,7 +195,6 @@ dicomServices: [ corsMaxAge: 600 corsAllowCredentials: false location: location - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId @@ -236,7 +232,6 @@ Create an IOT Connector (MedTech) service with the workspace. "corsMaxAge": 600, "corsAllowCredentials": false, "location": "[[location]]", - "diagnosticLogsRetentionInDays": 7, "diagnosticStorageAccountId": "[[storageAccountResourceId]]", "diagnosticWorkspaceId": "[[logAnalyticsWorkspaceResourceId]]", "diagnosticEventHubAuthorizationRuleId": "[[eventHubAuthorizationRuleId]]", @@ -275,7 +270,6 @@ iotConnectors: [ corsMaxAge: 600 corsAllowCredentials: false location: location - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId @@ -447,7 +441,6 @@ module workspace './healthcare-apis/workspace/main.bicep' = { ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -477,7 +470,6 @@ module workspace './healthcare-apis/workspace/main.bicep' = { ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -549,7 +541,6 @@ module workspace './healthcare-apis/workspace/main.bicep' = { ], "diagnosticEventHubAuthorizationRuleId": "", "diagnosticEventHubName": "", - "diagnosticLogsRetentionInDays": 7, "diagnosticStorageAccountId": "", "diagnosticWorkspaceId": "", "enableDefaultTelemetry": "", @@ -583,7 +574,6 @@ module workspace './healthcare-apis/workspace/main.bicep' = { ], "diagnosticEventHubAuthorizationRuleId": "", "diagnosticEventHubName": "", - "diagnosticLogsRetentionInDays": 7, "diagnosticStorageAccountId": "", "diagnosticWorkspaceId": "", "enableDefaultTelemetry": "", diff --git a/modules/healthcare-apis/workspace/dicomservice/README.md b/modules/healthcare-apis/workspace/dicomservice/README.md index e564c4c9f1..222a4334f9 100644 --- a/modules/healthcare-apis/workspace/dicomservice/README.md +++ b/modules/healthcare-apis/workspace/dicomservice/README.md @@ -43,7 +43,6 @@ This module deploys a Healthcare API Workspace DICOM Service. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[AuditLogs]` | `[AuditLogs]` | The name of logs that will be streamed. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | | `diagnosticWorkspaceId` | string | `''` | | Resource ID of the diagnostic log analytics workspace. | diff --git a/modules/healthcare-apis/workspace/dicomservice/main.bicep b/modules/healthcare-apis/workspace/dicomservice/main.bicep index 50defd0c9e..b15727ce45 100644 --- a/modules/healthcare-apis/workspace/dicomservice/main.bicep +++ b/modules/healthcare-apis/workspace/dicomservice/main.bicep @@ -35,11 +35,6 @@ param corsAllowCredentials bool = false @description('Optional. Location for all resources.') param location string = resourceGroup().location -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -93,10 +88,6 @@ param diagnosticSettingsName string = '' var diagnosticsLogs = [for category in diagnosticLogCategoriesToEnable: { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var identityType = systemAssignedIdentity ? (!empty(userAssignedIdentities) ? 'SystemAssigned,UserAssigned' : 'SystemAssigned') : (!empty(userAssignedIdentities) ? 'UserAssigned' : 'None') diff --git a/modules/healthcare-apis/workspace/dicomservice/main.json b/modules/healthcare-apis/workspace/dicomservice/main.json index 56760b2b0b..e9d301126e 100644 --- a/modules/healthcare-apis/workspace/dicomservice/main.json +++ b/modules/healthcare-apis/workspace/dicomservice/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2439060324976899647" - } + "version": "0.20.4.51522", + "templateHash": "13236257936604632093" + }, + "name": "Healthcare API Workspace DICOM Services", + "description": "This module deploys a Healthcare API Workspace DICOM Service.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -39,9 +42,6 @@ "corsMethods": { "type": "array", "defaultValue": [], - "metadata": { - "description": "Optional. Specify the allowed HTTP methods." - }, "allowedValues": [ "DELETE", "GET", @@ -49,7 +49,10 @@ "PATCH", "POST", "PUT" - ] + ], + "metadata": { + "description": "Optional. Specify the allowed HTTP methods." + } }, "corsMaxAge": { "type": "int", @@ -72,15 +75,6 @@ "description": "Optional. Location for all resources." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -112,25 +106,25 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "publicNetworkAccess": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Control permission for data plane traffic coming from public networks while private endpoint is enabled." - }, "allowedValues": [ "Disabled", "Enabled" - ] + ], + "metadata": { + "description": "Optional. Control permission for data plane traffic coming from public networks while private endpoint is enabled." + } }, "systemAssignedIdentity": { "type": "bool", @@ -187,11 +181,7 @@ "count": "[length(parameters('diagnosticLogCategoriesToEnable'))]", "input": { "category": "[parameters('diagnosticLogCategoriesToEnable')[copyIndex('diagnosticsLogs')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], diff --git a/modules/healthcare-apis/workspace/fhirservice/README.md b/modules/healthcare-apis/workspace/fhirservice/README.md index 8f6f39b84d..2a83d83637 100644 --- a/modules/healthcare-apis/workspace/fhirservice/README.md +++ b/modules/healthcare-apis/workspace/fhirservice/README.md @@ -49,7 +49,6 @@ This module deploys a Healthcare API Workspace FHIR Service. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[AuditLogs]` | `[AuditLogs]` | The name of logs that will be streamed. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | diff --git a/modules/healthcare-apis/workspace/fhirservice/main.bicep b/modules/healthcare-apis/workspace/fhirservice/main.bicep index bef3c2814e..f724cbe5a0 100644 --- a/modules/healthcare-apis/workspace/fhirservice/main.bicep +++ b/modules/healthcare-apis/workspace/fhirservice/main.bicep @@ -57,11 +57,6 @@ param corsAllowCredentials bool = false @description('Optional. Location for all resources.') param location string = resourceGroup().location -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -152,20 +147,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogs = [for category in diagnosticLogCategoriesToEnable: { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var identityType = systemAssignedIdentity ? (!empty(userAssignedIdentities) ? 'SystemAssigned,UserAssigned' : 'SystemAssigned') : (!empty(userAssignedIdentities) ? 'UserAssigned' : 'None') diff --git a/modules/healthcare-apis/workspace/fhirservice/main.json b/modules/healthcare-apis/workspace/fhirservice/main.json index d28c9e35b1..33998d37da 100644 --- a/modules/healthcare-apis/workspace/fhirservice/main.json +++ b/modules/healthcare-apis/workspace/fhirservice/main.json @@ -4,28 +4,31 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13041396315414383570" - } + "version": "0.20.4.51522", + "templateHash": "3716031618750035294" + }, + "name": "Healthcare API Workspace FHIR Services", + "description": "This module deploys a Healthcare API Workspace FHIR Service.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { "type": "string", + "maxLength": 50, "metadata": { "description": "Required. The name of the FHIR service." - }, - "maxLength": 50 + } }, "kind": { "type": "string", "defaultValue": "fhir-R4", - "metadata": { - "description": "Optional. The kind of the service. Defaults to R4." - }, "allowedValues": [ "fhir-R4", "fhir-Stu3" - ] + ], + "metadata": { + "description": "Optional. The kind of the service. Defaults to R4." + } }, "workspaceName": { "type": "string", @@ -85,9 +88,6 @@ "corsMethods": { "type": "array", "defaultValue": [], - "metadata": { - "description": "Optional. Specify the allowed HTTP methods." - }, "allowedValues": [ "DELETE", "GET", @@ -95,7 +95,10 @@ "PATCH", "POST", "PUT" - ] + ], + "metadata": { + "description": "Optional. Specify the allowed HTTP methods." + } }, "corsMaxAge": { "type": "int", @@ -118,15 +121,6 @@ "description": "Optional. Location for all resources." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -186,14 +180,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -205,25 +199,25 @@ "publicNetworkAccess": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Control permission for data plane traffic coming from public networks while private endpoint is enabled." - }, "allowedValues": [ "Disabled", "Enabled" - ] + ], + "metadata": { + "description": "Optional. Control permission for data plane traffic coming from public networks while private endpoint is enabled." + } }, "resourceVersionPolicy": { "type": "string", "defaultValue": "versioned", - "metadata": { - "description": "Optional. The default value for tracking history across all resources." - }, "allowedValues": [ "no-version", "versioned", "versioned-update" - ] + ], + "metadata": { + "description": "Optional. The default value for tracking history across all resources." + } }, "resourceVersionOverrides": { "type": "object", @@ -272,24 +266,24 @@ "defaultValue": [ "AuditLogs" ], - "metadata": { - "description": "Optional. The name of logs that will be streamed." - }, "allowedValues": [ "AuditLogs" - ] + ], + "metadata": { + "description": "Optional. The name of logs that will be streamed." + } }, "diagnosticMetricsToEnable": { "type": "array", "defaultValue": [ "AllMetrics" ], - "metadata": { - "description": "Optional. The name of metrics that will be streamed." - }, "allowedValues": [ "AllMetrics" - ] + ], + "metadata": { + "description": "Optional. The name of metrics that will be streamed." + } }, "diagnosticSettingsName": { "type": "string", @@ -306,11 +300,7 @@ "count": "[length(parameters('diagnosticLogCategoriesToEnable'))]", "input": { "category": "[parameters('diagnosticLogCategoriesToEnable')[copyIndex('diagnosticsLogs')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -319,11 +309,7 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -460,8 +446,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12959461194377825397" + "version": "0.20.4.51522", + "templateHash": "13975136606830731755" } }, "parameters": { diff --git a/modules/healthcare-apis/workspace/iotconnector/README.md b/modules/healthcare-apis/workspace/iotconnector/README.md index 5367007d20..5ff70e2024 100644 --- a/modules/healthcare-apis/workspace/iotconnector/README.md +++ b/modules/healthcare-apis/workspace/iotconnector/README.md @@ -43,7 +43,6 @@ This module deploys a Healthcare API Workspace IoT Connector. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[DiagnosticLogs]` | `[DiagnosticLogs]` | The name of logs that will be streamed. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | diff --git a/modules/healthcare-apis/workspace/iotconnector/fhirdestination/main.json b/modules/healthcare-apis/workspace/iotconnector/fhirdestination/main.json index 88f3928e74..b48bcb3727 100644 --- a/modules/healthcare-apis/workspace/iotconnector/fhirdestination/main.json +++ b/modules/healthcare-apis/workspace/iotconnector/fhirdestination/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5625257407409224246" - } + "version": "0.20.4.51522", + "templateHash": "18442235072798053221" + }, + "name": "Healthcare API Workspace IoT Connector FHIR Destinations", + "description": "This module deploys a Healthcare API Workspace IoT Connector FHIR Destination.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -61,13 +64,13 @@ "resourceIdentityResolutionType": { "type": "string", "defaultValue": "Lookup", - "metadata": { - "description": "Optional. Determines how resource identity is resolved on the destination." - }, "allowedValues": [ "Create", "Lookup" - ] + ], + "metadata": { + "description": "Optional. Determines how resource identity is resolved on the destination." + } } }, "resources": [ diff --git a/modules/healthcare-apis/workspace/iotconnector/main.bicep b/modules/healthcare-apis/workspace/iotconnector/main.bicep index 0f18338e21..137108bd31 100644 --- a/modules/healthcare-apis/workspace/iotconnector/main.bicep +++ b/modules/healthcare-apis/workspace/iotconnector/main.bicep @@ -30,11 +30,6 @@ param fhirdestination object = {} @description('Optional. Location for all resources.') param location string = resourceGroup().location -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -89,20 +84,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogs = [for category in diagnosticLogCategoriesToEnable: { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var identityType = systemAssignedIdentity ? (!empty(userAssignedIdentities) ? 'SystemAssigned,UserAssigned' : 'SystemAssigned') : (!empty(userAssignedIdentities) ? 'UserAssigned' : 'None') diff --git a/modules/healthcare-apis/workspace/iotconnector/main.json b/modules/healthcare-apis/workspace/iotconnector/main.json index 5258774222..63bb75e273 100644 --- a/modules/healthcare-apis/workspace/iotconnector/main.json +++ b/modules/healthcare-apis/workspace/iotconnector/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1832587141900709980" - } + "version": "0.20.4.51522", + "templateHash": "16981578699165858107" + }, + "name": "Healthcare API Workspace IoT Connectors", + "description": "This module deploys a Healthcare API Workspace IoT Connector.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -65,15 +68,6 @@ "description": "Optional. Location for all resources." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -105,14 +99,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "systemAssignedIdentity": { "type": "bool", @@ -181,11 +175,7 @@ "count": "[length(parameters('diagnosticLogCategoriesToEnable'))]", "input": { "category": "[parameters('diagnosticLogCategoriesToEnable')[copyIndex('diagnosticsLogs')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -194,11 +184,7 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], @@ -309,9 +295,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5625257407409224246" - } + "version": "0.20.4.51522", + "templateHash": "18442235072798053221" + }, + "name": "Healthcare API Workspace IoT Connector FHIR Destinations", + "description": "This module deploys a Healthcare API Workspace IoT Connector FHIR Destination.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -366,13 +355,13 @@ "resourceIdentityResolutionType": { "type": "string", "defaultValue": "Lookup", - "metadata": { - "description": "Optional. Determines how resource identity is resolved on the destination." - }, "allowedValues": [ "Create", "Lookup" - ] + ], + "metadata": { + "description": "Optional. Determines how resource identity is resolved on the destination." + } } }, "resources": [ diff --git a/modules/healthcare-apis/workspace/main.bicep b/modules/healthcare-apis/workspace/main.bicep index 2157ab87e5..00251abaca 100644 --- a/modules/healthcare-apis/workspace/main.bicep +++ b/modules/healthcare-apis/workspace/main.bicep @@ -111,7 +111,6 @@ module workspace_fhirservices 'fhirservice/main.bicep' = [for (fhir, index) in f corsMethods: contains(fhir, 'corsMethods') ? fhir.corsMethods : [] corsMaxAge: contains(fhir, 'corsMaxAge') ? fhir.corsMaxAge : -1 corsAllowCredentials: contains(fhir, 'corsAllowCredentials') ? fhir.corsAllowCredentials : false - diagnosticLogsRetentionInDays: contains(fhir, 'diagnosticLogsRetentionInDays') ? fhir.diagnosticLogsRetentionInDays : 365 diagnosticStorageAccountId: contains(fhir, 'diagnosticStorageAccountId') ? fhir.diagnosticStorageAccountId : '' diagnosticWorkspaceId: contains(fhir, 'diagnosticWorkspaceId') ? fhir.diagnosticWorkspaceId : '' diagnosticEventHubAuthorizationRuleId: contains(fhir, 'diagnosticEventHubAuthorizationRuleId') ? fhir.diagnosticEventHubAuthorizationRuleId : '' @@ -145,7 +144,6 @@ module workspace_dicomservices 'dicomservice/main.bicep' = [for (dicom, index) i corsMethods: contains(dicom, 'corsMethods') ? dicom.corsMethods : [] corsMaxAge: contains(dicom, 'corsMaxAge') ? dicom.corsMaxAge : -1 corsAllowCredentials: contains(dicom, 'corsAllowCredentials') ? dicom.corsAllowCredentials : false - diagnosticLogsRetentionInDays: contains(dicom, 'diagnosticLogsRetentionInDays') ? dicom.diagnosticLogsRetentionInDays : 365 diagnosticStorageAccountId: contains(dicom, 'diagnosticStorageAccountId') ? dicom.diagnosticStorageAccountId : '' diagnosticWorkspaceId: contains(dicom, 'diagnosticWorkspaceId') ? dicom.diagnosticWorkspaceId : '' diagnosticEventHubAuthorizationRuleId: contains(dicom, 'diagnosticEventHubAuthorizationRuleId') ? dicom.diagnosticEventHubAuthorizationRuleId : '' @@ -173,7 +171,6 @@ module workspace_iotconnector 'iotconnector/main.bicep' = [for (iotConnector, in fhirdestination: contains(iotConnector, 'fhirdestination') ? iotConnector.fhirdestination : {} consumerGroup: contains(iotConnector, 'consumerGroup') ? iotConnector.consumerGroup : iotConnector.name systemAssignedIdentity: contains(iotConnector, 'systemAssignedIdentity') ? iotConnector.systemAssignedIdentity : false - diagnosticLogsRetentionInDays: contains(iotConnector, 'diagnosticLogsRetentionInDays') ? iotConnector.diagnosticLogsRetentionInDays : 365 diagnosticStorageAccountId: contains(iotConnector, 'diagnosticStorageAccountId') ? iotConnector.diagnosticStorageAccountId : '' diagnosticWorkspaceId: contains(iotConnector, 'diagnosticWorkspaceId') ? iotConnector.diagnosticWorkspaceId : '' diagnosticEventHubAuthorizationRuleId: contains(iotConnector, 'diagnosticEventHubAuthorizationRuleId') ? iotConnector.diagnosticEventHubAuthorizationRuleId : '' diff --git a/modules/healthcare-apis/workspace/main.json b/modules/healthcare-apis/workspace/main.json index 140befe992..a680566afe 100644 --- a/modules/healthcare-apis/workspace/main.json +++ b/modules/healthcare-apis/workspace/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6402048725621026089" - } + "version": "0.20.4.51522", + "templateHash": "8975971845190410186" + }, + "name": "Healthcare API Workspaces", + "description": "This module deploys a Healthcare API Workspace.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -26,14 +29,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -45,13 +48,13 @@ "publicNetworkAccess": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Control permission for data plane traffic coming from public networks while private endpoint is enabled." - }, "allowedValues": [ "Disabled", "Enabled" - ] + ], + "metadata": { + "description": "Optional. Control permission for data plane traffic coming from public networks while private endpoint is enabled." + } }, "tags": { "type": "object", @@ -165,8 +168,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "761636189970295993" + "version": "0.20.4.51522", + "templateHash": "13579581223684332874" } }, "parameters": { @@ -328,7 +331,6 @@ "corsMethods": "[if(contains(parameters('fhirservices')[copyIndex()], 'corsMethods'), createObject('value', parameters('fhirservices')[copyIndex()].corsMethods), createObject('value', createArray()))]", "corsMaxAge": "[if(contains(parameters('fhirservices')[copyIndex()], 'corsMaxAge'), createObject('value', parameters('fhirservices')[copyIndex()].corsMaxAge), createObject('value', -1))]", "corsAllowCredentials": "[if(contains(parameters('fhirservices')[copyIndex()], 'corsAllowCredentials'), createObject('value', parameters('fhirservices')[copyIndex()].corsAllowCredentials), createObject('value', false()))]", - "diagnosticLogsRetentionInDays": "[if(contains(parameters('fhirservices')[copyIndex()], 'diagnosticLogsRetentionInDays'), createObject('value', parameters('fhirservices')[copyIndex()].diagnosticLogsRetentionInDays), createObject('value', 365))]", "diagnosticStorageAccountId": "[if(contains(parameters('fhirservices')[copyIndex()], 'diagnosticStorageAccountId'), createObject('value', parameters('fhirservices')[copyIndex()].diagnosticStorageAccountId), createObject('value', ''))]", "diagnosticWorkspaceId": "[if(contains(parameters('fhirservices')[copyIndex()], 'diagnosticWorkspaceId'), createObject('value', parameters('fhirservices')[copyIndex()].diagnosticWorkspaceId), createObject('value', ''))]", "diagnosticEventHubAuthorizationRuleId": "[if(contains(parameters('fhirservices')[copyIndex()], 'diagnosticEventHubAuthorizationRuleId'), createObject('value', parameters('fhirservices')[copyIndex()].diagnosticEventHubAuthorizationRuleId), createObject('value', ''))]", @@ -354,28 +356,31 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13041396315414383570" - } + "version": "0.20.4.51522", + "templateHash": "3716031618750035294" + }, + "name": "Healthcare API Workspace FHIR Services", + "description": "This module deploys a Healthcare API Workspace FHIR Service.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { "type": "string", + "maxLength": 50, "metadata": { "description": "Required. The name of the FHIR service." - }, - "maxLength": 50 + } }, "kind": { "type": "string", "defaultValue": "fhir-R4", - "metadata": { - "description": "Optional. The kind of the service. Defaults to R4." - }, "allowedValues": [ "fhir-R4", "fhir-Stu3" - ] + ], + "metadata": { + "description": "Optional. The kind of the service. Defaults to R4." + } }, "workspaceName": { "type": "string", @@ -435,9 +440,6 @@ "corsMethods": { "type": "array", "defaultValue": [], - "metadata": { - "description": "Optional. Specify the allowed HTTP methods." - }, "allowedValues": [ "DELETE", "GET", @@ -445,7 +447,10 @@ "PATCH", "POST", "PUT" - ] + ], + "metadata": { + "description": "Optional. Specify the allowed HTTP methods." + } }, "corsMaxAge": { "type": "int", @@ -468,15 +473,6 @@ "description": "Optional. Location for all resources." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -536,14 +532,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -555,25 +551,25 @@ "publicNetworkAccess": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Control permission for data plane traffic coming from public networks while private endpoint is enabled." - }, "allowedValues": [ "Disabled", "Enabled" - ] + ], + "metadata": { + "description": "Optional. Control permission for data plane traffic coming from public networks while private endpoint is enabled." + } }, "resourceVersionPolicy": { "type": "string", "defaultValue": "versioned", - "metadata": { - "description": "Optional. The default value for tracking history across all resources." - }, "allowedValues": [ "no-version", "versioned", "versioned-update" - ] + ], + "metadata": { + "description": "Optional. The default value for tracking history across all resources." + } }, "resourceVersionOverrides": { "type": "object", @@ -622,24 +618,24 @@ "defaultValue": [ "AuditLogs" ], - "metadata": { - "description": "Optional. The name of logs that will be streamed." - }, "allowedValues": [ "AuditLogs" - ] + ], + "metadata": { + "description": "Optional. The name of logs that will be streamed." + } }, "diagnosticMetricsToEnable": { "type": "array", "defaultValue": [ "AllMetrics" ], - "metadata": { - "description": "Optional. The name of metrics that will be streamed." - }, "allowedValues": [ "AllMetrics" - ] + ], + "metadata": { + "description": "Optional. The name of metrics that will be streamed." + } }, "diagnosticSettingsName": { "type": "string", @@ -656,11 +652,7 @@ "count": "[length(parameters('diagnosticLogCategoriesToEnable'))]", "input": { "category": "[parameters('diagnosticLogCategoriesToEnable')[copyIndex('diagnosticsLogs')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -669,11 +661,7 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -810,8 +798,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12959461194377825397" + "version": "0.20.4.51522", + "templateHash": "13975136606830731755" } }, "parameters": { @@ -1015,7 +1003,6 @@ "corsMethods": "[if(contains(parameters('dicomservices')[copyIndex()], 'corsMethods'), createObject('value', parameters('dicomservices')[copyIndex()].corsMethods), createObject('value', createArray()))]", "corsMaxAge": "[if(contains(parameters('dicomservices')[copyIndex()], 'corsMaxAge'), createObject('value', parameters('dicomservices')[copyIndex()].corsMaxAge), createObject('value', -1))]", "corsAllowCredentials": "[if(contains(parameters('dicomservices')[copyIndex()], 'corsAllowCredentials'), createObject('value', parameters('dicomservices')[copyIndex()].corsAllowCredentials), createObject('value', false()))]", - "diagnosticLogsRetentionInDays": "[if(contains(parameters('dicomservices')[copyIndex()], 'diagnosticLogsRetentionInDays'), createObject('value', parameters('dicomservices')[copyIndex()].diagnosticLogsRetentionInDays), createObject('value', 365))]", "diagnosticStorageAccountId": "[if(contains(parameters('dicomservices')[copyIndex()], 'diagnosticStorageAccountId'), createObject('value', parameters('dicomservices')[copyIndex()].diagnosticStorageAccountId), createObject('value', ''))]", "diagnosticWorkspaceId": "[if(contains(parameters('dicomservices')[copyIndex()], 'diagnosticWorkspaceId'), createObject('value', parameters('dicomservices')[copyIndex()].diagnosticWorkspaceId), createObject('value', ''))]", "diagnosticEventHubAuthorizationRuleId": "[if(contains(parameters('dicomservices')[copyIndex()], 'diagnosticEventHubAuthorizationRuleId'), createObject('value', parameters('dicomservices')[copyIndex()].diagnosticEventHubAuthorizationRuleId), createObject('value', ''))]", @@ -1033,9 +1020,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2439060324976899647" - } + "version": "0.20.4.51522", + "templateHash": "13236257936604632093" + }, + "name": "Healthcare API Workspace DICOM Services", + "description": "This module deploys a Healthcare API Workspace DICOM Service.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1068,9 +1058,6 @@ "corsMethods": { "type": "array", "defaultValue": [], - "metadata": { - "description": "Optional. Specify the allowed HTTP methods." - }, "allowedValues": [ "DELETE", "GET", @@ -1078,7 +1065,10 @@ "PATCH", "POST", "PUT" - ] + ], + "metadata": { + "description": "Optional. Specify the allowed HTTP methods." + } }, "corsMaxAge": { "type": "int", @@ -1101,15 +1091,6 @@ "description": "Optional. Location for all resources." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -1141,25 +1122,25 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "publicNetworkAccess": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. Control permission for data plane traffic coming from public networks while private endpoint is enabled." - }, "allowedValues": [ "Disabled", "Enabled" - ] + ], + "metadata": { + "description": "Optional. Control permission for data plane traffic coming from public networks while private endpoint is enabled." + } }, "systemAssignedIdentity": { "type": "bool", @@ -1216,11 +1197,7 @@ "count": "[length(parameters('diagnosticLogCategoriesToEnable'))]", "input": { "category": "[parameters('diagnosticLogCategoriesToEnable')[copyIndex('diagnosticsLogs')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], @@ -1370,7 +1347,6 @@ "fhirdestination": "[if(contains(parameters('iotconnectors')[copyIndex()], 'fhirdestination'), createObject('value', parameters('iotconnectors')[copyIndex()].fhirdestination), createObject('value', createObject()))]", "consumerGroup": "[if(contains(parameters('iotconnectors')[copyIndex()], 'consumerGroup'), createObject('value', parameters('iotconnectors')[copyIndex()].consumerGroup), createObject('value', parameters('iotconnectors')[copyIndex()].name))]", "systemAssignedIdentity": "[if(contains(parameters('iotconnectors')[copyIndex()], 'systemAssignedIdentity'), createObject('value', parameters('iotconnectors')[copyIndex()].systemAssignedIdentity), createObject('value', false()))]", - "diagnosticLogsRetentionInDays": "[if(contains(parameters('iotconnectors')[copyIndex()], 'diagnosticLogsRetentionInDays'), createObject('value', parameters('iotconnectors')[copyIndex()].diagnosticLogsRetentionInDays), createObject('value', 365))]", "diagnosticStorageAccountId": "[if(contains(parameters('iotconnectors')[copyIndex()], 'diagnosticStorageAccountId'), createObject('value', parameters('iotconnectors')[copyIndex()].diagnosticStorageAccountId), createObject('value', ''))]", "diagnosticWorkspaceId": "[if(contains(parameters('iotconnectors')[copyIndex()], 'diagnosticWorkspaceId'), createObject('value', parameters('iotconnectors')[copyIndex()].diagnosticWorkspaceId), createObject('value', ''))]", "diagnosticEventHubAuthorizationRuleId": "[if(contains(parameters('iotconnectors')[copyIndex()], 'diagnosticEventHubAuthorizationRuleId'), createObject('value', parameters('iotconnectors')[copyIndex()].diagnosticEventHubAuthorizationRuleId), createObject('value', ''))]", @@ -1389,9 +1365,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1832587141900709980" - } + "version": "0.20.4.51522", + "templateHash": "16981578699165858107" + }, + "name": "Healthcare API Workspace IoT Connectors", + "description": "This module deploys a Healthcare API Workspace IoT Connector.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1450,15 +1429,6 @@ "description": "Optional. Location for all resources." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -1490,14 +1460,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "systemAssignedIdentity": { "type": "bool", @@ -1566,11 +1536,7 @@ "count": "[length(parameters('diagnosticLogCategoriesToEnable'))]", "input": { "category": "[parameters('diagnosticLogCategoriesToEnable')[copyIndex('diagnosticsLogs')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -1579,11 +1545,7 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], @@ -1694,9 +1656,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5625257407409224246" - } + "version": "0.20.4.51522", + "templateHash": "18442235072798053221" + }, + "name": "Healthcare API Workspace IoT Connector FHIR Destinations", + "description": "This module deploys a Healthcare API Workspace IoT Connector FHIR Destination.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1751,13 +1716,13 @@ "resourceIdentityResolutionType": { "type": "string", "defaultValue": "Lookup", - "metadata": { - "description": "Optional. Determines how resource identity is resolved on the destination." - }, "allowedValues": [ "Create", "Lookup" - ] + ], + "metadata": { + "description": "Optional. Determines how resource identity is resolved on the destination." + } } }, "resources": [ diff --git a/modules/insights/action-group/main.json b/modules/insights/action-group/main.json index 8559a53a77..86bd937295 100644 --- a/modules/insights/action-group/main.json +++ b/modules/insights/action-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3611012359574200078" - } + "version": "0.20.4.51522", + "templateHash": "7436511771322208351" + }, + "name": "Action Groups", + "description": "This module deploys an Action Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -197,8 +200,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15066885127596890987" + "version": "0.20.4.51522", + "templateHash": "8367920646182761059" } }, "parameters": { diff --git a/modules/insights/activity-log-alert/main.json b/modules/insights/activity-log-alert/main.json index 72010dd035..75cfdbfa9d 100644 --- a/modules/insights/activity-log-alert/main.json +++ b/modules/insights/activity-log-alert/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12922301550242279895" - } + "version": "0.20.4.51522", + "templateHash": "12483368143384987419" + }, + "name": "Activity Log Alerts", + "description": "This module deploys an Activity Log Alert.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -159,8 +162,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11667512505521874865" + "version": "0.20.4.51522", + "templateHash": "3392546988640861707" } }, "parameters": { diff --git a/modules/insights/component/.test/common/main.test.bicep b/modules/insights/component/.test/common/main.test.bicep index 63923f1643..fcd24bdb75 100644 --- a/modules/insights/component/.test/common/main.test.bicep +++ b/modules/insights/component/.test/common/main.test.bicep @@ -68,7 +68,6 @@ module testDeployment '../../main.bicep' = { diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diagnosticEventHubName: diagnosticDependencies.outputs.eventHubNamespaceEventHubName - diagnosticLogsRetentionInDays: 7 roleAssignments: [ { roleDefinitionIdOrName: 'Reader' diff --git a/modules/insights/component/README.md b/modules/insights/component/README.md index 37697220e5..48eb8b99af 100644 --- a/modules/insights/component/README.md +++ b/modules/insights/component/README.md @@ -35,7 +35,6 @@ This component deploys an Application Insights instance. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, AppAvailabilityResults, AppBrowserTimings, AppDependencies, AppEvents, AppExceptions, AppMetrics, AppPageViews, AppPerformanceCounters, AppRequests, AppSystemEvents, AppTraces]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -189,7 +188,6 @@ module component './insights/component/main.bicep' = { // Non-required parameters diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -236,9 +234,6 @@ module component './insights/component/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/insights/component/main.bicep b/modules/insights/component/main.bicep index 661d545480..f6f6eb774d 100644 --- a/modules/insights/component/main.bicep +++ b/modules/insights/component/main.bicep @@ -63,11 +63,6 @@ param tags object = {} @description('Optional. Enable telemetry via a Globally Unique Identifier (GUID).') param enableDefaultTelemetry bool = true -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -114,20 +109,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -135,10 +122,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (enableDefaultTelemetry) { name: 'pid-47ed15a6-730a-4827-bcb4-0fd963ffbd82-${uniqueString(deployment().name, location)}' diff --git a/modules/insights/component/main.json b/modules/insights/component/main.json index 319563f711..eaad52c2a6 100644 --- a/modules/insights/component/main.json +++ b/modules/insights/component/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15330446449054175723" - } + "version": "0.20.4.51522", + "templateHash": "2194633988963750006" + }, + "name": "Application Insights", + "description": "This component deploys an Application Insights instance.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -75,8 +78,8 @@ "samplingPercentage": { "type": "int", "defaultValue": 100, - "maxValue": 100, "minValue": 0, + "maxValue": 100, "metadata": { "description": "Optional. Percentage of the data produced by the application being monitored that is being sampled for Application Insights telemetry." } @@ -116,15 +119,6 @@ "description": "Optional. Enable telemetry via a Globally Unique Identifier (GUID)." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -204,11 +198,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -217,15 +207,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" }, "resources": [ { @@ -310,8 +296,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5376732028486358032" + "version": "0.20.4.51522", + "templateHash": "8980605934442276115" } }, "parameters": { diff --git a/modules/insights/data-collection-endpoint/main.json b/modules/insights/data-collection-endpoint/main.json index d7e3fe6c39..52cbd6c980 100644 --- a/modules/insights/data-collection-endpoint/main.json +++ b/modules/insights/data-collection-endpoint/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10822358276047923797" - } + "version": "0.20.4.51522", + "templateHash": "7104376460236029224" + }, + "name": "Data Collection Endpoints", + "description": "This module deploys a Data Collection Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -154,8 +157,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3348228389312702075" + "version": "0.20.4.51522", + "templateHash": "4828222370523897181" } }, "parameters": { diff --git a/modules/insights/data-collection-rule/main.json b/modules/insights/data-collection-rule/main.json index 42a7070c45..55e60ccf76 100644 --- a/modules/insights/data-collection-rule/main.json +++ b/modules/insights/data-collection-rule/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2746699494103056755" - } + "version": "0.20.4.51522", + "templateHash": "9942526402444746051" + }, + "name": "Data Collection Rules", + "description": "This module deploys a Data Collection Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -185,8 +188,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5827707972845094534" + "version": "0.20.4.51522", + "templateHash": "5410933284087762205" } }, "parameters": { diff --git a/modules/insights/diagnostic-setting/.test/common/main.test.bicep b/modules/insights/diagnostic-setting/.test/common/main.test.bicep index 62e0d84fb9..d8eb101670 100644 --- a/modules/insights/diagnostic-setting/.test/common/main.test.bicep +++ b/modules/insights/diagnostic-setting/.test/common/main.test.bicep @@ -54,7 +54,6 @@ module testDeployment '../../main.bicep' = { params: { enableDefaultTelemetry: enableDefaultTelemetry name: '${namePrefix}${serviceShort}001' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/insights/diagnostic-setting/README.md b/modules/insights/diagnostic-setting/README.md index 3574719a0e..1af907de3f 100644 --- a/modules/insights/diagnostic-setting/README.md +++ b/modules/insights/diagnostic-setting/README.md @@ -25,7 +25,6 @@ This module deploys a Subscription wide export of the Activity Log. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', Administrative, Alert, allLogs, Autoscale, Policy, Recommendation, ResourceHealth, Security, ServiceHealth]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | | `diagnosticWorkspaceId` | string | `''` | | Resource ID of the diagnostic log analytics workspace. | | `enableDefaultTelemetry` | bool | `True` | | Enable telemetry via a Globally Unique Identifier (GUID). | @@ -64,7 +63,6 @@ module diagnosticSetting './insights/diagnostic-setting/main.bicep' = { params: { diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -91,9 +89,6 @@ module diagnosticSetting './insights/diagnostic-setting/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/insights/diagnostic-setting/main.bicep b/modules/insights/diagnostic-setting/main.bicep index d2eab81677..1054a40273 100644 --- a/modules/insights/diagnostic-setting/main.bicep +++ b/modules/insights/diagnostic-setting/main.bicep @@ -9,11 +9,6 @@ targetScope = 'subscription' @maxLength(260) param name string = '${uniqueString(subscription().id)}-ActivityLog' -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -52,20 +47,12 @@ param location string = deployment().location var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified diff --git a/modules/insights/diagnostic-setting/main.json b/modules/insights/diagnostic-setting/main.json index ea1c2ea638..f664a98704 100644 --- a/modules/insights/diagnostic-setting/main.json +++ b/modules/insights/diagnostic-setting/main.json @@ -4,29 +4,23 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4246828463890718517" - } + "version": "0.20.4.51522", + "templateHash": "16527409196402161876" + }, + "name": "Diagnostic Settings (Activity Logs) for Azure Subscriptions", + "description": "This module deploys a Subscription wide export of the Activity Log.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { "type": "string", "defaultValue": "[format('{0}-ActivityLog', uniqueString(subscription().id))]", - "maxLength": 260, "minLength": 1, + "maxLength": 260, "metadata": { "description": "Optional. Name of the ActivityLog diagnostic settings." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -98,15 +92,11 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" }, "resources": [ { diff --git a/modules/insights/metric-alert/main.json b/modules/insights/metric-alert/main.json index 3b723b482c..463df0aec2 100644 --- a/modules/insights/metric-alert/main.json +++ b/modules/insights/metric-alert/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15628752476358479893" - } + "version": "0.20.4.51522", + "templateHash": "17294788707800776152" + }, + "name": "Metric Alerts", + "description": "This module deploys a Metric Alert.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -242,8 +245,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14205051524800606717" + "version": "0.20.4.51522", + "templateHash": "10158771102272403472" } }, "parameters": { diff --git a/modules/insights/private-link-scope/.test/common/dependencies.bicep b/modules/insights/private-link-scope/.test/common/dependencies.bicep index 3b81287ace..a6a76f7615 100644 --- a/modules/insights/private-link-scope/.test/common/dependencies.bicep +++ b/modules/insights/private-link-scope/.test/common/dependencies.bicep @@ -12,50 +12,50 @@ param logAnalyticsWorkspaceName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.monitor.azure.com' - location: 'global' + name: 'privatelink.monitor.azure.com' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource logAnalyticsWorkspace 'Microsoft.OperationalInsights/workspaces@2021-12-01-preview' = { - name: logAnalyticsWorkspaceName - location: location + name: logAnalyticsWorkspaceName + location: location } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/insights/private-link-scope/README.md b/modules/insights/private-link-scope/README.md index 674c31ac5f..fc7bce7a62 100644 --- a/modules/insights/private-link-scope/README.md +++ b/modules/insights/private-link-scope/README.md @@ -18,8 +18,8 @@ This module deploys an Azure Monitor Private Link Scope. | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `microsoft.insights/privateLinkScopes` | [2019-10-17-preview](https://learn.microsoft.com/en-us/azure/templates/microsoft.insights/2019-10-17-preview/privateLinkScopes) | | `Microsoft.Insights/privateLinkScopes/scopedResources` | [2021-07-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-07-01-preview/privateLinkScopes/scopedResources) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | ## Parameters diff --git a/modules/insights/private-link-scope/main.json b/modules/insights/private-link-scope/main.json index 03be9d3a5c..e67afb5125 100644 --- a/modules/insights/private-link-scope/main.json +++ b/modules/insights/private-link-scope/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4375794655984806710" - } + "version": "0.20.4.51522", + "templateHash": "11301240088087056436" + }, + "name": "Azure Monitor Private Link Scopes", + "description": "This module deploys an Azure Monitor Private Link Scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -26,14 +29,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -144,9 +147,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3289526807399666136" - } + "version": "0.20.4.51522", + "templateHash": "15630582062607337146" + }, + "name": "Private Link Scope Scoped Resources", + "description": "This module deploys a Private Link Scope Scoped Resource.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -278,9 +284,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -345,14 +354,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -410,7 +419,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -475,9 +484,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -488,8 +500,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -540,7 +552,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -610,8 +622,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -781,7 +793,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -824,8 +836,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10126661940064474862" + "version": "0.20.4.51522", + "templateHash": "6491925298018963513" } }, "parameters": { diff --git a/modules/insights/private-link-scope/scoped-resource/main.json b/modules/insights/private-link-scope/scoped-resource/main.json index ee7d4fa789..790a70f1a7 100644 --- a/modules/insights/private-link-scope/scoped-resource/main.json +++ b/modules/insights/private-link-scope/scoped-resource/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3289526807399666136" - } + "version": "0.20.4.51522", + "templateHash": "15630582062607337146" + }, + "name": "Private Link Scope Scoped Resources", + "description": "This module deploys a Private Link Scope Scoped Resource.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/insights/scheduled-query-rule/main.json b/modules/insights/scheduled-query-rule/main.json index 439401ad89..ed3d4bf01c 100644 --- a/modules/insights/scheduled-query-rule/main.json +++ b/modules/insights/scheduled-query-rule/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4780686160683711568" - } + "version": "0.20.4.51522", + "templateHash": "16573278604665117270" + }, + "name": "Scheduled Query Rules", + "description": "This module deploys a Scheduled Query Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -227,8 +230,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3668193387034475361" + "version": "0.20.4.51522", + "templateHash": "14161037593999290531" } }, "parameters": { diff --git a/modules/insights/webtest/main.json b/modules/insights/webtest/main.json index 1980c0346e..c988c26735 100644 --- a/modules/insights/webtest/main.json +++ b/modules/insights/webtest/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6380631972103866785" - } + "version": "0.20.4.51522", + "templateHash": "14101657949762425247" + }, + "name": "Web Tests", + "description": "This module deploys a Web Test.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -134,14 +137,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -242,8 +245,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "374898712532732433" + "version": "0.20.4.51522", + "templateHash": "2663297042966788327" } }, "parameters": { diff --git a/modules/key-vault/vault/.test/common/dependencies.bicep b/modules/key-vault/vault/.test/common/dependencies.bicep index 064a1f10d8..73944d7f06 100644 --- a/modules/key-vault/vault/.test/common/dependencies.bicep +++ b/modules/key-vault/vault/.test/common/dependencies.bicep @@ -9,50 +9,50 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] + } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + serviceEndpoints: [ { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - serviceEndpoints: [ - { - service: 'Microsoft.KeyVault' - } - ] - } + service: 'Microsoft.KeyVault' } - ] - } + ] + } + } + ] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.vaultcore.azure.net' - location: 'global' + name: 'privatelink.vaultcore.azure.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/key-vault/vault/.test/common/main.test.bicep b/modules/key-vault/vault/.test/common/main.test.bicep index 9fb15bfb73..0d82e9293e 100644 --- a/modules/key-vault/vault/.test/common/main.test.bicep +++ b/modules/key-vault/vault/.test/common/main.test.bicep @@ -93,7 +93,6 @@ module testDeployment '../../main.bicep' = { } } ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/key-vault/vault/.test/pe/dependencies.bicep b/modules/key-vault/vault/.test/pe/dependencies.bicep index 688f2f2797..a52dc4dc09 100644 --- a/modules/key-vault/vault/.test/pe/dependencies.bicep +++ b/modules/key-vault/vault/.test/pe/dependencies.bicep @@ -6,40 +6,40 @@ param virtualNetworkName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.vaultcore.azure.net' - location: 'global' + name: 'privatelink.vaultcore.azure.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/key-vault/vault/README.md b/modules/key-vault/vault/README.md index c4529a2f21..d1bd7943f2 100644 --- a/modules/key-vault/vault/README.md +++ b/modules/key-vault/vault/README.md @@ -21,8 +21,8 @@ This module deploys a Key Vault. | `Microsoft.KeyVault/vaults/accessPolicies` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.KeyVault/2022-07-01/vaults/accessPolicies) | | `Microsoft.KeyVault/vaults/keys` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.KeyVault/2022-07-01/vaults/keys) | | `Microsoft.KeyVault/vaults/secrets` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.KeyVault/2022-07-01/vaults/secrets) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | ## Parameters @@ -41,7 +41,6 @@ This module deploys a Key Vault. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, AuditEvent, AzurePolicyEvaluationDetails]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub. | @@ -445,7 +444,6 @@ module vault './key-vault/vault/main.bicep' = { ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -611,9 +609,6 @@ module vault './key-vault/vault/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/key-vault/vault/access-policy/main.json b/modules/key-vault/vault/access-policy/main.json index 99229529e1..8605743d3b 100644 --- a/modules/key-vault/vault/access-policy/main.json +++ b/modules/key-vault/vault/access-policy/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5956155025819321457" - } + "version": "0.20.4.51522", + "templateHash": "7542638391604115549" + }, + "name": "Key Vault Access Policies", + "description": "This module deploys a Key Vault Access Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "keyVaultName": { diff --git a/modules/key-vault/vault/key/main.json b/modules/key-vault/vault/key/main.json index 3d7876476c..424830e621 100644 --- a/modules/key-vault/vault/key/main.json +++ b/modules/key-vault/vault/key/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7585019690208379133" - } + "version": "0.20.4.51522", + "templateHash": "7510105499462799965" + }, + "name": "Key Vault Keys", + "description": "This module deploys a Key Vault Key.", + "owner": "Azure/module-maintainers" }, "parameters": { "keyVaultName": { @@ -187,8 +190,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3354496057078802382" + "version": "0.20.4.51522", + "templateHash": "3968881335142586299" } }, "parameters": { diff --git a/modules/key-vault/vault/main.bicep b/modules/key-vault/vault/main.bicep index 7a530242f1..e6afd5d50f 100644 --- a/modules/key-vault/vault/main.bicep +++ b/modules/key-vault/vault/main.bicep @@ -64,11 +64,6 @@ param networkAcls object = {} ]) param publicNetworkAccess string = '' -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub.') param diagnosticStorageAccountId string = '' @@ -129,20 +124,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -150,10 +137,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var formattedAccessPolicies = [for accessPolicy in accessPolicies: { diff --git a/modules/key-vault/vault/main.json b/modules/key-vault/vault/main.json index ae7b4bec71..6e8099ca11 100644 --- a/modules/key-vault/vault/main.json +++ b/modules/key-vault/vault/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9781665469217879953" - } + "version": "0.20.4.51522", + "templateHash": "16665099504700716453" + }, + "name": "Key Vaults", + "description": "This module deploys a Key Vault.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -130,15 +133,6 @@ "description": "Optional. Whether or not public network access is allowed for this resource. For security reasons it should be disabled. If not specified, it will be disabled by default if private endpoints are set and networkAcls are not set." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -170,14 +164,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -249,11 +243,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -262,11 +252,7 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -280,7 +266,7 @@ } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "secretList": "[if(not(empty(parameters('secrets'))), parameters('secrets').secureList, createArray())]", "enableReferencedModulesTelemetry": false }, @@ -383,9 +369,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5956155025819321457" - } + "version": "0.20.4.51522", + "templateHash": "7542638391604115549" + }, + "name": "Key Vault Access Policies", + "description": "This module deploys a Key Vault Access Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "keyVaultName": { @@ -515,9 +504,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11848774348676575570" - } + "version": "0.20.4.51522", + "templateHash": "3581368535918618501" + }, + "name": "Key Vault Secrets", + "description": "This module deploys a Key Vault Secret.", + "owner": "Azure/module-maintainers" }, "parameters": { "keyVaultName": { @@ -652,8 +644,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9154475470956985352" + "version": "0.20.4.51522", + "templateHash": "4251680927905962776" } }, "parameters": { @@ -847,9 +839,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7585019690208379133" - } + "version": "0.20.4.51522", + "templateHash": "7510105499462799965" + }, + "name": "Key Vault Keys", + "description": "This module deploys a Key Vault Key.", + "owner": "Azure/module-maintainers" }, "parameters": { "keyVaultName": { @@ -1030,8 +1025,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3354496057078802382" + "version": "0.20.4.51522", + "templateHash": "3968881335142586299" } }, "parameters": { @@ -1233,9 +1228,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1300,14 +1298,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -1365,7 +1363,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -1430,9 +1428,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -1443,8 +1444,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -1495,7 +1496,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -1565,8 +1566,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -1736,7 +1737,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -1779,8 +1780,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3806203937606389856" + "version": "0.20.4.51522", + "templateHash": "18089760146236492183" } }, "parameters": { diff --git a/modules/key-vault/vault/secret/main.json b/modules/key-vault/vault/secret/main.json index 11eb252704..5a92b128a4 100644 --- a/modules/key-vault/vault/secret/main.json +++ b/modules/key-vault/vault/secret/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11848774348676575570" - } + "version": "0.20.4.51522", + "templateHash": "3581368535918618501" + }, + "name": "Key Vault Secrets", + "description": "This module deploys a Key Vault Secret.", + "owner": "Azure/module-maintainers" }, "parameters": { "keyVaultName": { @@ -141,8 +144,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9154475470956985352" + "version": "0.20.4.51522", + "templateHash": "4251680927905962776" } }, "parameters": { diff --git a/modules/kubernetes-configuration/extension/main.json b/modules/kubernetes-configuration/extension/main.json index c49654266c..a4f6868243 100644 --- a/modules/kubernetes-configuration/extension/main.json +++ b/modules/kubernetes-configuration/extension/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9994137923318557139" - } + "version": "0.20.4.51522", + "templateHash": "14118650678014878152" + }, + "name": "Kubernetes Configuration Extensions", + "description": "This module deploys a Kubernetes Configuration Extension.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -164,9 +167,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1433522452027494189" - } + "version": "0.20.4.51522", + "templateHash": "16353701795521321177" + }, + "name": "Kubernetes Configuration Flux Configurations", + "description": "This module deploys a Kubernetes Configuration Flux Configuration.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -231,23 +237,23 @@ }, "scope": { "type": "string", - "metadata": { - "description": "Required. Scope at which the configuration will be installed." - }, "allowedValues": [ "cluster", "namespace" - ] + ], + "metadata": { + "description": "Required. Scope at which the configuration will be installed." + } }, "sourceKind": { "type": "string", - "metadata": { - "description": "Required. Source Kind to pull the configuration data from." - }, "allowedValues": [ "Bucket", "GitRepository" - ] + ], + "metadata": { + "description": "Required. Source Kind to pull the configuration data from." + } }, "suspend": { "type": "bool", diff --git a/modules/kubernetes-configuration/flux-configuration/main.json b/modules/kubernetes-configuration/flux-configuration/main.json index 4434fee084..7eb97fbd22 100644 --- a/modules/kubernetes-configuration/flux-configuration/main.json +++ b/modules/kubernetes-configuration/flux-configuration/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1433522452027494189" - } + "version": "0.20.4.51522", + "templateHash": "16353701795521321177" + }, + "name": "Kubernetes Configuration Flux Configurations", + "description": "This module deploys a Kubernetes Configuration Flux Configuration.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -71,23 +74,23 @@ }, "scope": { "type": "string", - "metadata": { - "description": "Required. Scope at which the configuration will be installed." - }, "allowedValues": [ "cluster", "namespace" - ] + ], + "metadata": { + "description": "Required. Scope at which the configuration will be installed." + } }, "sourceKind": { "type": "string", - "metadata": { - "description": "Required. Source Kind to pull the configuration data from." - }, "allowedValues": [ "Bucket", "GitRepository" - ] + ], + "metadata": { + "description": "Required. Source Kind to pull the configuration data from." + } }, "suspend": { "type": "bool", diff --git a/modules/logic/workflow/.test/common/main.test.bicep b/modules/logic/workflow/.test/common/main.test.bicep index 85c51d1cdf..d5d815a1ba 100644 --- a/modules/logic/workflow/.test/common/main.test.bicep +++ b/modules/logic/workflow/.test/common/main.test.bicep @@ -63,7 +63,6 @@ module testDeployment '../../main.bicep' = { params: { enableDefaultTelemetry: enableDefaultTelemetry name: '${namePrefix}${serviceShort}001' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/logic/workflow/README.md b/modules/logic/workflow/README.md index f2d6d77eb6..029e1d3ef8 100644 --- a/modules/logic/workflow/README.md +++ b/modules/logic/workflow/README.md @@ -38,7 +38,6 @@ This module deploys a Logic App (Workflow). | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, WorkflowRuntime]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -339,7 +338,6 @@ module workflow './logic/workflow/main.bicep' = { // Non-required parameters diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -418,9 +416,6 @@ module workflow './logic/workflow/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/logic/workflow/main.bicep b/modules/logic/workflow/main.bicep index 707b36ec4f..9562898748 100644 --- a/modules/logic/workflow/main.bicep +++ b/modules/logic/workflow/main.bicep @@ -35,11 +35,6 @@ param integrationServiceEnvironmentResourceId string = '' @description('Optional. Location for all resources.') param location string = resourceGroup().location -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -125,20 +120,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -146,10 +133,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var identityType = systemAssignedIdentity ? 'SystemAssigned' : (!empty(userAssignedIdentities) ? 'UserAssigned' : 'None') diff --git a/modules/logic/workflow/main.json b/modules/logic/workflow/main.json index 3d8da17c92..92bebfe574 100644 --- a/modules/logic/workflow/main.json +++ b/modules/logic/workflow/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10964111464672282438" - } + "version": "0.20.4.51522", + "templateHash": "4657619507482611014" + }, + "name": "Logic Apps (Workflows)", + "description": "This module deploys a Logic App (Workflow).", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -85,15 +88,6 @@ "description": "Optional. Location for all resources." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -125,14 +119,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -260,11 +254,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -273,15 +263,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "identityType": "[if(parameters('systemAssignedIdentity'), 'SystemAssigned', if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None'))]", "identity": "[if(not(equals(variables('identityType'), 'None')), createObject('type', variables('identityType'), 'userAssignedIdentities', if(not(empty(parameters('userAssignedIdentities'))), parameters('userAssignedIdentities'), null())), null())]" }, @@ -399,8 +385,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3963079147102258163" + "version": "0.20.4.51522", + "templateHash": "17426038722469258445" } }, "parameters": { diff --git a/modules/machine-learning-services/workspace/.test/common/dependencies.bicep b/modules/machine-learning-services/workspace/.test/common/dependencies.bicep index e8d05c137c..bfbf61767d 100644 --- a/modules/machine-learning-services/workspace/.test/common/dependencies.bicep +++ b/modules/machine-learning-services/workspace/.test/common/dependencies.bicep @@ -18,98 +18,98 @@ param storageAccountName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource keyVault 'Microsoft.KeyVault/vaults@2022-07-01' = { - name: keyVaultName - location: location - properties: { - sku: { - family: 'A' - name: 'standard' - } - tenantId: tenant().tenantId - enablePurgeProtection: null - enabledForTemplateDeployment: true - enabledForDiskEncryption: true - enabledForDeployment: true - enableRbacAuthorization: true - accessPolicies: [] + name: keyVaultName + location: location + properties: { + sku: { + family: 'A' + name: 'standard' } + tenantId: tenant().tenantId + enablePurgeProtection: null + enabledForTemplateDeployment: true + enabledForDiskEncryption: true + enabledForDeployment: true + enableRbacAuthorization: true + accessPolicies: [] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource keyVaultServicePermissions 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid('msi-${keyVault.id}-${location}-${managedIdentity.id}-KeyVault-Contributor-RoleAssignment') - scope: keyVault - properties: { - principalId: managedIdentity.properties.principalId - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'b24988ac-6180-42a0-ab88-20f7382dd24c') // Contributor - principalType: 'ServicePrincipal' - } + name: guid('msi-${keyVault.id}-${location}-${managedIdentity.id}-KeyVault-Contributor-RoleAssignment') + scope: keyVault + properties: { + principalId: managedIdentity.properties.principalId + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'b24988ac-6180-42a0-ab88-20f7382dd24c') // Contributor + principalType: 'ServicePrincipal' + } } resource keyVaultDataPermissions 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid('msi-${keyVault.id}-${location}-${managedIdentity.id}-KeyVault-Data-Admin-RoleAssignment') - scope: keyVault - properties: { - principalId: managedIdentity.properties.principalId - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '00482a5a-887f-4fb3-b363-3b7fe8e74483') // Key Vault Administrator - principalType: 'ServicePrincipal' - } + name: guid('msi-${keyVault.id}-${location}-${managedIdentity.id}-KeyVault-Data-Admin-RoleAssignment') + scope: keyVault + properties: { + principalId: managedIdentity.properties.principalId + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '00482a5a-887f-4fb3-b363-3b7fe8e74483') // Key Vault Administrator + principalType: 'ServicePrincipal' + } } resource applicationInsights 'Microsoft.Insights/components@2020-02-02' = { - name: applicationInsightsName - location: location - kind: '' - properties: {} + name: applicationInsightsName + location: location + kind: '' + properties: {} } resource storageAccount 'Microsoft.Storage/storageAccounts@2021-09-01' = { - name: storageAccountName - location: location - sku: { - name: 'Standard_LRS' - } - kind: 'StorageV2' + name: storageAccountName + location: location + sku: { + name: 'Standard_LRS' + } + kind: 'StorageV2' } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.api.azureml.ms' - location: 'global' + name: 'privatelink.api.azureml.ms' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/machine-learning-services/workspace/.test/common/main.test.bicep b/modules/machine-learning-services/workspace/.test/common/main.test.bicep index cad6ccb49e..8ef9866ca3 100644 --- a/modules/machine-learning-services/workspace/.test/common/main.test.bicep +++ b/modules/machine-learning-services/workspace/.test/common/main.test.bicep @@ -101,7 +101,6 @@ module testDeployment '../../main.bicep' = { } ] description: 'The cake is a lie.' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/machine-learning-services/workspace/.test/encr/dependencies.bicep b/modules/machine-learning-services/workspace/.test/encr/dependencies.bicep index dc63792fcb..f0bbffab09 100644 --- a/modules/machine-learning-services/workspace/.test/encr/dependencies.bicep +++ b/modules/machine-learning-services/workspace/.test/encr/dependencies.bicep @@ -20,106 +20,106 @@ param storageAccountName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource keyVault 'Microsoft.KeyVault/vaults@2022-07-01' = { - name: keyVaultName - location: location - properties: { - sku: { - family: 'A' - name: 'standard' - } - tenantId: tenant().tenantId - enablePurgeProtection: true // Required by batch account - softDeleteRetentionInDays: 7 - enabledForTemplateDeployment: true - enabledForDiskEncryption: true - enabledForDeployment: true - enableRbacAuthorization: true - accessPolicies: [] + name: keyVaultName + location: location + properties: { + sku: { + family: 'A' + name: 'standard' } - - resource key 'keys@2022-07-01' = { - name: 'keyEncryptionKey' - properties: { - kty: 'RSA' - } + tenantId: tenant().tenantId + enablePurgeProtection: true // Required by batch account + softDeleteRetentionInDays: 7 + enabledForTemplateDeployment: true + enabledForDiskEncryption: true + enabledForDeployment: true + enableRbacAuthorization: true + accessPolicies: [] + } + + resource key 'keys@2022-07-01' = { + name: 'keyEncryptionKey' + properties: { + kty: 'RSA' } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource keyVaultServicePermissions 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid('msi-${keyVault.id}-${location}-${managedIdentity.id}-KeyVault-Contributor-RoleAssignment') - scope: keyVault - properties: { - principalId: managedIdentity.properties.principalId - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'b24988ac-6180-42a0-ab88-20f7382dd24c') // Contributor - principalType: 'ServicePrincipal' - } + name: guid('msi-${keyVault.id}-${location}-${managedIdentity.id}-KeyVault-Contributor-RoleAssignment') + scope: keyVault + properties: { + principalId: managedIdentity.properties.principalId + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'b24988ac-6180-42a0-ab88-20f7382dd24c') // Contributor + principalType: 'ServicePrincipal' + } } resource keyVaultDataPermissions 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid('msi-${keyVault.id}-${location}-${managedIdentity.id}-KeyVault-Data-Admin-RoleAssignment') - scope: keyVault::key - properties: { - principalId: managedIdentity.properties.principalId - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '12338af0-0e69-4776-bea7-57ae8d297424') // Key Vault Crypto User - principalType: 'ServicePrincipal' - } + name: guid('msi-${keyVault.id}-${location}-${managedIdentity.id}-KeyVault-Data-Admin-RoleAssignment') + scope: keyVault::key + properties: { + principalId: managedIdentity.properties.principalId + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '12338af0-0e69-4776-bea7-57ae8d297424') // Key Vault Crypto User + principalType: 'ServicePrincipal' + } } resource applicationInsights 'Microsoft.Insights/components@2020-02-02' = { - name: applicationInsightsName - location: location - kind: '' - properties: {} + name: applicationInsightsName + location: location + kind: '' + properties: {} } resource storageAccount 'Microsoft.Storage/storageAccounts@2021-09-01' = { - name: storageAccountName - location: location - sku: { - name: 'Standard_LRS' - } - kind: 'StorageV2' + name: storageAccountName + location: location + sku: { + name: 'Standard_LRS' + } + kind: 'StorageV2' } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.api.azureml.ms' - location: 'global' + name: 'privatelink.api.azureml.ms' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/machine-learning-services/workspace/README.md b/modules/machine-learning-services/workspace/README.md index a15a4bd947..b25795e5be 100644 --- a/modules/machine-learning-services/workspace/README.md +++ b/modules/machine-learning-services/workspace/README.md @@ -19,8 +19,8 @@ This module deploys a Machine Learning Services Workspace. | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | | `Microsoft.MachineLearningServices/workspaces` | [2022-10-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.MachineLearningServices/2022-10-01/workspaces) | | `Microsoft.MachineLearningServices/workspaces/computes` | [2022-10-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.MachineLearningServices/2022-10-01/workspaces/computes) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | ## Parameters @@ -57,7 +57,6 @@ This module deploys a Machine Learning Services Workspace. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, AmlComputeClusterEvent, AmlComputeClusterNodeEvent, AmlComputeCpuGpuUtilization, AmlComputeJobEvent, AmlRunStatusChangedEvent]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -488,7 +487,6 @@ module workspace './machine-learning-services/workspace/main.bicep' = { description: 'The cake is a lie.' diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' discoveryUrl: 'http://example.com' @@ -600,9 +598,6 @@ module workspace './machine-learning-services/workspace/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/machine-learning-services/workspace/compute/main.json b/modules/machine-learning-services/workspace/compute/main.json index fb249825ce..6a6d90b340 100644 --- a/modules/machine-learning-services/workspace/compute/main.json +++ b/modules/machine-learning-services/workspace/compute/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15795280339280624879" - } + "version": "0.20.4.51522", + "templateHash": "1887700101020083718" + }, + "name": "Machine Learning Services Workspaces Computes", + "description": "This module deploys a Machine Learning Services Workspaces Compute.\r\n\r\nAttaching a compute is not idempotent and will fail in case you try to redeploy over an existing compute in AML (see parameter `deployCompute`).", + "owner": "Azure/module-maintainers" }, "parameters": { "machineLearningWorkspaceName": { @@ -17,8 +20,8 @@ }, "name": { "type": "string", - "maxLength": 16, "minLength": 2, + "maxLength": 16, "metadata": { "description": "Required. Name of the compute." } diff --git a/modules/machine-learning-services/workspace/main.bicep b/modules/machine-learning-services/workspace/main.bicep index 7056db4f7d..e7dadf2e34 100644 --- a/modules/machine-learning-services/workspace/main.bicep +++ b/modules/machine-learning-services/workspace/main.bicep @@ -69,11 +69,6 @@ param systemAssignedIdentity bool = false param userAssignedIdentities object = {} // Diagnostic Settings -@sys.description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @sys.description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -164,20 +159,12 @@ var identity = identityType != 'None' ? { var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -185,10 +172,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] // ================// diff --git a/modules/machine-learning-services/workspace/main.json b/modules/machine-learning-services/workspace/main.json index 325061b378..5f5a4ad75a 100644 --- a/modules/machine-learning-services/workspace/main.json +++ b/modules/machine-learning-services/workspace/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5741661511872344841" - } + "version": "0.20.4.51522", + "templateHash": "12489776525535905441" + }, + "name": "Machine Learning Services Workspaces", + "description": "This module deploys a Machine Learning Services Workspace.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -62,14 +65,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "hbiWorkspace": { "type": "bool", @@ -134,15 +137,6 @@ "description": "Conditional. The ID(s) to assign to the resource. Required if `systemAssignedIdentity` is set to false." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -298,11 +292,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -311,18 +301,14 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], "enableReferencedModulesTelemetry": false, "identityType": "[if(parameters('systemAssignedIdentity'), if(not(empty(parameters('userAssignedIdentities'))), 'SystemAssigned,UserAssigned', 'SystemAssigned'), if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None'))]", "identity": "[if(not(equals(variables('identityType'), 'None')), createObject('type', variables('identityType'), 'userAssignedIdentities', if(not(empty(parameters('userAssignedIdentities'))), parameters('userAssignedIdentities'), null())), null())]", - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" }, "resources": [ { @@ -445,9 +431,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15795280339280624879" - } + "version": "0.20.4.51522", + "templateHash": "1887700101020083718" + }, + "name": "Machine Learning Services Workspaces Computes", + "description": "This module deploys a Machine Learning Services Workspaces Compute.\r\n\r\nAttaching a compute is not idempotent and will fail in case you try to redeploy over an existing compute in AML (see parameter `deployCompute`).", + "owner": "Azure/module-maintainers" }, "parameters": { "machineLearningWorkspaceName": { @@ -458,8 +447,8 @@ }, "name": { "type": "string", - "maxLength": 16, "minLength": 2, + "maxLength": 16, "metadata": { "description": "Required. Name of the compute." } @@ -693,9 +682,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -760,14 +752,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -825,7 +817,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -890,9 +882,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -903,8 +898,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -955,7 +950,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -1025,8 +1020,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -1196,7 +1191,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -1239,8 +1234,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3436984846601692541" + "version": "0.20.4.51522", + "templateHash": "3821714743195780251" } }, "parameters": { diff --git a/modules/maintenance/maintenance-configuration/main.json b/modules/maintenance/maintenance-configuration/main.json index b348af1a01..b03447786a 100644 --- a/modules/maintenance/maintenance-configuration/main.json +++ b/modules/maintenance/maintenance-configuration/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17935698824231934849" - } + "version": "0.20.4.51522", + "templateHash": "16739611821824144982" + }, + "name": "Maintenance Configurations", + "description": "This module deploys a Maintenance Configuration.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -181,8 +184,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17071263450023081003" + "version": "0.20.4.51522", + "templateHash": "7156539886562733404" } }, "parameters": { diff --git a/modules/managed-identity/user-assigned-identity/main.json b/modules/managed-identity/user-assigned-identity/main.json index 4100b1a52c..79b93fda5a 100644 --- a/modules/managed-identity/user-assigned-identity/main.json +++ b/modules/managed-identity/user-assigned-identity/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11596446637697126199" - } + "version": "0.20.4.51522", + "templateHash": "510769152124932769" + }, + "name": "User Assigned Identities", + "description": "This module deploys a User Assigned Identity.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -26,14 +29,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -127,8 +130,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "944620176257250244" + "version": "0.20.4.51522", + "templateHash": "7489087194642478460" } }, "parameters": { diff --git a/modules/managed-services/registration-definition/main.json b/modules/managed-services/registration-definition/main.json index 6ae5686a17..b2f205ebfd 100644 --- a/modules/managed-services/registration-definition/main.json +++ b/modules/managed-services/registration-definition/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6492155404763508094" - } + "version": "0.20.4.51522", + "templateHash": "6524933084453245231" + }, + "name": "Registration Definitions", + "description": "This module deploys a `Registration Definition` and a `Registration Assignment` (often referred to as 'Lighthouse' or 'resource delegation')\r\non subscription or resource group scopes. This type of delegation is very similar to role assignments but here the principal that is\r\nassigned a role is in a remote/managing Azure Active Directory tenant. The templates are run towards the tenant where\r\nthe Azure resources you want to delegate access to are, providing 'authorizations' (aka. access delegation) to principals in a\r\nremote/managing tenant.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -122,8 +125,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14693332143746765828" + "version": "0.20.4.51522", + "templateHash": "13427221863666370070" } }, "parameters": { diff --git a/modules/management/management-group/main.json b/modules/management/management-group/main.json index bf8206a0a9..b9b7eff029 100644 --- a/modules/management/management-group/main.json +++ b/modules/management/management-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "429938566920379086" - } + "version": "0.20.4.51522", + "templateHash": "1453799279339111364" + }, + "name": "Management Groups", + "description": "This template will prepare the management group structure based on the provided parameter.\r\n\r\nThis module has some known **limitations**:\r\n- It's not possible to change the display name of the root management group (the one that has the tenant GUID as ID)\r\n- It can't manage the Root (/) management group", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/net-app/net-app-account/.test/nfs3/dependencies.bicep b/modules/net-app/net-app-account/.test/nfs3/dependencies.bicep index f360ac3c90..105ee6f541 100644 --- a/modules/net-app/net-app-account/.test/nfs3/dependencies.bicep +++ b/modules/net-app/net-app-account/.test/nfs3/dependencies.bicep @@ -9,37 +9,37 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] + } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + delegations: [ { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - delegations: [ - { - name: 'netappDel' - properties: { - serviceName: 'Microsoft.Netapp/volumes' - } - } - ] - } + name: 'netappDel' + properties: { + serviceName: 'Microsoft.Netapp/volumes' + } } - ] - } + ] + } + } + ] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/net-app/net-app-account/.test/nfs41/dependencies.bicep b/modules/net-app/net-app-account/.test/nfs41/dependencies.bicep index 624322e555..26b4c80d20 100644 --- a/modules/net-app/net-app-account/.test/nfs41/dependencies.bicep +++ b/modules/net-app/net-app-account/.test/nfs41/dependencies.bicep @@ -9,37 +9,37 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] + } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + delegations: [ { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - delegations: [ - { - name: 'netappDel' - properties: { - serviceName: 'Microsoft.Netapp/volumes' - } - } - ] - } + name: 'netappDel' + properties: { + serviceName: 'Microsoft.Netapp/volumes' + } } - ] - } + ] + } + } + ] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/network/application-gateway-web-application-firewall-policy/main.json b/modules/network/application-gateway-web-application-firewall-policy/main.json index 214820c936..bdb8d90260 100644 --- a/modules/network/application-gateway-web-application-firewall-policy/main.json +++ b/modules/network/application-gateway-web-application-firewall-policy/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12186382676600930554" - } + "version": "0.20.4.51522", + "templateHash": "9248935888816522277" + }, + "name": "Application Gateway Web Application Firewall (WAF) Policies", + "description": "This module deploys an Application Gateway Web Application Firewall (WAF) Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/network/application-gateway/.bicep/nested_roleAssignments.bicep b/modules/network/application-gateway/.bicep/nested_roleAssignments.bicep index 2af2190176..2bd352a75d 100644 --- a/modules/network/application-gateway/.bicep/nested_roleAssignments.bicep +++ b/modules/network/application-gateway/.bicep/nested_roleAssignments.bicep @@ -78,7 +78,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource applicationGateway 'Microsoft.Network/applicationGateways@2022-07-01' existing = { +resource applicationGateway 'Microsoft.Network/applicationGateways@2023-04-01' existing = { name: last(split(resourceId, '/'))! } diff --git a/modules/network/application-gateway/.test/common/dependencies.bicep b/modules/network/application-gateway/.test/common/dependencies.bicep index 46d1b47f0f..b0475399b4 100644 --- a/modules/network/application-gateway/.test/common/dependencies.bicep +++ b/modules/network/application-gateway/.test/common/dependencies.bicep @@ -18,87 +18,87 @@ param certDeploymentScriptName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } -resource publicIP 'Microsoft.Network/publicIPAddresses@2022-01-01' = { - name: publicIPName - location: location - sku: { - name: 'Standard' - tier: 'Regional' - } - properties: { - publicIPAllocationMethod: 'Static' - } +resource publicIP 'Microsoft.Network/publicIPAddresses@2023-04-01' = { + name: publicIPName + location: location + sku: { + name: 'Standard' + tier: 'Regional' + } + properties: { + publicIPAllocationMethod: 'Static' + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource keyVault 'Microsoft.KeyVault/vaults@2022-07-01' = { - name: keyVaultName - location: location - properties: { - sku: { - family: 'A' - name: 'standard' - } - tenantId: tenant().tenantId - enablePurgeProtection: null - enabledForTemplateDeployment: true - enabledForDiskEncryption: true - enabledForDeployment: true - enableRbacAuthorization: true - accessPolicies: [] + name: keyVaultName + location: location + properties: { + sku: { + family: 'A' + name: 'standard' } + tenantId: tenant().tenantId + enablePurgeProtection: null + enabledForTemplateDeployment: true + enabledForDiskEncryption: true + enabledForDeployment: true + enableRbacAuthorization: true + accessPolicies: [] + } } resource keyPermissions 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid('msi-${managedIdentity.name}-KeyVault-Admin-RoleAssignment') - scope: keyVault - properties: { - principalId: managedIdentity.properties.principalId - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '00482a5a-887f-4fb3-b363-3b7fe8e74483') // Key Vault Administrator - principalType: 'ServicePrincipal' - } + name: guid('msi-${managedIdentity.name}-KeyVault-Admin-RoleAssignment') + scope: keyVault + properties: { + principalId: managedIdentity.properties.principalId + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '00482a5a-887f-4fb3-b363-3b7fe8e74483') // Key Vault Administrator + principalType: 'ServicePrincipal' + } } resource certDeploymentScript 'Microsoft.Resources/deploymentScripts@2020-10-01' = { - name: certDeploymentScriptName - location: location - kind: 'AzurePowerShell' - identity: { - type: 'UserAssigned' - userAssignedIdentities: { - '${managedIdentity.id}': {} - } - } - properties: { - azPowerShellVersion: '8.0' - retentionInterval: 'P1D' - arguments: '-KeyVaultName "${keyVault.name}" -CertName "applicationGatewaySslCertificate"' - scriptContent: loadTextContent('../../../../.shared/.scripts/Set-CertificateInKeyVault.ps1') + name: certDeploymentScriptName + location: location + kind: 'AzurePowerShell' + identity: { + type: 'UserAssigned' + userAssignedIdentities: { + '${managedIdentity.id}': {} } + } + properties: { + azPowerShellVersion: '8.0' + retentionInterval: 'P1D' + arguments: '-KeyVaultName "${keyVault.name}" -CertName "applicationGatewaySslCertificate"' + scriptContent: loadTextContent('../../../../.shared/.scripts/Set-CertificateInKeyVault.ps1') + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/network/application-gateway/.test/common/main.test.bicep b/modules/network/application-gateway/.test/common/main.test.bicep index e735a7a896..c104f55dd6 100644 --- a/modules/network/application-gateway/.test/common/main.test.bicep +++ b/modules/network/application-gateway/.test/common/main.test.bicep @@ -116,7 +116,6 @@ module testDeployment '../../main.bicep' = { } } ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/network/application-gateway/README.md b/modules/network/application-gateway/README.md index ef200720f9..1030c5792e 100644 --- a/modules/network/application-gateway/README.md +++ b/modules/network/application-gateway/README.md @@ -17,7 +17,7 @@ This module deploys a Network Application Gateway. | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/applicationGateways` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/applicationGateways) | +| `Microsoft.Network/applicationGateways` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/applicationGateways) | ## Parameters @@ -42,7 +42,6 @@ This module deploys a Network Application Gateway. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, ApplicationGatewayAccessLog, ApplicationGatewayFirewallLog, ApplicationGatewayPerformanceLog]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub. | @@ -299,7 +298,6 @@ module applicationGateway './network/application-gateway/main.bicep' = { ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -701,9 +699,6 @@ module applicationGateway './network/application-gateway/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/network/application-gateway/main.bicep b/modules/network/application-gateway/main.bicep index 297f84a394..86c83ba8ad 100644 --- a/modules/network/application-gateway/main.bicep +++ b/modules/network/application-gateway/main.bicep @@ -177,11 +177,6 @@ param webApplicationFirewallConfiguration object = {} @description('Optional. A list of availability zones denoting where the resource needs to come from.') param zones array = [] -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub.') param diagnosticStorageAccountId string = '' @@ -227,20 +222,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -248,10 +235,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] @allowed([ @@ -292,7 +275,7 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource applicationGateway 'Microsoft.Network/applicationGateways@2022-07-01' = { +resource applicationGateway 'Microsoft.Network/applicationGateways@2023-04-01' = { name: name location: location tags: tags diff --git a/modules/network/application-gateway/main.json b/modules/network/application-gateway/main.json index c4c2d8a822..b63c0b3509 100644 --- a/modules/network/application-gateway/main.json +++ b/modules/network/application-gateway/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5397927094254711177" - } + "version": "0.20.4.51522", + "templateHash": "5018705520765822480" + }, + "name": "Network Application Gateways", + "description": "This module deploys a Network Application Gateway.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -196,8 +199,8 @@ "capacity": { "type": "int", "defaultValue": 2, - "maxValue": 10, "minValue": 1, + "maxValue": 10, "metadata": { "description": "Optional. The number of Application instances to be configured." } @@ -331,15 +334,6 @@ "description": "Optional. A list of availability zones denoting where the resource needs to come from." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -406,14 +400,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -465,11 +459,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -478,17 +468,13 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], "identityType": "[if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None')]", "identity": "[if(not(equals(variables('identityType'), 'None')), createObject('type', variables('identityType'), 'userAssignedIdentities', if(not(empty(parameters('userAssignedIdentities'))), parameters('userAssignedIdentities'), null())), null())]", - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" }, "resources": [ { @@ -507,7 +493,7 @@ }, { "type": "Microsoft.Network/applicationGateways", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -581,8 +567,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5212041204090731948" + "version": "0.20.4.51522", + "templateHash": "12763064958980402840" } }, "parameters": { @@ -752,7 +738,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/applicationGateways', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/applicationGateways', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/application-security-group/.bicep/nested_roleAssignments.bicep b/modules/network/application-security-group/.bicep/nested_roleAssignments.bicep index 5d36c19294..b349156bec 100644 --- a/modules/network/application-security-group/.bicep/nested_roleAssignments.bicep +++ b/modules/network/application-security-group/.bicep/nested_roleAssignments.bicep @@ -78,7 +78,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource applicationSecurityGroup 'Microsoft.Network/applicationSecurityGroups@2021-08-01' existing = { +resource applicationSecurityGroup 'Microsoft.Network/applicationSecurityGroups@2023-04-01' existing = { name: last(split(resourceId, '/'))! } diff --git a/modules/network/application-security-group/README.md b/modules/network/application-security-group/README.md index 0f6578986a..b9e9571422 100644 --- a/modules/network/application-security-group/README.md +++ b/modules/network/application-security-group/README.md @@ -16,7 +16,7 @@ This module deploys an Application Security Group (ASG). | :-- | :-- | | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | -| `Microsoft.Network/applicationSecurityGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/applicationSecurityGroups) | +| `Microsoft.Network/applicationSecurityGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/applicationSecurityGroups) | ## Parameters diff --git a/modules/network/application-security-group/main.bicep b/modules/network/application-security-group/main.bicep index e336c93c75..fa7054d1eb 100644 --- a/modules/network/application-security-group/main.bicep +++ b/modules/network/application-security-group/main.bicep @@ -37,7 +37,7 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource applicationSecurityGroup 'Microsoft.Network/applicationSecurityGroups@2022-07-01' = { +resource applicationSecurityGroup 'Microsoft.Network/applicationSecurityGroups@2023-04-01' = { name: name location: location tags: tags diff --git a/modules/network/application-security-group/main.json b/modules/network/application-security-group/main.json index 58d57c7b47..3b8e0b80ac 100644 --- a/modules/network/application-security-group/main.json +++ b/modules/network/application-security-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17250594128284307013" - } + "version": "0.20.4.51522", + "templateHash": "10906991942186771532" + }, + "name": "Application Security Groups (ASG)", + "description": "This module deploys an Application Security Group (ASG).", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -25,14 +28,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -73,7 +76,7 @@ }, { "type": "Microsoft.Network/applicationSecurityGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -127,8 +130,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15838105021656936169" + "version": "0.20.4.51522", + "templateHash": "2194807908259933046" } }, "parameters": { @@ -298,7 +301,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/applicationSecurityGroups', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/applicationSecurityGroups', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/azure-firewall/.bicep/nested_roleAssignments.bicep b/modules/network/azure-firewall/.bicep/nested_roleAssignments.bicep index 2f3b245340..cbed9e6958 100644 --- a/modules/network/azure-firewall/.bicep/nested_roleAssignments.bicep +++ b/modules/network/azure-firewall/.bicep/nested_roleAssignments.bicep @@ -78,7 +78,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource azureFirewall 'Microsoft.Network/azureFirewalls@2021-08-01' existing = { +resource azureFirewall 'Microsoft.Network/azureFirewalls@2023-04-01' existing = { name: last(split(resourceId, '/'))! } diff --git a/modules/network/azure-firewall/.test/addpip/dependencies.bicep b/modules/network/azure-firewall/.test/addpip/dependencies.bicep index 060f492b73..4992dd4893 100644 --- a/modules/network/azure-firewall/.test/addpip/dependencies.bicep +++ b/modules/network/azure-firewall/.test/addpip/dependencies.bicep @@ -14,52 +14,52 @@ var addressPrefix = '10.0.0.0/16' var addressPrefixDefaultSubnet = '10.0.0.0/20' var addressPrefixManagementSubnet = '10.0.16.0/20' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'AzureFirewallSubnet' - properties: { - addressPrefix: addressPrefixDefaultSubnet - } - } - { - name: 'AzureFirewallManagementSubnet' - properties: { - addressPrefix: addressPrefixManagementSubnet - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'AzureFirewallSubnet' + properties: { + addressPrefix: addressPrefixDefaultSubnet + } + } + { + name: 'AzureFirewallManagementSubnet' + properties: { + addressPrefix: addressPrefixManagementSubnet + } + } + ] + } } -resource publicIP 'Microsoft.Network/publicIPAddresses@2022-01-01' = { - name: publicIPName - location: location - sku: { - name: 'Standard' - tier: 'Regional' - } - properties: { - publicIPAllocationMethod: 'Static' - } - zones: [ - '1' - '2' - '3' - ] +resource publicIP 'Microsoft.Network/publicIPAddresses@2023-04-01' = { + name: publicIPName + location: location + sku: { + name: 'Standard' + tier: 'Regional' + } + properties: { + publicIPAllocationMethod: 'Static' + } + zones: [ + '1' + '2' + '3' + ] } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network.') diff --git a/modules/network/azure-firewall/.test/common/dependencies.bicep b/modules/network/azure-firewall/.test/common/dependencies.bicep index d8b4279427..c40eb887b4 100644 --- a/modules/network/azure-firewall/.test/common/dependencies.bicep +++ b/modules/network/azure-firewall/.test/common/dependencies.bicep @@ -12,46 +12,46 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'AzureFirewallSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'AzureFirewallSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } -resource publicIP 'Microsoft.Network/publicIPAddresses@2022-01-01' = { - name: publicIPName - location: location - sku: { - name: 'Standard' - tier: 'Regional' - } - properties: { - publicIPAllocationMethod: 'Static' - } - zones: [ - '1' - '2' - '3' - ] +resource publicIP 'Microsoft.Network/publicIPAddresses@2023-04-01' = { + name: publicIPName + location: location + sku: { + name: 'Standard' + tier: 'Regional' + } + properties: { + publicIPAllocationMethod: 'Static' + } + zones: [ + '1' + '2' + '3' + ] } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network.') diff --git a/modules/network/azure-firewall/.test/common/main.test.bicep b/modules/network/azure-firewall/.test/common/main.test.bicep index 49adde3d27..3e0a1db6cc 100644 --- a/modules/network/azure-firewall/.test/common/main.test.bicep +++ b/modules/network/azure-firewall/.test/common/main.test.bicep @@ -119,7 +119,6 @@ module testDeployment '../../main.bicep' = { } ] publicIPResourceID: nestedDependencies.outputs.publicIPResourceId - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/network/azure-firewall/.test/custompip/dependencies.bicep b/modules/network/azure-firewall/.test/custompip/dependencies.bicep index 1748a2e50c..231d6590bb 100644 --- a/modules/network/azure-firewall/.test/custompip/dependencies.bicep +++ b/modules/network/azure-firewall/.test/custompip/dependencies.bicep @@ -9,29 +9,29 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'AzureFirewallSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'AzureFirewallSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network.') diff --git a/modules/network/azure-firewall/.test/hubcommon/dependencies.bicep b/modules/network/azure-firewall/.test/hubcommon/dependencies.bicep index 4fe1ddd8c5..0dc2f1d9a2 100644 --- a/modules/network/azure-firewall/.test/hubcommon/dependencies.bicep +++ b/modules/network/azure-firewall/.test/hubcommon/dependencies.bicep @@ -10,7 +10,7 @@ param virtualHubName string @description('Required. The name of the Firewall Policy to create.') param firewallPolicyName string -resource virtualWan 'Microsoft.Network/virtualWans@2021-08-01' = { +resource virtualWan 'Microsoft.Network/virtualWans@2023-04-01' = { name: virtualWanName location: location properties: { @@ -31,7 +31,7 @@ resource virtualHub 'Microsoft.Network/virtualHubs@2021-08-01' = { } } -resource policy 'Microsoft.Network/firewallPolicies@2021-08-01' = { +resource policy 'Microsoft.Network/firewallPolicies@2023-04-01' = { name: firewallPolicyName location: location properties: { diff --git a/modules/network/azure-firewall/.test/hubmin/dependencies.bicep b/modules/network/azure-firewall/.test/hubmin/dependencies.bicep index 21324f286b..eceb77c39e 100644 --- a/modules/network/azure-firewall/.test/hubmin/dependencies.bicep +++ b/modules/network/azure-firewall/.test/hubmin/dependencies.bicep @@ -7,7 +7,7 @@ param virtualWanName string @description('Required. The name of the Virtual Hub to create.') param virtualHubName string -resource virtualWan 'Microsoft.Network/virtualWans@2021-08-01' = { +resource virtualWan 'Microsoft.Network/virtualWans@2023-04-01' = { name: virtualWanName location: location properties: { diff --git a/modules/network/azure-firewall/.test/min/dependencies.bicep b/modules/network/azure-firewall/.test/min/dependencies.bicep index bd6b937f6e..7e9226ea5d 100644 --- a/modules/network/azure-firewall/.test/min/dependencies.bicep +++ b/modules/network/azure-firewall/.test/min/dependencies.bicep @@ -6,24 +6,24 @@ param virtualNetworkName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'AzureFirewallSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'AzureFirewallSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } @description('The resource ID of the created Virtual Network.') output virtualNetworkResourceId string = virtualNetwork.id diff --git a/modules/network/azure-firewall/README.md b/modules/network/azure-firewall/README.md index 1b63fae853..f5cca12eaf 100644 --- a/modules/network/azure-firewall/README.md +++ b/modules/network/azure-firewall/README.md @@ -18,8 +18,8 @@ This module deploys an Azure Firewall. | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/azureFirewalls` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/azureFirewalls) | -| `Microsoft.Network/publicIPAddresses` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/publicIPAddresses) | +| `Microsoft.Network/azureFirewalls` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/azureFirewalls) | +| `Microsoft.Network/publicIPAddresses` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/publicIPAddresses) | ## Parameters @@ -47,7 +47,6 @@ This module deploys an Azure Firewall. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, AzureFirewallApplicationRule, AzureFirewallDnsProxy, AzureFirewallNetworkRule]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Diagnostic Storage Account resource identifier. | @@ -493,7 +492,6 @@ module azureFirewall './network/azure-firewall/main.bicep' = { ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -628,9 +626,6 @@ module azureFirewall './network/azure-firewall/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/network/azure-firewall/main.bicep b/modules/network/azure-firewall/main.bicep index cb6beb7e01..83e3b2a2af 100644 --- a/modules/network/azure-firewall/main.bicep +++ b/modules/network/azure-firewall/main.bicep @@ -73,11 +73,6 @@ param diagnosticStorageAccountId string = '' @description('Optional. Log Analytics workspace resource identifier.') param diagnosticWorkspaceId string = '' -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to.') param diagnosticEventHubAuthorizationRuleId string = '' @@ -199,20 +194,12 @@ var managementIPConfiguration = { var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -220,10 +207,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var enableReferencedModulesTelemetry = false @@ -260,7 +243,6 @@ module publicIPAddress '../../network/public-ip-address/main.bicep' = if (empty( ] location: location diagnosticStorageAccountId: diagnosticStorageAccountId - diagnosticLogsRetentionInDays: diagnosticLogsRetentionInDays diagnosticWorkspaceId: diagnosticWorkspaceId diagnosticEventHubAuthorizationRuleId: diagnosticEventHubAuthorizationRuleId diagnosticEventHubName: diagnosticEventHubName @@ -291,7 +273,6 @@ module managementIPAddress '../../network/public-ip-address/main.bicep' = if (em ] location: location diagnosticStorageAccountId: diagnosticStorageAccountId - diagnosticLogsRetentionInDays: diagnosticLogsRetentionInDays diagnosticWorkspaceId: diagnosticWorkspaceId diagnosticEventHubAuthorizationRuleId: diagnosticEventHubAuthorizationRuleId diagnosticEventHubName: diagnosticEventHubName @@ -302,7 +283,7 @@ module managementIPAddress '../../network/public-ip-address/main.bicep' = if (em } } -resource azureFirewall 'Microsoft.Network/azureFirewalls@2022-07-01' = { +resource azureFirewall 'Microsoft.Network/azureFirewalls@2023-04-01' = { name: name location: location zones: length(zones) == 0 ? null : zones diff --git a/modules/network/azure-firewall/main.json b/modules/network/azure-firewall/main.json index f36826b1bd..7e91e558dd 100644 --- a/modules/network/azure-firewall/main.json +++ b/modules/network/azure-firewall/main.json @@ -5,7 +5,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "9308869025215221965" + "templateHash": "16299423526459095141" }, "name": "Azure Firewalls", "description": "This module deploys an Azure Firewall.", @@ -158,15 +158,6 @@ "description": "Optional. Log Analytics workspace resource identifier." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "minValue": 0, - "maxValue": 365, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticEventHubAuthorizationRuleId": { "type": "string", "defaultValue": "", @@ -274,11 +265,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -287,11 +274,7 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], @@ -318,7 +301,7 @@ "id": "[parameters('managementIPResourceID')]" } }, - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "enableReferencedModulesTelemetry": false }, "resources": [ @@ -338,7 +321,7 @@ }, { "type": "Microsoft.Network/azureFirewalls", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "zones": "[if(equals(length(parameters('zones')), 0), null(), parameters('zones'))]", @@ -406,9 +389,6 @@ "diagnosticStorageAccountId": { "value": "[parameters('diagnosticStorageAccountId')]" }, - "diagnosticLogsRetentionInDays": { - "value": "[parameters('diagnosticLogsRetentionInDays')]" - }, "diagnosticWorkspaceId": { "value": "[parameters('diagnosticWorkspaceId')]" }, @@ -438,7 +418,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "14474619344547636171" + "templateHash": "7444990895328873286" }, "name": "Public IP Addresses", "description": "This module deploys a Public IP Address.", @@ -509,15 +489,6 @@ "description": "Optional. IP address version." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "minValue": 0, - "maxValue": 365, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -553,6 +524,20 @@ "description": "Optional. The domain name label. The concatenation of the domain name label and the regionalized DNS zone make up the fully qualified domain name associated with the public IP address. If a domain name label is specified, an A DNS record is created for the public IP in the Microsoft Azure DNS system." } }, + "domainNameLabelScope": { + "type": "string", + "defaultValue": "", + "allowedValues": [ + "", + "NoReuse", + "ResourceGroupReuse", + "SubscriptionReuse", + "TenantReuse" + ], + "metadata": { + "description": "Optional. The domain name label scope. If a domain name label and a domain name label scope are specified, an A DNS record is created for the public IP in the Microsoft Azure DNS system with a hashed value includes in FQDN." + } + }, "fqdn": { "type": "string", "defaultValue": "", @@ -650,11 +635,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -663,15 +644,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" }, "resources": [ { @@ -690,7 +667,7 @@ }, { "type": "Microsoft.Network/publicIPAddresses", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -700,7 +677,7 @@ }, "zones": "[parameters('zones')]", "properties": { - "dnsSettings": "[if(not(empty(parameters('domainNameLabel'))), createObject('domainNameLabel', parameters('domainNameLabel'), 'fqdn', parameters('fqdn'), 'reverseFqdn', parameters('reverseFqdn')), null())]", + "dnsSettings": "[if(not(empty(parameters('domainNameLabel'))), createObject('domainNameLabel', parameters('domainNameLabel'), 'domainNameLabelScope', parameters('domainNameLabelScope'), 'fqdn', parameters('fqdn'), 'reverseFqdn', parameters('reverseFqdn')), null())]", "publicIPAddressVersion": "[parameters('publicIPAddressVersion')]", "publicIPAllocationMethod": "[parameters('publicIPAllocationMethod')]", "publicIPPrefix": "[if(not(empty(parameters('publicIPPrefixResourceId'))), createObject('id', parameters('publicIPPrefixResourceId')), null())]", @@ -945,14 +922,14 @@ "metadata": { "description": "The public IP address of the public IP address resource." }, - "value": "[if(contains(reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2022-07-01'), 'ipAddress'), reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2022-07-01').ipAddress, '')]" + "value": "[if(contains(reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2023-04-01'), 'ipAddress'), reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2023-04-01').ipAddress, '')]" }, "location": { "type": "string", "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -983,9 +960,6 @@ "diagnosticStorageAccountId": { "value": "[parameters('diagnosticStorageAccountId')]" }, - "diagnosticLogsRetentionInDays": { - "value": "[parameters('diagnosticLogsRetentionInDays')]" - }, "diagnosticWorkspaceId": { "value": "[parameters('diagnosticWorkspaceId')]" }, @@ -1015,7 +989,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "14474619344547636171" + "templateHash": "7444990895328873286" }, "name": "Public IP Addresses", "description": "This module deploys a Public IP Address.", @@ -1086,15 +1060,6 @@ "description": "Optional. IP address version." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "minValue": 0, - "maxValue": 365, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -1130,6 +1095,20 @@ "description": "Optional. The domain name label. The concatenation of the domain name label and the regionalized DNS zone make up the fully qualified domain name associated with the public IP address. If a domain name label is specified, an A DNS record is created for the public IP in the Microsoft Azure DNS system." } }, + "domainNameLabelScope": { + "type": "string", + "defaultValue": "", + "allowedValues": [ + "", + "NoReuse", + "ResourceGroupReuse", + "SubscriptionReuse", + "TenantReuse" + ], + "metadata": { + "description": "Optional. The domain name label scope. If a domain name label and a domain name label scope are specified, an A DNS record is created for the public IP in the Microsoft Azure DNS system with a hashed value includes in FQDN." + } + }, "fqdn": { "type": "string", "defaultValue": "", @@ -1227,11 +1206,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -1240,15 +1215,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" }, "resources": [ { @@ -1267,7 +1238,7 @@ }, { "type": "Microsoft.Network/publicIPAddresses", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -1277,7 +1248,7 @@ }, "zones": "[parameters('zones')]", "properties": { - "dnsSettings": "[if(not(empty(parameters('domainNameLabel'))), createObject('domainNameLabel', parameters('domainNameLabel'), 'fqdn', parameters('fqdn'), 'reverseFqdn', parameters('reverseFqdn')), null())]", + "dnsSettings": "[if(not(empty(parameters('domainNameLabel'))), createObject('domainNameLabel', parameters('domainNameLabel'), 'domainNameLabelScope', parameters('domainNameLabelScope'), 'fqdn', parameters('fqdn'), 'reverseFqdn', parameters('reverseFqdn')), null())]", "publicIPAddressVersion": "[parameters('publicIPAddressVersion')]", "publicIPAllocationMethod": "[parameters('publicIPAllocationMethod')]", "publicIPPrefix": "[if(not(empty(parameters('publicIPPrefixResourceId'))), createObject('id', parameters('publicIPPrefixResourceId')), null())]", @@ -1522,14 +1493,14 @@ "metadata": { "description": "The public IP address of the public IP address resource." }, - "value": "[if(contains(reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2022-07-01'), 'ipAddress'), reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2022-07-01').ipAddress, '')]" + "value": "[if(contains(reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2023-04-01'), 'ipAddress'), reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2023-04-01').ipAddress, '')]" }, "location": { "type": "string", "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -1740,14 +1711,14 @@ "metadata": { "description": "The private IP of the Azure firewall." }, - "value": "[if(contains(reference(resourceId('Microsoft.Network/azureFirewalls', parameters('name')), '2022-07-01'), 'ipConfigurations'), reference(resourceId('Microsoft.Network/azureFirewalls', parameters('name')), '2022-07-01').ipConfigurations[0].properties.privateIPAddress, '')]" + "value": "[if(contains(reference(resourceId('Microsoft.Network/azureFirewalls', parameters('name')), '2023-04-01'), 'ipConfigurations'), reference(resourceId('Microsoft.Network/azureFirewalls', parameters('name')), '2023-04-01').ipConfigurations[0].properties.privateIPAddress, '')]" }, "ipConfAzureFirewallSubnet": { "type": "object", "metadata": { "description": "The Public IP configuration object for the Azure Firewall Subnet." }, - "value": "[if(contains(reference(resourceId('Microsoft.Network/azureFirewalls', parameters('name')), '2022-07-01'), 'ipConfigurations'), reference(resourceId('Microsoft.Network/azureFirewalls', parameters('name')), '2022-07-01').ipConfigurations[0], createObject())]" + "value": "[if(contains(reference(resourceId('Microsoft.Network/azureFirewalls', parameters('name')), '2023-04-01'), 'ipConfigurations'), reference(resourceId('Microsoft.Network/azureFirewalls', parameters('name')), '2023-04-01').ipConfigurations[0], createObject())]" }, "applicationRuleCollections": { "type": "array", @@ -1775,7 +1746,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/azureFirewalls', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/azureFirewalls', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/bastion-host/.test/common/dependencies.bicep b/modules/network/bastion-host/.test/common/dependencies.bicep index 24b87a6565..e0e57e9cde 100644 --- a/modules/network/bastion-host/.test/common/dependencies.bicep +++ b/modules/network/bastion-host/.test/common/dependencies.bicep @@ -12,41 +12,41 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-11-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'AzureBastionSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'AzureBastionSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } -resource publicIP 'Microsoft.Network/publicIPAddresses@2022-11-01' = { - name: publicIPName - location: location - sku: { - name: 'Standard' - tier: 'Regional' - } - properties: { - publicIPAllocationMethod: 'Static' - } +resource publicIP 'Microsoft.Network/publicIPAddresses@2023-04-01' = { + name: publicIPName + location: location + sku: { + name: 'Standard' + tier: 'Regional' + } + properties: { + publicIPAllocationMethod: 'Static' + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2023-01-31' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network.') diff --git a/modules/network/bastion-host/.test/common/main.test.bicep b/modules/network/bastion-host/.test/common/main.test.bicep index ed7b56b900..5086feb3dd 100644 --- a/modules/network/bastion-host/.test/common/main.test.bicep +++ b/modules/network/bastion-host/.test/common/main.test.bicep @@ -67,7 +67,6 @@ module testDeployment '../../main.bicep' = { name: '${namePrefix}${serviceShort}001' vNetId: nestedDependencies.outputs.virtualNetworkResourceId bastionSubnetPublicIpResourceId: nestedDependencies.outputs.publicIPResourceId - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/network/bastion-host/.test/custompip/dependencies.bicep b/modules/network/bastion-host/.test/custompip/dependencies.bicep index edaf073459..c3818c972a 100644 --- a/modules/network/bastion-host/.test/custompip/dependencies.bicep +++ b/modules/network/bastion-host/.test/custompip/dependencies.bicep @@ -9,29 +9,29 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-11-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'AzureBastionSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'AzureBastionSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2023-01-31' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network.') diff --git a/modules/network/bastion-host/.test/min/dependencies.bicep b/modules/network/bastion-host/.test/min/dependencies.bicep index e4c461ed0b..7bac5f6ba2 100644 --- a/modules/network/bastion-host/.test/min/dependencies.bicep +++ b/modules/network/bastion-host/.test/min/dependencies.bicep @@ -6,24 +6,24 @@ param virtualNetworkName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-11-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'AzureBastionSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'AzureBastionSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } @description('The resource ID of the created Virtual Network.') diff --git a/modules/network/bastion-host/README.md b/modules/network/bastion-host/README.md index 5e5c36581b..bdc13666af 100644 --- a/modules/network/bastion-host/README.md +++ b/modules/network/bastion-host/README.md @@ -18,7 +18,7 @@ This module deploys a Bastion Host. | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | | `Microsoft.Network/bastionHosts` | [2022-11-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-11-01/bastionHosts) | -| `Microsoft.Network/publicIPAddresses` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/publicIPAddresses) | +| `Microsoft.Network/publicIPAddresses` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/publicIPAddresses) | ## Parameters @@ -37,7 +37,6 @@ This module deploys a Bastion Host. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, BastionAuditLogs]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | | `diagnosticWorkspaceId` | string | `''` | | Resource ID of the diagnostic log analytics workspace. | @@ -320,7 +319,6 @@ module bastionHost './network/bastion-host/main.bicep' = { bastionSubnetPublicIpResourceId: '' diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' disableCopyPaste: true @@ -377,9 +375,6 @@ module bastionHost './network/bastion-host/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/network/bastion-host/main.bicep b/modules/network/bastion-host/main.bicep index 797177e37e..f0b0ea9427 100644 --- a/modules/network/bastion-host/main.bicep +++ b/modules/network/bastion-host/main.bicep @@ -20,11 +20,6 @@ param isCreateDefaultPublicIP bool = true @description('Optional. Specifies the properties of the Public IP to create and be used by Azure Bastion. If it\'s not provided and publicIPAddressResourceId is empty, a \'-pip\' suffix will be appended to the Bastion\'s name.') param publicIPAddressObject object = {} -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -95,20 +90,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -172,7 +159,6 @@ module publicIPAddress '../public-ip-address/main.bicep' = if (empty(bastionSubn 'AllMetrics' ] diagnosticStorageAccountId: diagnosticStorageAccountId - diagnosticLogsRetentionInDays: diagnosticLogsRetentionInDays diagnosticWorkspaceId: diagnosticWorkspaceId diagnosticEventHubAuthorizationRuleId: diagnosticEventHubAuthorizationRuleId diagnosticEventHubName: diagnosticEventHubName diff --git a/modules/network/bastion-host/main.json b/modules/network/bastion-host/main.json index 4dd4640366..141d9fccf5 100644 --- a/modules/network/bastion-host/main.json +++ b/modules/network/bastion-host/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7216068948381159464" - } + "version": "0.20.4.51522", + "templateHash": "419717336724554916" + }, + "name": "Bastion Hosts", + "description": "This module deploys a Bastion Host.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -49,15 +52,6 @@ "description": "Optional. Specifies the properties of the Public IP to create and be used by Azure Bastion. If it's not provided and publicIPAddressResourceId is empty, a '-pip' suffix will be appended to the Bastion's name." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -89,25 +83,25 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "skuName": { "type": "string", "defaultValue": "Basic", - "metadata": { - "description": "Optional. The SKU of this Bastion Host." - }, "allowedValues": [ "Basic", "Standard" - ] + ], + "metadata": { + "description": "Optional. The SKU of this Bastion Host." + } }, "disableCopyPaste": { "type": "bool", @@ -201,15 +195,11 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "enableTunneling": "[if(equals(parameters('skuName'), 'Standard'), true(), null())]", "scaleUnitsVar": "[if(equals(parameters('skuName'), 'Basic'), 2, parameters('scaleUnits'))]", "subnetVar": { @@ -301,9 +291,6 @@ "diagnosticStorageAccountId": { "value": "[parameters('diagnosticStorageAccountId')]" }, - "diagnosticLogsRetentionInDays": { - "value": "[parameters('diagnosticLogsRetentionInDays')]" - }, "diagnosticWorkspaceId": { "value": "[parameters('diagnosticWorkspaceId')]" }, @@ -339,9 +326,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1954871673414826097" - } + "version": "0.20.4.51522", + "templateHash": "7444990895328873286" + }, + "name": "Public IP Addresses", + "description": "This module deploys a Public IP Address.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -408,15 +398,6 @@ "description": "Optional. IP address version." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -452,6 +433,20 @@ "description": "Optional. The domain name label. The concatenation of the domain name label and the regionalized DNS zone make up the fully qualified domain name associated with the public IP address. If a domain name label is specified, an A DNS record is created for the public IP in the Microsoft Azure DNS system." } }, + "domainNameLabelScope": { + "type": "string", + "defaultValue": "", + "allowedValues": [ + "", + "NoReuse", + "ResourceGroupReuse", + "SubscriptionReuse", + "TenantReuse" + ], + "metadata": { + "description": "Optional. The domain name label scope. If a domain name label and a domain name label scope are specified, an A DNS record is created for the public IP in the Microsoft Azure DNS system with a hashed value includes in FQDN." + } + }, "fqdn": { "type": "string", "defaultValue": "", @@ -469,14 +464,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "location": { "type": "string", @@ -549,11 +544,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -562,15 +553,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" }, "resources": [ { @@ -589,7 +576,7 @@ }, { "type": "Microsoft.Network/publicIPAddresses", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -599,7 +586,7 @@ }, "zones": "[parameters('zones')]", "properties": { - "dnsSettings": "[if(not(empty(parameters('domainNameLabel'))), createObject('domainNameLabel', parameters('domainNameLabel'), 'fqdn', parameters('fqdn'), 'reverseFqdn', parameters('reverseFqdn')), null())]", + "dnsSettings": "[if(not(empty(parameters('domainNameLabel'))), createObject('domainNameLabel', parameters('domainNameLabel'), 'domainNameLabelScope', parameters('domainNameLabelScope'), 'fqdn', parameters('fqdn'), 'reverseFqdn', parameters('reverseFqdn')), null())]", "publicIPAddressVersion": "[parameters('publicIPAddressVersion')]", "publicIPAllocationMethod": "[parameters('publicIPAllocationMethod')]", "publicIPPrefix": "[if(not(empty(parameters('publicIPPrefixResourceId'))), createObject('id', parameters('publicIPPrefixResourceId')), null())]", @@ -673,8 +660,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7927074872480917952" + "version": "0.20.4.51522", + "templateHash": "11249227806125160411" } }, "parameters": { @@ -844,14 +831,14 @@ "metadata": { "description": "The public IP address of the public IP address resource." }, - "value": "[if(contains(reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2022-07-01'), 'ipAddress'), reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2022-07-01').ipAddress, '')]" + "value": "[if(contains(reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2023-04-01'), 'ipAddress'), reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2023-04-01').ipAddress, '')]" }, "location": { "type": "string", "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -891,8 +878,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12549213259153345965" + "version": "0.20.4.51522", + "templateHash": "14708512190775235887" } }, "parameters": { diff --git a/modules/network/connection/.test/vnet2vnet/dependencies.bicep b/modules/network/connection/.test/vnet2vnet/dependencies.bicep index fde57e7083..a8398dc99e 100644 --- a/modules/network/connection/.test/vnet2vnet/dependencies.bicep +++ b/modules/network/connection/.test/vnet2vnet/dependencies.bicep @@ -19,110 +19,110 @@ param secondaryVirtualNetworkName string @description('Required. The name of the secondary Virtual Network Gateway to create.') param secondaryVirtualNetworkGatewayName string -resource primaryVirtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: primaryVirtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - '10.0.0.0/24' - ] - } - subnets: [ - { - name: 'GatewaySubnet' - properties: { - addressPrefix: '10.0.0.0/24' - } - } - ] +resource primaryVirtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: primaryVirtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + '10.0.0.0/24' + ] } + subnets: [ + { + name: 'GatewaySubnet' + properties: { + addressPrefix: '10.0.0.0/24' + } + } + ] + } } -resource primaryPublicIP 'Microsoft.Network/publicIPAddresses@2022-01-01' = { - name: primaryPublicIPName - location: location +resource primaryPublicIP 'Microsoft.Network/publicIPAddresses@2023-04-01' = { + name: primaryPublicIPName + location: location } -resource primaryVNETGateway 'Microsoft.Network/virtualNetworkGateways@2021-08-01' = { - name: primaryVirtualNetworkGatewayName - location: location - properties: { - gatewayType: 'Vpn' - ipConfigurations: [ - { - name: 'default' - properties: { - privateIPAllocationMethod: 'Dynamic' - subnet: { - id: primaryVirtualNetwork.properties.subnets[0].id - } - publicIPAddress: { - id: primaryPublicIP.id - } - } - } - ] - vpnType: 'RouteBased' - vpnGatewayGeneration: 'Generation2' - sku: { - name: 'VpnGw2' - tier: 'VpnGw2' +resource primaryVNETGateway 'Microsoft.Network/virtualNetworkGateways@2023-04-01' = { + name: primaryVirtualNetworkGatewayName + location: location + properties: { + gatewayType: 'Vpn' + ipConfigurations: [ + { + name: 'default' + properties: { + privateIPAllocationMethod: 'Dynamic' + subnet: { + id: primaryVirtualNetwork.properties.subnets[0].id + } + publicIPAddress: { + id: primaryPublicIP.id + } } + } + ] + vpnType: 'RouteBased' + vpnGatewayGeneration: 'Generation2' + sku: { + name: 'VpnGw2' + tier: 'VpnGw2' } + } } -resource secondaryVirtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: secondaryVirtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - '10.0.1.0/24' - ] - } - subnets: [ - { - name: 'GatewaySubnet' - properties: { - addressPrefix: '10.0.1.0/24' - } - } - ] +resource secondaryVirtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: secondaryVirtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + '10.0.1.0/24' + ] } + subnets: [ + { + name: 'GatewaySubnet' + properties: { + addressPrefix: '10.0.1.0/24' + } + } + ] + } } -resource secondaryPublicIP 'Microsoft.Network/publicIPAddresses@2022-01-01' = { - name: secondaryPublicIPName - location: location +resource secondaryPublicIP 'Microsoft.Network/publicIPAddresses@2023-04-01' = { + name: secondaryPublicIPName + location: location } -resource secondaryVNETGateway 'Microsoft.Network/virtualNetworkGateways@2021-08-01' = { - name: secondaryVirtualNetworkGatewayName - location: location - properties: { - gatewayType: 'Vpn' - ipConfigurations: [ - { - name: 'default' - properties: { - privateIPAllocationMethod: 'Dynamic' - subnet: { - id: secondaryVirtualNetwork.properties.subnets[0].id - } - publicIPAddress: { - id: secondaryPublicIP.id - } - } - } - ] - vpnType: 'RouteBased' - vpnGatewayGeneration: 'Generation2' - sku: { - name: 'VpnGw2' - tier: 'VpnGw2' +resource secondaryVNETGateway 'Microsoft.Network/virtualNetworkGateways@2023-04-01' = { + name: secondaryVirtualNetworkGatewayName + location: location + properties: { + gatewayType: 'Vpn' + ipConfigurations: [ + { + name: 'default' + properties: { + privateIPAllocationMethod: 'Dynamic' + subnet: { + id: secondaryVirtualNetwork.properties.subnets[0].id + } + publicIPAddress: { + id: secondaryPublicIP.id + } } + } + ] + vpnType: 'RouteBased' + vpnGatewayGeneration: 'Generation2' + sku: { + name: 'VpnGw2' + tier: 'VpnGw2' } + } } @description('The resource ID of the created primary Virtual Network Gateway.') diff --git a/modules/network/connection/README.md b/modules/network/connection/README.md index 21fdbaed66..f580c1c56c 100644 --- a/modules/network/connection/README.md +++ b/modules/network/connection/README.md @@ -15,7 +15,7 @@ This module deploys a Virtual Network Gateway Connection. | Resource Type | API Version | | :-- | :-- | | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | -| `Microsoft.Network/connections` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/connections) | +| `Microsoft.Network/connections` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/connections) | ## Parameters diff --git a/modules/network/connection/main.bicep b/modules/network/connection/main.bicep index abc2155c02..ff8e21e11d 100644 --- a/modules/network/connection/main.bicep +++ b/modules/network/connection/main.bicep @@ -112,7 +112,7 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource connection 'Microsoft.Network/connections@2022-07-01' = { +resource connection 'Microsoft.Network/connections@2023-04-01' = { name: name location: location tags: tags diff --git a/modules/network/connection/main.json b/modules/network/connection/main.json index 63bdabc3cd..ab4bc4b45b 100644 --- a/modules/network/connection/main.json +++ b/modules/network/connection/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2301912117131465144" - } + "version": "0.20.4.51522", + "templateHash": "3912009667353652137" + }, + "name": "Virtual Network Gateway Connections", + "description": "This module deploys a Virtual Network Gateway Connection.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -52,34 +55,34 @@ "connectionMode": { "type": "string", "defaultValue": "Default", - "metadata": { - "description": "Optional. The connection connectionMode for this connection. Available for IPSec connections." - }, "allowedValues": [ "Default", "InitiatorOnly", "ResponderOnly" - ] + ], + "metadata": { + "description": "Optional. The connection connectionMode for this connection. Available for IPSec connections." + } }, "connectionProtocol": { "type": "string", "defaultValue": "IKEv2", - "metadata": { - "description": "Optional. Connection connectionProtocol used for this connection. Available for IPSec connections." - }, "allowedValues": [ "IKEv1", "IKEv2" - ] + ], + "metadata": { + "description": "Optional. Connection connectionProtocol used for this connection. Available for IPSec connections." + } }, "dpdTimeoutSeconds": { "type": "int", "defaultValue": 45, + "minValue": 9, + "maxValue": 3600, "metadata": { "description": "Optional. The dead peer detection timeout of this connection in seconds. Setting the timeout to shorter periods will cause IKE to rekey more aggressively, causing the connection to appear to be disconnected in some instances. The general recommendation is to set the timeout between 30 to 45 seconds." - }, - "maxValue": 3600, - "minValue": 9 + } }, "usePolicyBasedTrafficSelectors": { "type": "bool", @@ -135,14 +138,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the connectionType of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the connectionType of lock." + } }, "tags": { "type": "object", @@ -210,7 +213,7 @@ }, { "type": "Microsoft.Network/connections", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -276,7 +279,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/connections', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/connections', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/ddos-protection-plan/.bicep/nested_roleAssignments.bicep b/modules/network/ddos-protection-plan/.bicep/nested_roleAssignments.bicep index ae50048d7e..8cacd68005 100644 --- a/modules/network/ddos-protection-plan/.bicep/nested_roleAssignments.bicep +++ b/modules/network/ddos-protection-plan/.bicep/nested_roleAssignments.bicep @@ -78,7 +78,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource ddosProtectionPlan 'Microsoft.Network/ddosProtectionPlans@2022-07-01' existing = { +resource ddosProtectionPlan 'Microsoft.Network/ddosProtectionPlans@2023-04-01' existing = { name: last(split(resourceId, '/'))! } diff --git a/modules/network/ddos-protection-plan/README.md b/modules/network/ddos-protection-plan/README.md index 64bd627893..61f85a11ce 100644 --- a/modules/network/ddos-protection-plan/README.md +++ b/modules/network/ddos-protection-plan/README.md @@ -16,7 +16,7 @@ This module deploys a DDoS Protection Plan. | :-- | :-- | | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | -| `Microsoft.Network/ddosProtectionPlans` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/ddosProtectionPlans) | +| `Microsoft.Network/ddosProtectionPlans` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/ddosProtectionPlans) | ## Parameters diff --git a/modules/network/ddos-protection-plan/main.bicep b/modules/network/ddos-protection-plan/main.bicep index c9d337e1ed..159a71942f 100644 --- a/modules/network/ddos-protection-plan/main.bicep +++ b/modules/network/ddos-protection-plan/main.bicep @@ -38,7 +38,7 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource ddosProtectionPlan 'Microsoft.Network/ddosProtectionPlans@2022-07-01' = { +resource ddosProtectionPlan 'Microsoft.Network/ddosProtectionPlans@2023-04-01' = { name: name location: location tags: tags diff --git a/modules/network/ddos-protection-plan/main.json b/modules/network/ddos-protection-plan/main.json index 607193af3d..974c8d1067 100644 --- a/modules/network/ddos-protection-plan/main.json +++ b/modules/network/ddos-protection-plan/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13011445494121235150" - } + "version": "0.20.4.51522", + "templateHash": "4963707653962125969" + }, + "name": "DDoS Protection Plans", + "description": "This module deploys a DDoS Protection Plan.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -26,14 +29,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -74,7 +77,7 @@ }, { "type": "Microsoft.Network/ddosProtectionPlans", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -128,8 +131,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12286798680007657788" + "version": "0.20.4.51522", + "templateHash": "11204718740684669608" } }, "parameters": { @@ -299,7 +302,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/ddosProtectionPlans', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/ddosProtectionPlans', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/dns-forwarding-ruleset/.test/common/dependencies.bicep b/modules/network/dns-forwarding-ruleset/.test/common/dependencies.bicep index 787fa83d1e..59defd424f 100644 --- a/modules/network/dns-forwarding-ruleset/.test/common/dependencies.bicep +++ b/modules/network/dns-forwarding-ruleset/.test/common/dependencies.bicep @@ -14,7 +14,7 @@ var addressPrefix = '10.0.0.0/16' var pdnsinSnetAddressPrefix = '10.0.100.0/25' var pdnsoutSnetAddressPrefix = '10.0.100.128/25' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkName location: location properties: { diff --git a/modules/network/dns-forwarding-ruleset/.test/min/dependencies.bicep b/modules/network/dns-forwarding-ruleset/.test/min/dependencies.bicep index c5d7fcf3c9..46306c367c 100644 --- a/modules/network/dns-forwarding-ruleset/.test/min/dependencies.bicep +++ b/modules/network/dns-forwarding-ruleset/.test/min/dependencies.bicep @@ -7,7 +7,7 @@ param dnsResolverName string @description('Optional. The location to deploy resources to.') param location string = resourceGroup().location -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkName location: location properties: { diff --git a/modules/network/dns-forwarding-ruleset/forwarding-rule/main.json b/modules/network/dns-forwarding-ruleset/forwarding-rule/main.json index 281d30d4e8..4d23c6d66f 100644 --- a/modules/network/dns-forwarding-ruleset/forwarding-rule/main.json +++ b/modules/network/dns-forwarding-ruleset/forwarding-rule/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6763736224574178406" - } + "version": "0.20.4.51522", + "templateHash": "9007779430484184440" + }, + "name": "Dns Forwarding Rulesets Forwarding Rules", + "description": "This template deploys Forwarding Rule in a Dns Forwarding Ruleset.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/network/dns-forwarding-ruleset/main.json b/modules/network/dns-forwarding-ruleset/main.json index 94779370db..8835bcee3d 100644 --- a/modules/network/dns-forwarding-ruleset/main.json +++ b/modules/network/dns-forwarding-ruleset/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17944454305700070229" - } + "version": "0.20.4.51522", + "templateHash": "6357939502160422831" + }, + "name": "Dns Forwarding Rulesets", + "description": "This template deploys an dns forwarding ruleset.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -26,14 +29,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -160,9 +163,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6763736224574178406" - } + "version": "0.20.4.51522", + "templateHash": "9007779430484184440" + }, + "name": "Dns Forwarding Rulesets Forwarding Rules", + "description": "This template deploys Forwarding Rule in a Dns Forwarding Ruleset.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -304,9 +310,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1750882725233704055" - } + "version": "0.20.4.51522", + "templateHash": "13969101007511584177" + }, + "name": "Dns Forwarding Rulesets Virtual Network Links", + "description": "This template deploys Virtual Network Link in a Dns Forwarding Ruleset.", + "owner": "Azure/module-maintainers" }, "parameters": { "dnsForwardingRulesetName": { @@ -432,8 +441,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2022959906898437818" + "version": "0.20.4.51522", + "templateHash": "7949235653028892214" } }, "parameters": { diff --git a/modules/network/dns-forwarding-ruleset/virtual-network-link/main.json b/modules/network/dns-forwarding-ruleset/virtual-network-link/main.json index 26f54691c9..f41aa5933d 100644 --- a/modules/network/dns-forwarding-ruleset/virtual-network-link/main.json +++ b/modules/network/dns-forwarding-ruleset/virtual-network-link/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1750882725233704055" - } + "version": "0.20.4.51522", + "templateHash": "13969101007511584177" + }, + "name": "Dns Forwarding Rulesets Virtual Network Links", + "description": "This template deploys Virtual Network Link in a Dns Forwarding Ruleset.", + "owner": "Azure/module-maintainers" }, "parameters": { "dnsForwardingRulesetName": { diff --git a/modules/network/dns-resolver/.test/common/dependencies.bicep b/modules/network/dns-resolver/.test/common/dependencies.bicep index 8d3ff6c579..55f6162462 100644 --- a/modules/network/dns-resolver/.test/common/dependencies.bicep +++ b/modules/network/dns-resolver/.test/common/dependencies.bicep @@ -4,7 +4,7 @@ param virtualNetworkName string @description('Optional. The location to deploy resources to.') param location string = resourceGroup().location -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkName location: location properties: { diff --git a/modules/network/dns-resolver/main.json b/modules/network/dns-resolver/main.json index a7c864b88b..6f75e4048b 100644 --- a/modules/network/dns-resolver/main.json +++ b/modules/network/dns-resolver/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5917961660447616412" - } + "version": "0.20.4.51522", + "templateHash": "14340945341890605893" + }, + "name": "DNS Resolvers", + "description": "This module deploys a DNS Resolver.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -26,14 +29,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -194,8 +197,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5728481863995479341" + "version": "0.20.4.51522", + "templateHash": "8674983461017287842" } }, "parameters": { diff --git a/modules/network/dns-zone/a/main.json b/modules/network/dns-zone/a/main.json index 7e1b9ffad5..003161d55c 100644 --- a/modules/network/dns-zone/a/main.json +++ b/modules/network/dns-zone/a/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9656044135859018158" - } + "version": "0.20.4.51522", + "templateHash": "5170145363622927115" + }, + "name": "Public DNS Zone A record", + "description": "This module deploys a Public DNS Zone A record.", + "owner": "Azure/module-maintainers" }, "parameters": { "dnsZoneName": { @@ -124,8 +127,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5838800660531266266" + "version": "0.20.4.51522", + "templateHash": "3558751375290910792" } }, "parameters": { diff --git a/modules/network/dns-zone/aaaa/main.json b/modules/network/dns-zone/aaaa/main.json index 4220ba7c15..9bcf93a5ff 100644 --- a/modules/network/dns-zone/aaaa/main.json +++ b/modules/network/dns-zone/aaaa/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17289131489516532324" - } + "version": "0.20.4.51522", + "templateHash": "14783067103445567469" + }, + "name": "Public DNS Zone AAAA record", + "description": "This module deploys a Public DNS Zone AAAA record.", + "owner": "Azure/module-maintainers" }, "parameters": { "dnsZoneName": { @@ -124,8 +127,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "928652912604346892" + "version": "0.20.4.51522", + "templateHash": "10619447653791643982" } }, "parameters": { diff --git a/modules/network/dns-zone/caa/main.json b/modules/network/dns-zone/caa/main.json index 71d310a1fb..01174cacf6 100644 --- a/modules/network/dns-zone/caa/main.json +++ b/modules/network/dns-zone/caa/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4737667227541818959" - } + "version": "0.20.4.51522", + "templateHash": "4477853461523597510" + }, + "name": "Public DNS Zone CAA record", + "description": "This module deploys a Public DNS Zone CAA record.", + "owner": "Azure/module-maintainers" }, "parameters": { "dnsZoneName": { @@ -116,8 +119,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4833032307337861985" + "version": "0.20.4.51522", + "templateHash": "17740559314627874296" } }, "parameters": { diff --git a/modules/network/dns-zone/cname/main.json b/modules/network/dns-zone/cname/main.json index 94bdfc6243..4f413117dd 100644 --- a/modules/network/dns-zone/cname/main.json +++ b/modules/network/dns-zone/cname/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3316321683949899686" - } + "version": "0.20.4.51522", + "templateHash": "16690614046545500600" + }, + "name": "Public DNS Zone CNAME record", + "description": "This module deploys a Public DNS Zone CNAME record.", + "owner": "Azure/module-maintainers" }, "parameters": { "dnsZoneName": { @@ -124,8 +127,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12386507584642406479" + "version": "0.20.4.51522", + "templateHash": "1579300133069941204" } }, "parameters": { diff --git a/modules/network/dns-zone/main.json b/modules/network/dns-zone/main.json index 0a6b88cb9b..bca448b38d 100644 --- a/modules/network/dns-zone/main.json +++ b/modules/network/dns-zone/main.json @@ -4,15 +4,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16903388947644520567" - } + "version": "0.20.4.51522", + "templateHash": "6584518441041226458" + }, + "name": "Public DNS Zones", + "description": "This module deploys a Public DNS zone.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { "type": "string", - "maxLength": 63, "minLength": 1, + "maxLength": 63, "metadata": { "description": "Required. DNS zone name." } @@ -111,14 +114,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "enableDefaultTelemetry": { "type": "bool", @@ -205,9 +208,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9656044135859018158" - } + "version": "0.20.4.51522", + "templateHash": "5170145363622927115" + }, + "name": "Public DNS Zone A record", + "description": "This module deploys a Public DNS Zone A record.", + "owner": "Azure/module-maintainers" }, "parameters": { "dnsZoneName": { @@ -325,8 +331,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5838800660531266266" + "version": "0.20.4.51522", + "templateHash": "3558751375290910792" } }, "parameters": { @@ -533,9 +539,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17289131489516532324" - } + "version": "0.20.4.51522", + "templateHash": "14783067103445567469" + }, + "name": "Public DNS Zone AAAA record", + "description": "This module deploys a Public DNS Zone AAAA record.", + "owner": "Azure/module-maintainers" }, "parameters": { "dnsZoneName": { @@ -653,8 +662,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "928652912604346892" + "version": "0.20.4.51522", + "templateHash": "10619447653791643982" } }, "parameters": { @@ -861,9 +870,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3316321683949899686" - } + "version": "0.20.4.51522", + "templateHash": "16690614046545500600" + }, + "name": "Public DNS Zone CNAME record", + "description": "This module deploys a Public DNS Zone CNAME record.", + "owner": "Azure/module-maintainers" }, "parameters": { "dnsZoneName": { @@ -981,8 +993,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12386507584642406479" + "version": "0.20.4.51522", + "templateHash": "1579300133069941204" } }, "parameters": { @@ -1188,9 +1200,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4737667227541818959" - } + "version": "0.20.4.51522", + "templateHash": "4477853461523597510" + }, + "name": "Public DNS Zone CAA record", + "description": "This module deploys a Public DNS Zone CAA record.", + "owner": "Azure/module-maintainers" }, "parameters": { "dnsZoneName": { @@ -1300,8 +1315,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4833032307337861985" + "version": "0.20.4.51522", + "templateHash": "17740559314627874296" } }, "parameters": { @@ -1507,9 +1522,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5716130859187181927" - } + "version": "0.20.4.51522", + "templateHash": "14301321817801341159" + }, + "name": "Public DNS Zone MX record", + "description": "This module deploys a Public DNS Zone MX record.", + "owner": "Azure/module-maintainers" }, "parameters": { "dnsZoneName": { @@ -1619,8 +1637,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7481666858270434364" + "version": "0.20.4.51522", + "templateHash": "9536077061979113211" } }, "parameters": { @@ -1826,9 +1844,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16698471026179434287" - } + "version": "0.20.4.51522", + "templateHash": "13879924638868874443" + }, + "name": "Public DNS Zone NS record", + "description": "This module deploys a Public DNS Zone NS record.", + "owner": "Azure/module-maintainers" }, "parameters": { "dnsZoneName": { @@ -1938,8 +1959,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12862915302255804850" + "version": "0.20.4.51522", + "templateHash": "2717382131813837654" } }, "parameters": { @@ -2145,9 +2166,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18164536109323645020" - } + "version": "0.20.4.51522", + "templateHash": "14950916556855362521" + }, + "name": "Public DNS Zone PTR record", + "description": "This module deploys a Public DNS Zone PTR record.", + "owner": "Azure/module-maintainers" }, "parameters": { "dnsZoneName": { @@ -2257,8 +2281,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6672045440662548077" + "version": "0.20.4.51522", + "templateHash": "14048540340305231771" } }, "parameters": { @@ -2464,9 +2488,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18439593303689291072" - } + "version": "0.20.4.51522", + "templateHash": "15092776661272728734" + }, + "name": "Public DNS Zone SOA record", + "description": "This module deploys a Public DNS Zone SOA record.", + "owner": "Azure/module-maintainers" }, "parameters": { "dnsZoneName": { @@ -2576,8 +2603,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16683803953921655919" + "version": "0.20.4.51522", + "templateHash": "17247816691852004236" } }, "parameters": { @@ -2783,9 +2810,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2573308748570559876" - } + "version": "0.20.4.51522", + "templateHash": "2772370204362718864" + }, + "name": "Public DNS Zone SRV record", + "description": "This module deploys a Public DNS Zone SRV record.", + "owner": "Azure/module-maintainers" }, "parameters": { "dnsZoneName": { @@ -2895,8 +2925,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15357224405420155309" + "version": "0.20.4.51522", + "templateHash": "13880457002928639304" } }, "parameters": { @@ -3102,9 +3132,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7539598631188408331" - } + "version": "0.20.4.51522", + "templateHash": "16370550186541929198" + }, + "name": "Public DNS Zone TXT record", + "description": "This module deploys a Public DNS Zone TXT record.", + "owner": "Azure/module-maintainers" }, "parameters": { "dnsZoneName": { @@ -3214,8 +3247,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15382683460209888170" + "version": "0.20.4.51522", + "templateHash": "17843024796725206765" } }, "parameters": { @@ -3421,8 +3454,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18010354754861629753" + "version": "0.20.4.51522", + "templateHash": "12106058003619769842" } }, "parameters": { diff --git a/modules/network/dns-zone/mx/main.json b/modules/network/dns-zone/mx/main.json index eeaf472c7f..8b13e14708 100644 --- a/modules/network/dns-zone/mx/main.json +++ b/modules/network/dns-zone/mx/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5716130859187181927" - } + "version": "0.20.4.51522", + "templateHash": "14301321817801341159" + }, + "name": "Public DNS Zone MX record", + "description": "This module deploys a Public DNS Zone MX record.", + "owner": "Azure/module-maintainers" }, "parameters": { "dnsZoneName": { @@ -116,8 +119,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7481666858270434364" + "version": "0.20.4.51522", + "templateHash": "9536077061979113211" } }, "parameters": { diff --git a/modules/network/dns-zone/ns/main.json b/modules/network/dns-zone/ns/main.json index 3ed4aa90a8..39cbd138f6 100644 --- a/modules/network/dns-zone/ns/main.json +++ b/modules/network/dns-zone/ns/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16698471026179434287" - } + "version": "0.20.4.51522", + "templateHash": "13879924638868874443" + }, + "name": "Public DNS Zone NS record", + "description": "This module deploys a Public DNS Zone NS record.", + "owner": "Azure/module-maintainers" }, "parameters": { "dnsZoneName": { @@ -116,8 +119,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12862915302255804850" + "version": "0.20.4.51522", + "templateHash": "2717382131813837654" } }, "parameters": { diff --git a/modules/network/dns-zone/ptr/main.json b/modules/network/dns-zone/ptr/main.json index 6e049208c7..8e886f5e90 100644 --- a/modules/network/dns-zone/ptr/main.json +++ b/modules/network/dns-zone/ptr/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18164536109323645020" - } + "version": "0.20.4.51522", + "templateHash": "14950916556855362521" + }, + "name": "Public DNS Zone PTR record", + "description": "This module deploys a Public DNS Zone PTR record.", + "owner": "Azure/module-maintainers" }, "parameters": { "dnsZoneName": { @@ -116,8 +119,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6672045440662548077" + "version": "0.20.4.51522", + "templateHash": "14048540340305231771" } }, "parameters": { diff --git a/modules/network/dns-zone/soa/main.json b/modules/network/dns-zone/soa/main.json index c65fe90467..69744041ff 100644 --- a/modules/network/dns-zone/soa/main.json +++ b/modules/network/dns-zone/soa/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18439593303689291072" - } + "version": "0.20.4.51522", + "templateHash": "15092776661272728734" + }, + "name": "Public DNS Zone SOA record", + "description": "This module deploys a Public DNS Zone SOA record.", + "owner": "Azure/module-maintainers" }, "parameters": { "dnsZoneName": { @@ -116,8 +119,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16683803953921655919" + "version": "0.20.4.51522", + "templateHash": "17247816691852004236" } }, "parameters": { diff --git a/modules/network/dns-zone/srv/main.json b/modules/network/dns-zone/srv/main.json index cfec0f28be..6e3933b6ad 100644 --- a/modules/network/dns-zone/srv/main.json +++ b/modules/network/dns-zone/srv/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2573308748570559876" - } + "version": "0.20.4.51522", + "templateHash": "2772370204362718864" + }, + "name": "Public DNS Zone SRV record", + "description": "This module deploys a Public DNS Zone SRV record.", + "owner": "Azure/module-maintainers" }, "parameters": { "dnsZoneName": { @@ -116,8 +119,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15357224405420155309" + "version": "0.20.4.51522", + "templateHash": "13880457002928639304" } }, "parameters": { diff --git a/modules/network/dns-zone/txt/main.json b/modules/network/dns-zone/txt/main.json index 97e2c21b32..3cc94f1b0e 100644 --- a/modules/network/dns-zone/txt/main.json +++ b/modules/network/dns-zone/txt/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7539598631188408331" - } + "version": "0.20.4.51522", + "templateHash": "16370550186541929198" + }, + "name": "Public DNS Zone TXT record", + "description": "This module deploys a Public DNS Zone TXT record.", + "owner": "Azure/module-maintainers" }, "parameters": { "dnsZoneName": { @@ -116,8 +119,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15382683460209888170" + "version": "0.20.4.51522", + "templateHash": "17843024796725206765" } }, "parameters": { diff --git a/modules/network/express-route-circuit/.bicep/nested_roleAssignments.bicep b/modules/network/express-route-circuit/.bicep/nested_roleAssignments.bicep index cb466dbfb7..17c48155cf 100644 --- a/modules/network/express-route-circuit/.bicep/nested_roleAssignments.bicep +++ b/modules/network/express-route-circuit/.bicep/nested_roleAssignments.bicep @@ -78,7 +78,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource expressRouteCircuits 'Microsoft.Network/expressRouteCircuits@2021-08-01' existing = { +resource expressRouteCircuits 'Microsoft.Network/expressRouteCircuits@2023-04-01' existing = { name: last(split(resourceId, '/'))! } diff --git a/modules/network/express-route-circuit/.test/common/main.test.bicep b/modules/network/express-route-circuit/.test/common/main.test.bicep index b5994dbf43..a9770a8c30 100644 --- a/modules/network/express-route-circuit/.test/common/main.test.bicep +++ b/modules/network/express-route-circuit/.test/common/main.test.bicep @@ -66,7 +66,6 @@ module testDeployment '../../main.bicep' = { bandwidthInMbps: 50 peeringLocation: 'Amsterdam' serviceProviderName: 'Equinix' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/network/express-route-circuit/README.md b/modules/network/express-route-circuit/README.md index 051e689910..a37c149790 100644 --- a/modules/network/express-route-circuit/README.md +++ b/modules/network/express-route-circuit/README.md @@ -17,7 +17,7 @@ This module deploys an Express Route Circuit. | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/expressRouteCircuits` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/expressRouteCircuits) | +| `Microsoft.Network/expressRouteCircuits` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/expressRouteCircuits) | ## Parameters @@ -39,7 +39,6 @@ This module deploys an Express Route Circuit. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, PeeringRouteLog]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -202,7 +201,6 @@ module expressRouteCircuit './network/express-route-circuit/main.bicep' = { allowClassicOperations: true diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -261,9 +259,6 @@ module expressRouteCircuit './network/express-route-circuit/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/network/express-route-circuit/main.bicep b/modules/network/express-route-circuit/main.bicep index 253d9a7be8..f979f2c2e7 100644 --- a/modules/network/express-route-circuit/main.bicep +++ b/modules/network/express-route-circuit/main.bicep @@ -69,11 +69,6 @@ param expressRoutePortResourceId string = '' @description('Optional. Flag denoting global reach status. To enable ExpressRoute Global Reach between different geopolitical regions, your circuits must be Premium SKU.') param globalReachEnabled bool = false -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -127,20 +122,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -148,10 +135,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var peeringConfiguration = [ @@ -180,7 +163,7 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource expressRouteCircuits 'Microsoft.Network/expressRouteCircuits@2022-07-01' = { +resource expressRouteCircuits 'Microsoft.Network/expressRouteCircuits@2023-04-01' = { name: name location: location tags: tags diff --git a/modules/network/express-route-circuit/main.json b/modules/network/express-route-circuit/main.json index 635e3ddc17..0c1dd34102 100644 --- a/modules/network/express-route-circuit/main.json +++ b/modules/network/express-route-circuit/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12110219474007942587" - } + "version": "0.20.4.51522", + "templateHash": "2220842335649593450" + }, + "name": "ExpressRoute Circuits", + "description": "This module deploys an Express Route Circuit.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -144,15 +147,6 @@ "description": "Optional. Flag denoting global reach status. To enable ExpressRoute Global Reach between different geopolitical regions, your circuits must be Premium SKU." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -184,14 +178,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -255,11 +249,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -268,15 +258,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "peeringConfiguration": [ { "name": "[parameters('peeringType')]", @@ -308,7 +294,7 @@ }, { "type": "Microsoft.Network/expressRouteCircuits", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -396,8 +382,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4710829534363237072" + "version": "0.20.4.51522", + "templateHash": "3704217573510649158" } }, "parameters": { @@ -574,7 +560,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/expressRouteCircuits', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/expressRouteCircuits', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/express-route-gateway/.bicep/nested_roleAssignments.bicep b/modules/network/express-route-gateway/.bicep/nested_roleAssignments.bicep index 2af2190176..2bd352a75d 100644 --- a/modules/network/express-route-gateway/.bicep/nested_roleAssignments.bicep +++ b/modules/network/express-route-gateway/.bicep/nested_roleAssignments.bicep @@ -78,7 +78,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource applicationGateway 'Microsoft.Network/applicationGateways@2022-07-01' existing = { +resource applicationGateway 'Microsoft.Network/applicationGateways@2023-04-01' existing = { name: last(split(resourceId, '/'))! } diff --git a/modules/network/express-route-gateway/.test/common/dependencies.bicep b/modules/network/express-route-gateway/.test/common/dependencies.bicep index c865cb6910..0ddf2fe3b3 100644 --- a/modules/network/express-route-gateway/.test/common/dependencies.bicep +++ b/modules/network/express-route-gateway/.test/common/dependencies.bicep @@ -6,20 +6,20 @@ param virtualHubName string @description('Optional. The location to deploy resources to.') param location string = resourceGroup().location -resource virtualWan 'Microsoft.Network/virtualWans@2021-05-01' = { - name: virtualWANName - location: location +resource virtualWan 'Microsoft.Network/virtualWans@2023-04-01' = { + name: virtualWANName + location: location } -resource virtualHub 'Microsoft.Network/virtualHubs@2022-07-01' = { - name: virtualHubName - location: location - properties: { - addressPrefix: '10.0.0.0/16' - virtualWan: { - id: virtualWan.id - } +resource virtualHub 'Microsoft.Network/virtualHubs@2023-04-01' = { + name: virtualHubName + location: location + properties: { + addressPrefix: '10.0.0.0/16' + virtualWan: { + id: virtualWan.id } + } } @description('The resource ID of the created Virtual Hub.') diff --git a/modules/network/express-route-gateway/README.md b/modules/network/express-route-gateway/README.md index a545f8a6a2..b548883a79 100644 --- a/modules/network/express-route-gateway/README.md +++ b/modules/network/express-route-gateway/README.md @@ -14,7 +14,7 @@ This module deploys an Express Route Gateway. | Resource Type | API Version | | :-- | :-- | -| `Microsoft.Network/expressRouteGateways` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/expressRouteGateways) | +| `Microsoft.Network/expressRouteGateways` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/expressRouteGateways) | ## Parameters diff --git a/modules/network/express-route-gateway/main.bicep b/modules/network/express-route-gateway/main.bicep index df5b3b6d91..a435dde03f 100644 --- a/modules/network/express-route-gateway/main.bicep +++ b/modules/network/express-route-gateway/main.bicep @@ -41,7 +41,7 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource expressRouteGateway 'Microsoft.Network/expressRouteGateways@2022-07-01' = { +resource expressRouteGateway 'Microsoft.Network/expressRouteGateways@2023-04-01' = { name: name location: location tags: tags diff --git a/modules/network/express-route-gateway/main.json b/modules/network/express-route-gateway/main.json index 47cb450e7c..7039161434 100644 --- a/modules/network/express-route-gateway/main.json +++ b/modules/network/express-route-gateway/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1815800049558243200" - } + "version": "0.20.4.51522", + "templateHash": "10514926371607978717" + }, + "name": "Express Route Gateways", + "description": "This module deploys an Express Route Gateway.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -88,7 +91,7 @@ }, { "type": "Microsoft.Network/expressRouteGateways", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -134,7 +137,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/expressRouteGateways', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/expressRouteGateways', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/firewall-policy/README.md b/modules/network/firewall-policy/README.md index b61a8274a4..0147564584 100644 --- a/modules/network/firewall-policy/README.md +++ b/modules/network/firewall-policy/README.md @@ -14,8 +14,8 @@ This module deploys a Firewall Policy. | Resource Type | API Version | | :-- | :-- | -| `Microsoft.Network/firewallPolicies` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/firewallPolicies) | -| `Microsoft.Network/firewallPolicies/ruleCollectionGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/firewallPolicies/ruleCollectionGroups) | +| `Microsoft.Network/firewallPolicies` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/firewallPolicies) | +| `Microsoft.Network/firewallPolicies/ruleCollectionGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/firewallPolicies/ruleCollectionGroups) | ## Parameters diff --git a/modules/network/firewall-policy/main.bicep b/modules/network/firewall-policy/main.bicep index 1d1047a64b..13da1d1af1 100644 --- a/modules/network/firewall-policy/main.bicep +++ b/modules/network/firewall-policy/main.bicep @@ -117,7 +117,7 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource firewallPolicy 'Microsoft.Network/firewallPolicies@2022-07-01' = { +resource firewallPolicy 'Microsoft.Network/firewallPolicies@2023-04-01' = { name: name location: location tags: tags diff --git a/modules/network/firewall-policy/main.json b/modules/network/firewall-policy/main.json index eb88a21d7e..50d81e59f7 100644 --- a/modules/network/firewall-policy/main.json +++ b/modules/network/firewall-policy/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13879906363559654168" - } + "version": "0.20.4.51522", + "templateHash": "8941216473298209164" + }, + "name": "Firewall Policies", + "description": "This module deploys a Firewall Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -132,13 +135,13 @@ "autoLearnPrivateRanges": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. The operation mode for automatically learning private ranges to not be SNAT." - }, "allowedValues": [ "Disabled", "Enabled" - ] + ], + "metadata": { + "description": "Optional. The operation mode for automatically learning private ranges to not be SNAT." + } }, "threatIntelMode": { "type": "string", @@ -224,7 +227,7 @@ }, { "type": "Microsoft.Network/firewallPolicies", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -287,9 +290,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17712009459606794175" - } + "version": "0.20.4.51522", + "templateHash": "12741470915279971248" + }, + "name": "Firewall Policy Rule Collection Groups", + "description": "This module deploys a Firewall Policy Rule Collection Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "firewallPolicyName": { @@ -342,7 +348,7 @@ }, { "type": "Microsoft.Network/firewallPolicies/ruleCollectionGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('firewallPolicyName'), parameters('name'))]", "properties": { "priority": "[parameters('priority')]", @@ -407,7 +413,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/firewallPolicies', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/firewallPolicies', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/firewall-policy/rule-collection-group/README.md b/modules/network/firewall-policy/rule-collection-group/README.md index 4f73831639..9be45dfd53 100644 --- a/modules/network/firewall-policy/rule-collection-group/README.md +++ b/modules/network/firewall-policy/rule-collection-group/README.md @@ -13,7 +13,7 @@ This module deploys a Firewall Policy Rule Collection Group. | Resource Type | API Version | | :-- | :-- | -| `Microsoft.Network/firewallPolicies/ruleCollectionGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/firewallPolicies/ruleCollectionGroups) | +| `Microsoft.Network/firewallPolicies/ruleCollectionGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/firewallPolicies/ruleCollectionGroups) | ## Parameters diff --git a/modules/network/firewall-policy/rule-collection-group/main.bicep b/modules/network/firewall-policy/rule-collection-group/main.bicep index 1eb64dbdf4..f7a417981f 100644 --- a/modules/network/firewall-policy/rule-collection-group/main.bicep +++ b/modules/network/firewall-policy/rule-collection-group/main.bicep @@ -29,11 +29,11 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource firewallPolicy 'Microsoft.Network/firewallPolicies@2022-07-01' existing = { +resource firewallPolicy 'Microsoft.Network/firewallPolicies@2023-04-01' existing = { name: firewallPolicyName } -resource ruleCollectionGroup 'Microsoft.Network/firewallPolicies/ruleCollectionGroups@2022-07-01' = { +resource ruleCollectionGroup 'Microsoft.Network/firewallPolicies/ruleCollectionGroups@2023-04-01' = { name: name parent: firewallPolicy properties: { diff --git a/modules/network/firewall-policy/rule-collection-group/main.json b/modules/network/firewall-policy/rule-collection-group/main.json index 93c55d4422..f2abb4caf2 100644 --- a/modules/network/firewall-policy/rule-collection-group/main.json +++ b/modules/network/firewall-policy/rule-collection-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17712009459606794175" - } + "version": "0.20.4.51522", + "templateHash": "12741470915279971248" + }, + "name": "Firewall Policy Rule Collection Groups", + "description": "This module deploys a Firewall Policy Rule Collection Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "firewallPolicyName": { @@ -59,7 +62,7 @@ }, { "type": "Microsoft.Network/firewallPolicies/ruleCollectionGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('firewallPolicyName'), parameters('name'))]", "properties": { "priority": "[parameters('priority')]", diff --git a/modules/network/front-door/README.md b/modules/network/front-door/README.md index 99d21d9b11..7708e8c589 100644 --- a/modules/network/front-door/README.md +++ b/modules/network/front-door/README.md @@ -39,7 +39,6 @@ This module deploys an Azure Front Door. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, FrontdoorAccessLog, FrontdoorWebApplicationFirewallLog]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub. | | `diagnosticWorkspaceId` | string | `''` | | Resource ID of the diagnostic log analytics workspace. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub. | | `enableDefaultTelemetry` | bool | `True` | | Enable telemetry via a Globally Unique Identifier (GUID). | diff --git a/modules/network/front-door/main.bicep b/modules/network/front-door/main.bicep index 6e3eaa513b..fe4dac367a 100644 --- a/modules/network/front-door/main.bicep +++ b/modules/network/front-door/main.bicep @@ -55,11 +55,6 @@ param loadBalancingSettings array @description('Required. Routing rules settings of the frontdoor resource.') param routingRules array -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub.') param diagnosticStorageAccountId string = '' @@ -94,20 +89,12 @@ param metricsToEnable array = [ var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -115,10 +102,6 @@ var diagnosticsMetrics = [for metric in metricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (enableDefaultTelemetry) { diff --git a/modules/network/front-door/main.json b/modules/network/front-door/main.json index f1ccccb149..bcd114db31 100644 --- a/modules/network/front-door/main.json +++ b/modules/network/front-door/main.json @@ -4,15 +4,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14477404761572548237" - } + "version": "0.20.4.51522", + "templateHash": "14479303029874640056" + }, + "name": "Azure Front Doors", + "description": "This module deploys an Azure Front Door.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { "type": "string", - "maxLength": 64, "minLength": 1, + "maxLength": 64, "metadata": { "description": "Required. The name of the frontDoor." } @@ -27,14 +30,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -116,15 +119,6 @@ "description": "Required. Routing rules settings of the frontdoor resource." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -188,11 +182,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -201,15 +191,11 @@ "input": { "category": "[parameters('metricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" }, "resources": [ { @@ -312,8 +298,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12240281793388591156" + "version": "0.20.4.51522", + "templateHash": "7790989344899751422" } }, "parameters": { diff --git a/modules/network/ip-group/.bicep/nested_roleAssignments.bicep b/modules/network/ip-group/.bicep/nested_roleAssignments.bicep index 62ee58272d..cf16819442 100644 --- a/modules/network/ip-group/.bicep/nested_roleAssignments.bicep +++ b/modules/network/ip-group/.bicep/nested_roleAssignments.bicep @@ -78,7 +78,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource ipGroup 'Microsoft.Network/ipGroups@2022-07-01' existing = { +resource ipGroup 'Microsoft.Network/ipGroups@2023-04-01' existing = { name: last(split(resourceId, '/'))! } diff --git a/modules/network/ip-group/README.md b/modules/network/ip-group/README.md index 6ada26e4ac..fcd18f33c1 100644 --- a/modules/network/ip-group/README.md +++ b/modules/network/ip-group/README.md @@ -16,7 +16,7 @@ This module deploys an IP Group. | :-- | :-- | | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | -| `Microsoft.Network/ipGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/ipGroups) | +| `Microsoft.Network/ipGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/ipGroups) | ## Parameters diff --git a/modules/network/ip-group/main.bicep b/modules/network/ip-group/main.bicep index cbf5e1f3d1..b9a45120cd 100644 --- a/modules/network/ip-group/main.bicep +++ b/modules/network/ip-group/main.bicep @@ -41,7 +41,7 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource ipGroup 'Microsoft.Network/ipGroups@2022-07-01' = { +resource ipGroup 'Microsoft.Network/ipGroups@2023-04-01' = { name: name location: location tags: tags diff --git a/modules/network/ip-group/main.json b/modules/network/ip-group/main.json index 0519060014..1a45ccd984 100644 --- a/modules/network/ip-group/main.json +++ b/modules/network/ip-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14054150072203383023" - } + "version": "0.20.4.51522", + "templateHash": "5323472559339531565" + }, + "name": "IP Groups", + "description": "This module deploys an IP Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -33,14 +36,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -81,7 +84,7 @@ }, { "type": "Microsoft.Network/ipGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -137,8 +140,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17919828349291708949" + "version": "0.20.4.51522", + "templateHash": "15974868910769237968" } }, "parameters": { @@ -308,7 +311,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/ipGroups', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/ipGroups', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/load-balancer/.bicep/nested_roleAssignments.bicep b/modules/network/load-balancer/.bicep/nested_roleAssignments.bicep index 3972bf7c74..f92b1683cf 100644 --- a/modules/network/load-balancer/.bicep/nested_roleAssignments.bicep +++ b/modules/network/load-balancer/.bicep/nested_roleAssignments.bicep @@ -78,7 +78,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource loadBalancer 'Microsoft.Network/loadBalancers@2021-08-01' existing = { +resource loadBalancer 'Microsoft.Network/loadBalancers@2023-04-01' existing = { name: last(split(resourceId, '/'))! } diff --git a/modules/network/load-balancer/.test/common/dependencies.bicep b/modules/network/load-balancer/.test/common/dependencies.bicep index c435b9706a..c54f364b82 100644 --- a/modules/network/load-balancer/.test/common/dependencies.bicep +++ b/modules/network/load-balancer/.test/common/dependencies.bicep @@ -7,26 +7,26 @@ param publicIPName string @description('Required. The name of the Managed Identity to create.') param managedIdentityName string -resource publicIP 'Microsoft.Network/publicIPAddresses@2022-01-01' = { - name: publicIPName - location: location - sku: { - name: 'Standard' - tier: 'Regional' - } - properties: { - publicIPAllocationMethod: 'Static' - } - zones: [ - '1' - '2' - '3' - ] +resource publicIP 'Microsoft.Network/publicIPAddresses@2023-04-01' = { + name: publicIPName + location: location + sku: { + name: 'Standard' + tier: 'Regional' + } + properties: { + publicIPAllocationMethod: 'Static' + } + zones: [ + '1' + '2' + '3' + ] } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Public IP.') diff --git a/modules/network/load-balancer/.test/common/main.test.bicep b/modules/network/load-balancer/.test/common/main.test.bicep index 526fb4b161..0ad2ff1ec7 100644 --- a/modules/network/load-balancer/.test/common/main.test.bicep +++ b/modules/network/load-balancer/.test/common/main.test.bicep @@ -78,7 +78,6 @@ module testDeployment '../../main.bicep' = { name: 'backendAddressPool2' } ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/network/load-balancer/.test/internal/dependencies.bicep b/modules/network/load-balancer/.test/internal/dependencies.bicep index a0ce801b74..6e3ab14105 100644 --- a/modules/network/load-balancer/.test/internal/dependencies.bicep +++ b/modules/network/load-balancer/.test/internal/dependencies.bicep @@ -9,29 +9,29 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/network/load-balancer/.test/internal/main.test.bicep b/modules/network/load-balancer/.test/internal/main.test.bicep index 55e1de8d6e..b7f877c493 100644 --- a/modules/network/load-balancer/.test/internal/main.test.bicep +++ b/modules/network/load-balancer/.test/internal/main.test.bicep @@ -75,7 +75,6 @@ module testDeployment '../../main.bicep' = { name: 'servers' } ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/network/load-balancer/.test/min/dependencies.bicep b/modules/network/load-balancer/.test/min/dependencies.bicep index 6f05edd3d6..54ec47a195 100644 --- a/modules/network/load-balancer/.test/min/dependencies.bicep +++ b/modules/network/load-balancer/.test/min/dependencies.bicep @@ -4,21 +4,21 @@ param location string = resourceGroup().location @description('Required. The name of the Public IP to create.') param publicIPName string -resource publicIP 'Microsoft.Network/publicIPAddresses@2022-01-01' = { - name: publicIPName - location: location - sku: { - name: 'Standard' - tier: 'Regional' - } - properties: { - publicIPAllocationMethod: 'Static' - } - zones: [ - '1' - '2' - '3' - ] +resource publicIP 'Microsoft.Network/publicIPAddresses@2023-04-01' = { + name: publicIPName + location: location + sku: { + name: 'Standard' + tier: 'Regional' + } + properties: { + publicIPAllocationMethod: 'Static' + } + zones: [ + '1' + '2' + '3' + ] } @description('The resource ID of the created Public IP.') diff --git a/modules/network/load-balancer/README.md b/modules/network/load-balancer/README.md index 624a38a950..08ec47fbae 100644 --- a/modules/network/load-balancer/README.md +++ b/modules/network/load-balancer/README.md @@ -17,9 +17,9 @@ This module deploys a Load Balancer. | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/loadBalancers` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/loadBalancers) | -| `Microsoft.Network/loadBalancers/backendAddressPools` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/loadBalancers/backendAddressPools) | -| `Microsoft.Network/loadBalancers/inboundNatRules` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/loadBalancers/inboundNatRules) | +| `Microsoft.Network/loadBalancers` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/loadBalancers) | +| `Microsoft.Network/loadBalancers/backendAddressPools` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/loadBalancers/backendAddressPools) | +| `Microsoft.Network/loadBalancers/inboundNatRules` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/loadBalancers/inboundNatRules) | ## Parameters @@ -37,7 +37,6 @@ This module deploys a Load Balancer. | `backendAddressPools` | array | `[]` | | Collection of backend address pools used by a load balancer. | | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -500,7 +499,6 @@ module loadBalancer './network/load-balancer/main.bicep' = { ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -629,9 +627,6 @@ module loadBalancer './network/load-balancer/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, @@ -768,7 +763,6 @@ module loadBalancer './network/load-balancer/main.bicep' = { ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -871,9 +865,6 @@ module loadBalancer './network/load-balancer/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/network/load-balancer/backend-address-pool/README.md b/modules/network/load-balancer/backend-address-pool/README.md index 70eb4a0cad..44dfdef1f7 100644 --- a/modules/network/load-balancer/backend-address-pool/README.md +++ b/modules/network/load-balancer/backend-address-pool/README.md @@ -13,7 +13,7 @@ This module deploys a Load Balancer Backend Address Pools. | Resource Type | API Version | | :-- | :-- | -| `Microsoft.Network/loadBalancers/backendAddressPools` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/loadBalancers/backendAddressPools) | +| `Microsoft.Network/loadBalancers/backendAddressPools` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/loadBalancers/backendAddressPools) | ## Parameters @@ -31,12 +31,13 @@ This module deploys a Load Balancer Backend Address Pools. **Optional parameters** -| Parameter Name | Type | Default Value | Description | -| :-- | :-- | :-- | :-- | -| `drainPeriodInSeconds` | int | `0` | Amount of seconds Load Balancer waits for before sending RESET to client and backend address. if value is 0 then this property will be set to null. Subscription must register the feature Microsoft.Network/SLBAllowConnectionDraining before using this property. | -| `enableDefaultTelemetry` | bool | `True` | Enable telemetry via a Globally Unique Identifier (GUID). | -| `loadBalancerBackendAddresses` | array | `[]` | An array of backend addresses. | -| `tunnelInterfaces` | array | `[]` | An array of gateway load balancer tunnel interfaces. | +| Parameter Name | Type | Default Value | Allowed Values | Description | +| :-- | :-- | :-- | :-- | :-- | +| `drainPeriodInSeconds` | int | `0` | | Amount of seconds Load Balancer waits for before sending RESET to client and backend address. if value is 0 then this property will be set to null. Subscription must register the feature Microsoft.Network/SLBAllowConnectionDraining before using this property. | +| `enableDefaultTelemetry` | bool | `True` | | Enable telemetry via a Globally Unique Identifier (GUID). | +| `loadBalancerBackendAddresses` | array | `[]` | | An array of backend addresses. | +| `syncMode` | string | `''` | `['', Automatic, Manual]` | Backend address synchronous mode for the backend pool. | +| `tunnelInterfaces` | array | `[]` | | An array of gateway load balancer tunnel interfaces. | ## Outputs diff --git a/modules/network/load-balancer/backend-address-pool/main.bicep b/modules/network/load-balancer/backend-address-pool/main.bicep index c7cf6525fe..3a06064bc0 100644 --- a/modules/network/load-balancer/backend-address-pool/main.bicep +++ b/modules/network/load-balancer/backend-address-pool/main.bicep @@ -17,6 +17,14 @@ param tunnelInterfaces array = [] @description('Optional. Amount of seconds Load Balancer waits for before sending RESET to client and backend address. if value is 0 then this property will be set to null. Subscription must register the feature Microsoft.Network/SLBAllowConnectionDraining before using this property.') param drainPeriodInSeconds int = 0 +@allowed([ + '' + 'Automatic' + 'Manual' +]) +@description('Optional. Backend address synchronous mode for the backend pool.') +param syncMode string = '' + @description('Optional. Enable telemetry via a Globally Unique Identifier (GUID).') param enableDefaultTelemetry bool = true @@ -32,16 +40,17 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource loadBalancer 'Microsoft.Network/loadBalancers@2021-08-01' existing = { +resource loadBalancer 'Microsoft.Network/loadBalancers@2023-04-01' existing = { name: loadBalancerName } -resource backendAddressPool 'Microsoft.Network/loadBalancers/backendAddressPools@2022-07-01' = { +resource backendAddressPool 'Microsoft.Network/loadBalancers/backendAddressPools@2023-04-01' = { name: name properties: { loadBalancerBackendAddresses: loadBalancerBackendAddresses tunnelInterfaces: tunnelInterfaces drainPeriodInSeconds: drainPeriodInSeconds != 0 ? drainPeriodInSeconds : null + syncMode: !empty(syncMode) ? syncMode : null } parent: loadBalancer } diff --git a/modules/network/load-balancer/backend-address-pool/main.json b/modules/network/load-balancer/backend-address-pool/main.json index 7caefecb97..4c67067b1a 100644 --- a/modules/network/load-balancer/backend-address-pool/main.json +++ b/modules/network/load-balancer/backend-address-pool/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9987210976096685266" - } + "version": "0.20.4.51522", + "templateHash": "14919070901241549953" + }, + "name": "Load Balancer Backend Address Pools", + "description": "This module deploys a Load Balancer Backend Address Pools.", + "owner": "Azure/module-maintainers" }, "parameters": { "loadBalancerName": { @@ -42,6 +45,18 @@ "description": "Optional. Amount of seconds Load Balancer waits for before sending RESET to client and backend address. if value is 0 then this property will be set to null. Subscription must register the feature Microsoft.Network/SLBAllowConnectionDraining before using this property." } }, + "syncMode": { + "type": "string", + "defaultValue": "", + "allowedValues": [ + "", + "Automatic", + "Manual" + ], + "metadata": { + "description": "Optional. Backend address synchronous mode for the backend pool." + } + }, "enableDefaultTelemetry": { "type": "bool", "defaultValue": true, @@ -67,12 +82,13 @@ }, { "type": "Microsoft.Network/loadBalancers/backendAddressPools", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('loadBalancerName'), parameters('name'))]", "properties": { "loadBalancerBackendAddresses": "[parameters('loadBalancerBackendAddresses')]", "tunnelInterfaces": "[parameters('tunnelInterfaces')]", - "drainPeriodInSeconds": "[if(not(equals(parameters('drainPeriodInSeconds'), 0)), parameters('drainPeriodInSeconds'), null())]" + "drainPeriodInSeconds": "[if(not(equals(parameters('drainPeriodInSeconds'), 0)), parameters('drainPeriodInSeconds'), null())]", + "syncMode": "[if(not(empty(parameters('syncMode'))), parameters('syncMode'), null())]" } } ], diff --git a/modules/network/load-balancer/inbound-nat-rule/README.md b/modules/network/load-balancer/inbound-nat-rule/README.md index 49cd436de4..c26aee6bf8 100644 --- a/modules/network/load-balancer/inbound-nat-rule/README.md +++ b/modules/network/load-balancer/inbound-nat-rule/README.md @@ -13,7 +13,7 @@ This module deploys a Load Balancer Inbound NAT Rules. | Resource Type | API Version | | :-- | :-- | -| `Microsoft.Network/loadBalancers/inboundNatRules` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/loadBalancers/inboundNatRules) | +| `Microsoft.Network/loadBalancers/inboundNatRules` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/loadBalancers/inboundNatRules) | ## Parameters diff --git a/modules/network/load-balancer/inbound-nat-rule/main.bicep b/modules/network/load-balancer/inbound-nat-rule/main.bicep index b2dff436a6..0025ec40b4 100644 --- a/modules/network/load-balancer/inbound-nat-rule/main.bicep +++ b/modules/network/load-balancer/inbound-nat-rule/main.bicep @@ -66,11 +66,11 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource loadBalancer 'Microsoft.Network/loadBalancers@2022-07-01' existing = { +resource loadBalancer 'Microsoft.Network/loadBalancers@2023-04-01' existing = { name: loadBalancerName } -resource inboundNatRule 'Microsoft.Network/loadBalancers/inboundNatRules@2022-07-01' = { +resource inboundNatRule 'Microsoft.Network/loadBalancers/inboundNatRules@2023-04-01' = { name: name properties: { frontendPort: frontendPort diff --git a/modules/network/load-balancer/inbound-nat-rule/main.json b/modules/network/load-balancer/inbound-nat-rule/main.json index 027d2797d8..e340a35b19 100644 --- a/modules/network/load-balancer/inbound-nat-rule/main.json +++ b/modules/network/load-balancer/inbound-nat-rule/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16462838100949743192" - } + "version": "0.20.4.51522", + "templateHash": "17563889842244498787" + }, + "name": "Load Balancer Inbound NAT Rules", + "description": "This module deploys a Load Balancer Inbound NAT Rules.", + "owner": "Azure/module-maintainers" }, "parameters": { "loadBalancerName": { @@ -23,8 +26,8 @@ }, "frontendPort": { "type": "int", - "maxValue": 65534, "minValue": 1, + "maxValue": 65534, "metadata": { "description": "Required. The port for the external endpoint. Port numbers for each rule must be unique within the Load Balancer." } @@ -32,8 +35,8 @@ "backendPort": { "type": "int", "defaultValue": "[parameters('frontendPort')]", - "maxValue": 65535, "minValue": 1, + "maxValue": 65535, "metadata": { "description": "Optional. The port used for the internal endpoint." } @@ -68,8 +71,8 @@ "frontendPortRangeEnd": { "type": "int", "defaultValue": -1, - "maxValue": 65534, "minValue": -1, + "maxValue": 65534, "metadata": { "description": "Optional. The port range end for the external endpoint. This property is used together with BackendAddressPool and FrontendPortRangeStart. Individual inbound NAT rule port mappings will be created for each backend address from BackendAddressPool." } @@ -77,8 +80,8 @@ "frontendPortRangeStart": { "type": "int", "defaultValue": -1, - "maxValue": 65534, "minValue": -1, + "maxValue": 65534, "metadata": { "description": "Optional. The port range start for the external endpoint. This property is used together with BackendAddressPool and FrontendPortRangeEnd. Individual inbound NAT rule port mappings will be created for each backend address from BackendAddressPool." } @@ -127,7 +130,7 @@ }, { "type": "Microsoft.Network/loadBalancers/inboundNatRules", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('loadBalancerName'), parameters('name'))]", "properties": { "frontendPort": "[parameters('frontendPort')]", diff --git a/modules/network/load-balancer/main.bicep b/modules/network/load-balancer/main.bicep index 704f5029de..0f15931f27 100644 --- a/modules/network/load-balancer/main.bicep +++ b/modules/network/load-balancer/main.bicep @@ -28,11 +28,6 @@ param loadBalancingRules array = [] @description('Optional. Array of objects containing all probes, these are references in the load balancing rules.') param probes array = [] -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -162,10 +157,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (enableDefaultTelemetry) { @@ -180,7 +171,7 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource loadBalancer 'Microsoft.Network/loadBalancers@2022-07-01' = { +resource loadBalancer 'Microsoft.Network/loadBalancers@2023-04-01' = { name: name location: location tags: tags diff --git a/modules/network/load-balancer/main.json b/modules/network/load-balancer/main.json index da8502c8a6..bfc262efa4 100644 --- a/modules/network/load-balancer/main.json +++ b/modules/network/load-balancer/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5264258087440913796" - } + "version": "0.20.4.51522", + "templateHash": "6749534664336375393" + }, + "name": "Load Balancers", + "description": "This module deploys a Load Balancer.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -61,15 +64,6 @@ "description": "Optional. Array of objects containing all probes, these are references in the load balancing rules." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -101,14 +95,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -257,11 +251,7 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], @@ -284,7 +274,7 @@ }, { "type": "Microsoft.Network/loadBalancers", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -363,9 +353,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9987210976096685266" - } + "version": "0.20.4.51522", + "templateHash": "14919070901241549953" + }, + "name": "Load Balancer Backend Address Pools", + "description": "This module deploys a Load Balancer Backend Address Pools.", + "owner": "Azure/module-maintainers" }, "parameters": { "loadBalancerName": { @@ -401,6 +394,18 @@ "description": "Optional. Amount of seconds Load Balancer waits for before sending RESET to client and backend address. if value is 0 then this property will be set to null. Subscription must register the feature Microsoft.Network/SLBAllowConnectionDraining before using this property." } }, + "syncMode": { + "type": "string", + "defaultValue": "", + "allowedValues": [ + "", + "Automatic", + "Manual" + ], + "metadata": { + "description": "Optional. Backend address synchronous mode for the backend pool." + } + }, "enableDefaultTelemetry": { "type": "bool", "defaultValue": true, @@ -426,12 +431,13 @@ }, { "type": "Microsoft.Network/loadBalancers/backendAddressPools", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('loadBalancerName'), parameters('name'))]", "properties": { "loadBalancerBackendAddresses": "[parameters('loadBalancerBackendAddresses')]", "tunnelInterfaces": "[parameters('tunnelInterfaces')]", - "drainPeriodInSeconds": "[if(not(equals(parameters('drainPeriodInSeconds'), 0)), parameters('drainPeriodInSeconds'), null())]" + "drainPeriodInSeconds": "[if(not(equals(parameters('drainPeriodInSeconds'), 0)), parameters('drainPeriodInSeconds'), null())]", + "syncMode": "[if(not(empty(parameters('syncMode'))), parameters('syncMode'), null())]" } } ], @@ -508,9 +514,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16462838100949743192" - } + "version": "0.20.4.51522", + "templateHash": "17563889842244498787" + }, + "name": "Load Balancer Inbound NAT Rules", + "description": "This module deploys a Load Balancer Inbound NAT Rules.", + "owner": "Azure/module-maintainers" }, "parameters": { "loadBalancerName": { @@ -527,8 +536,8 @@ }, "frontendPort": { "type": "int", - "maxValue": 65534, "minValue": 1, + "maxValue": 65534, "metadata": { "description": "Required. The port for the external endpoint. Port numbers for each rule must be unique within the Load Balancer." } @@ -536,8 +545,8 @@ "backendPort": { "type": "int", "defaultValue": "[parameters('frontendPort')]", - "maxValue": 65535, "minValue": 1, + "maxValue": 65535, "metadata": { "description": "Optional. The port used for the internal endpoint." } @@ -572,8 +581,8 @@ "frontendPortRangeEnd": { "type": "int", "defaultValue": -1, - "maxValue": 65534, "minValue": -1, + "maxValue": 65534, "metadata": { "description": "Optional. The port range end for the external endpoint. This property is used together with BackendAddressPool and FrontendPortRangeStart. Individual inbound NAT rule port mappings will be created for each backend address from BackendAddressPool." } @@ -581,8 +590,8 @@ "frontendPortRangeStart": { "type": "int", "defaultValue": -1, - "maxValue": 65534, "minValue": -1, + "maxValue": 65534, "metadata": { "description": "Optional. The port range start for the external endpoint. This property is used together with BackendAddressPool and FrontendPortRangeEnd. Individual inbound NAT rule port mappings will be created for each backend address from BackendAddressPool." } @@ -631,7 +640,7 @@ }, { "type": "Microsoft.Network/loadBalancers/inboundNatRules", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('loadBalancerName'), parameters('name'))]", "properties": { "frontendPort": "[parameters('frontendPort')]", @@ -713,8 +722,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "317938330178756229" + "version": "0.20.4.51522", + "templateHash": "13103053503630094914" } }, "parameters": { @@ -884,14 +893,14 @@ "metadata": { "description": "The backend address pools available in the load balancer." }, - "value": "[reference(resourceId('Microsoft.Network/loadBalancers', parameters('name')), '2022-07-01').backendAddressPools]" + "value": "[reference(resourceId('Microsoft.Network/loadBalancers', parameters('name')), '2023-04-01').backendAddressPools]" }, "location": { "type": "string", "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/loadBalancers', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/loadBalancers', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/local-network-gateway/.bicep/nested_roleAssignments.bicep b/modules/network/local-network-gateway/.bicep/nested_roleAssignments.bicep index e6ba4dc722..6cc482997e 100644 --- a/modules/network/local-network-gateway/.bicep/nested_roleAssignments.bicep +++ b/modules/network/local-network-gateway/.bicep/nested_roleAssignments.bicep @@ -78,7 +78,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource localNetworkGateway 'Microsoft.Network/localNetworkGateways@2022-07-01' existing = { +resource localNetworkGateway 'Microsoft.Network/localNetworkGateways@2023-04-01' existing = { name: last(split(resourceId, '/'))! } diff --git a/modules/network/local-network-gateway/README.md b/modules/network/local-network-gateway/README.md index 02aedfdd97..6c4412d68e 100644 --- a/modules/network/local-network-gateway/README.md +++ b/modules/network/local-network-gateway/README.md @@ -16,7 +16,7 @@ This module deploys a Local Network Gateway. | :-- | :-- | | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | -| `Microsoft.Network/localNetworkGateways` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/localNetworkGateways) | +| `Microsoft.Network/localNetworkGateways` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/localNetworkGateways) | ## Parameters diff --git a/modules/network/local-network-gateway/main.bicep b/modules/network/local-network-gateway/main.bicep index 7c07fc9c6d..7030202e79 100644 --- a/modules/network/local-network-gateway/main.bicep +++ b/modules/network/local-network-gateway/main.bicep @@ -62,7 +62,7 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource localNetworkGateway 'Microsoft.Network/localNetworkGateways@2022-07-01' = { +resource localNetworkGateway 'Microsoft.Network/localNetworkGateways@2023-04-01' = { name: name location: location tags: tags diff --git a/modules/network/local-network-gateway/main.json b/modules/network/local-network-gateway/main.json index 3980d2c776..ac72d38bbb 100644 --- a/modules/network/local-network-gateway/main.json +++ b/modules/network/local-network-gateway/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16338290764551298680" - } + "version": "0.20.4.51522", + "templateHash": "3419627759042565001" + }, + "name": "Local Network Gateways", + "description": "This module deploys a Local Network Gateway.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -59,14 +62,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -121,7 +124,7 @@ }, { "type": "Microsoft.Network/localNetworkGateways", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -182,8 +185,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12287681441682406192" + "version": "0.20.4.51522", + "templateHash": "17045611642567667004" } }, "parameters": { @@ -353,7 +356,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/localNetworkGateways', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/localNetworkGateways', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/nat-gateway/.bicep/nested_roleAssignments.bicep b/modules/network/nat-gateway/.bicep/nested_roleAssignments.bicep index 7136a083fe..b351e7930d 100644 --- a/modules/network/nat-gateway/.bicep/nested_roleAssignments.bicep +++ b/modules/network/nat-gateway/.bicep/nested_roleAssignments.bicep @@ -78,7 +78,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource natGateway 'Microsoft.Network/natGateways@2022-07-01' existing = { +resource natGateway 'Microsoft.Network/natGateways@2023-04-01' existing = { name: last(split(resourceId, '/'))! } diff --git a/modules/network/nat-gateway/.test/common/main.test.bicep b/modules/network/nat-gateway/.test/common/main.test.bicep index 62cc3168e6..733add4379 100644 --- a/modules/network/nat-gateway/.test/common/main.test.bicep +++ b/modules/network/nat-gateway/.test/common/main.test.bicep @@ -63,7 +63,6 @@ module testDeployment '../../main.bicep' = { params: { enableDefaultTelemetry: enableDefaultTelemetry name: '${namePrefix}${serviceShort}001' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/network/nat-gateway/README.md b/modules/network/nat-gateway/README.md index 6f06099d30..5f45329dc9 100644 --- a/modules/network/nat-gateway/README.md +++ b/modules/network/nat-gateway/README.md @@ -17,8 +17,8 @@ This module deploys a NAT Gateway. | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/natGateways` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/natGateways) | -| `Microsoft.Network/publicIPAddresses` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/publicIPAddresses) | +| `Microsoft.Network/natGateways` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/natGateways) | +| `Microsoft.Network/publicIPAddresses` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/publicIPAddresses) | ## Parameters @@ -35,7 +35,6 @@ This module deploys a NAT Gateway. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, DDoSMitigationFlowLogs, DDoSMitigationReports, DDoSProtectionNotifications]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the public IP diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -194,7 +193,6 @@ module natGateway './network/nat-gateway/main.bicep' = { // Non-required parameters diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -240,9 +238,6 @@ module natGateway './network/nat-gateway/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/network/nat-gateway/main.bicep b/modules/network/nat-gateway/main.bicep index f6f114fe2d..0f48846095 100644 --- a/modules/network/nat-gateway/main.bicep +++ b/modules/network/nat-gateway/main.bicep @@ -32,11 +32,6 @@ param zones array = [] @description('Optional. Location for all resources.') param location string = resourceGroup().location -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -120,7 +115,6 @@ module publicIPAddress '../public-ip-address/main.bicep' = if (natGatewayPublicI diagnosticLogCategoriesToEnable: diagnosticLogCategoriesToEnable diagnosticMetricsToEnable: diagnosticMetricsToEnable diagnosticSettingsName: !empty(diagnosticSettingsName) ? diagnosticSettingsName : (!empty(natGatewayPipName) ? '${natGatewayPipName}-diagnosticSettings' : '${name}-pip-diagnosticSettings') - diagnosticLogsRetentionInDays: diagnosticLogsRetentionInDays diagnosticStorageAccountId: diagnosticStorageAccountId diagnosticWorkspaceId: diagnosticWorkspaceId diagnosticEventHubAuthorizationRuleId: diagnosticEventHubAuthorizationRuleId @@ -138,7 +132,7 @@ module publicIPAddress '../public-ip-address/main.bicep' = if (natGatewayPublicI // NAT GATEWAY // =========== -resource natGateway 'Microsoft.Network/natGateways@2022-07-01' = { +resource natGateway 'Microsoft.Network/natGateways@2023-04-01' = { name: name location: location tags: tags diff --git a/modules/network/nat-gateway/main.json b/modules/network/nat-gateway/main.json index 88682ad70a..2faa1a6061 100644 --- a/modules/network/nat-gateway/main.json +++ b/modules/network/nat-gateway/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17459283846288520476" - } + "version": "0.20.4.51522", + "templateHash": "11858620925085165603" + }, + "name": "NAT Gateways", + "description": "This module deploys a NAT Gateway.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -78,15 +81,6 @@ "description": "Optional. Location for all resources." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -118,14 +112,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -220,7 +214,7 @@ }, { "type": "Microsoft.Network/natGateways", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -270,9 +264,6 @@ "value": "[parameters('diagnosticMetricsToEnable')]" }, "diagnosticSettingsName": "[if(not(empty(parameters('diagnosticSettingsName'))), createObject('value', parameters('diagnosticSettingsName')), if(not(empty(parameters('natGatewayPipName'))), createObject('value', format('{0}-diagnosticSettings', parameters('natGatewayPipName'))), createObject('value', format('{0}-pip-diagnosticSettings', parameters('name')))))]", - "diagnosticLogsRetentionInDays": { - "value": "[parameters('diagnosticLogsRetentionInDays')]" - }, "diagnosticStorageAccountId": { "value": "[parameters('diagnosticStorageAccountId')]" }, @@ -316,9 +307,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1954871673414826097" - } + "version": "0.20.4.51522", + "templateHash": "7444990895328873286" + }, + "name": "Public IP Addresses", + "description": "This module deploys a Public IP Address.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -385,15 +379,6 @@ "description": "Optional. IP address version." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -429,6 +414,20 @@ "description": "Optional. The domain name label. The concatenation of the domain name label and the regionalized DNS zone make up the fully qualified domain name associated with the public IP address. If a domain name label is specified, an A DNS record is created for the public IP in the Microsoft Azure DNS system." } }, + "domainNameLabelScope": { + "type": "string", + "defaultValue": "", + "allowedValues": [ + "", + "NoReuse", + "ResourceGroupReuse", + "SubscriptionReuse", + "TenantReuse" + ], + "metadata": { + "description": "Optional. The domain name label scope. If a domain name label and a domain name label scope are specified, an A DNS record is created for the public IP in the Microsoft Azure DNS system with a hashed value includes in FQDN." + } + }, "fqdn": { "type": "string", "defaultValue": "", @@ -446,14 +445,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "location": { "type": "string", @@ -526,11 +525,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -539,15 +534,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" }, "resources": [ { @@ -566,7 +557,7 @@ }, { "type": "Microsoft.Network/publicIPAddresses", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -576,7 +567,7 @@ }, "zones": "[parameters('zones')]", "properties": { - "dnsSettings": "[if(not(empty(parameters('domainNameLabel'))), createObject('domainNameLabel', parameters('domainNameLabel'), 'fqdn', parameters('fqdn'), 'reverseFqdn', parameters('reverseFqdn')), null())]", + "dnsSettings": "[if(not(empty(parameters('domainNameLabel'))), createObject('domainNameLabel', parameters('domainNameLabel'), 'domainNameLabelScope', parameters('domainNameLabelScope'), 'fqdn', parameters('fqdn'), 'reverseFqdn', parameters('reverseFqdn')), null())]", "publicIPAddressVersion": "[parameters('publicIPAddressVersion')]", "publicIPAllocationMethod": "[parameters('publicIPAllocationMethod')]", "publicIPPrefix": "[if(not(empty(parameters('publicIPPrefixResourceId'))), createObject('id', parameters('publicIPPrefixResourceId')), null())]", @@ -650,8 +641,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7927074872480917952" + "version": "0.20.4.51522", + "templateHash": "11249227806125160411" } }, "parameters": { @@ -821,14 +812,14 @@ "metadata": { "description": "The public IP address of the public IP address resource." }, - "value": "[if(contains(reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2022-07-01'), 'ipAddress'), reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2022-07-01').ipAddress, '')]" + "value": "[if(contains(reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2023-04-01'), 'ipAddress'), reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2023-04-01').ipAddress, '')]" }, "location": { "type": "string", "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -868,8 +859,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13433158154703182157" + "version": "0.20.4.51522", + "templateHash": "18168932094320787414" } }, "parameters": { @@ -1039,7 +1030,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/natGateways', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/natGateways', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/network-interface/.bicep/nested_roleAssignments.bicep b/modules/network/network-interface/.bicep/nested_roleAssignments.bicep index 15867ee2df..902582a911 100644 --- a/modules/network/network-interface/.bicep/nested_roleAssignments.bicep +++ b/modules/network/network-interface/.bicep/nested_roleAssignments.bicep @@ -78,7 +78,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource networkInterface 'Microsoft.Network/networkInterfaces@2021-08-01' existing = { +resource networkInterface 'Microsoft.Network/networkInterfaces@2023-04-01' existing = { name: last(split(resourceId, '/'))! } diff --git a/modules/network/network-interface/.test/common/dependencies.bicep b/modules/network/network-interface/.test/common/dependencies.bicep index f0b711e434..9cd1f6840e 100644 --- a/modules/network/network-interface/.test/common/dependencies.bicep +++ b/modules/network/network-interface/.test/common/dependencies.bicep @@ -15,89 +15,89 @@ param loadBalancerName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } -resource applicationSecurityGroup 'Microsoft.Network/applicationSecurityGroups@2022-01-01' = { - name: applicationSecurityGroupName - location: location +resource applicationSecurityGroup 'Microsoft.Network/applicationSecurityGroups@2023-04-01' = { + name: applicationSecurityGroupName + location: location } -resource loadBalancer 'Microsoft.Network/loadBalancers@2022-01-01' = { - name: loadBalancerName - location: location - sku: { - name: 'Standard' - } - - properties: { - frontendIPConfigurations: [ - { - name: 'privateIPConfig1' - properties: { - subnet: { - id: virtualNetwork.properties.subnets[0].id - } - } - } - ] - } +resource loadBalancer 'Microsoft.Network/loadBalancers@2023-04-01' = { + name: loadBalancerName + location: location + sku: { + name: 'Standard' + } + + properties: { + frontendIPConfigurations: [ + { + name: 'privateIPConfig1' + properties: { + subnet: { + id: virtualNetwork.properties.subnets[0].id + } + } + } + ] + } - resource backendPool 'backendAddressPools@2022-01-01' = { - name: 'default' - } + resource backendPool 'backendAddressPools@2022-01-01' = { + name: 'default' + } } -resource inboundNatRule 'Microsoft.Network/loadBalancers/inboundNatRules@2021-08-01' = { - name: 'inboundNatRule1' - properties: { - frontendPort: 443 - backendPort: 443 - enableFloatingIP: false - enableTcpReset: false - frontendIPConfiguration: { - id: loadBalancer.properties.frontendIPConfigurations[0].id - } - idleTimeoutInMinutes: 4 - protocol: 'Tcp' +resource inboundNatRule 'Microsoft.Network/loadBalancers/inboundNatRules@2023-04-01' = { + name: 'inboundNatRule1' + properties: { + frontendPort: 443 + backendPort: 443 + enableFloatingIP: false + enableTcpReset: false + frontendIPConfiguration: { + id: loadBalancer.properties.frontendIPConfigurations[0].id } - parent: loadBalancer + idleTimeoutInMinutes: 4 + protocol: 'Tcp' + } + parent: loadBalancer } -resource inboundNatRule2 'Microsoft.Network/loadBalancers/inboundNatRules@2021-08-01' = { - name: 'inboundNatRule2' - properties: { - frontendPort: 3389 - backendPort: 3389 - frontendIPConfiguration: { - id: loadBalancer.properties.frontendIPConfigurations[0].id - } - idleTimeoutInMinutes: 4 - protocol: 'Tcp' +resource inboundNatRule2 'Microsoft.Network/loadBalancers/inboundNatRules@2023-04-01' = { + name: 'inboundNatRule2' + properties: { + frontendPort: 3389 + backendPort: 3389 + frontendIPConfiguration: { + id: loadBalancer.properties.frontendIPConfigurations[0].id } - parent: loadBalancer + idleTimeoutInMinutes: 4 + protocol: 'Tcp' + } + parent: loadBalancer } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/network/network-interface/.test/common/main.test.bicep b/modules/network/network-interface/.test/common/main.test.bicep index b6ddc8f6bb..ba8beced0c 100644 --- a/modules/network/network-interface/.test/common/main.test.bicep +++ b/modules/network/network-interface/.test/common/main.test.bicep @@ -90,7 +90,6 @@ module testDeployment '../../main.bicep' = { ] } ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/network/network-interface/.test/min/dependencies.bicep b/modules/network/network-interface/.test/min/dependencies.bicep index 978d8fa796..b81c96bf15 100644 --- a/modules/network/network-interface/.test/min/dependencies.bicep +++ b/modules/network/network-interface/.test/min/dependencies.bicep @@ -6,24 +6,24 @@ param virtualNetworkName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/network/network-interface/README.md b/modules/network/network-interface/README.md index 4dadb3d2ab..3ad755e48e 100644 --- a/modules/network/network-interface/README.md +++ b/modules/network/network-interface/README.md @@ -17,7 +17,7 @@ This module deploys a Network Interface. | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/networkInterfaces` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/networkInterfaces) | +| `Microsoft.Network/networkInterfaces` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/networkInterfaces) | ## Parameters @@ -33,9 +33,9 @@ This module deploys a Network Interface. | Parameter Name | Type | Default Value | Allowed Values | Description | | :-- | :-- | :-- | :-- | :-- | | `auxiliaryMode` | string | `'None'` | `[Floating, MaxConnections, None]` | Auxiliary mode of Network Interface resource. Not all regions are enabled for Auxiliary Mode Nic. | +| `auxiliarySku` | string | `'None'` | `[A1, A2, A4, A8, None]` | Auxiliary sku of Network Interface resource. Not all regions are enabled for Auxiliary Mode Nic. | | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -232,7 +232,6 @@ module networkInterface './network/network-interface/main.bicep' = { // Non-required parameters diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -303,9 +302,6 @@ module networkInterface './network/network-interface/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/network/network-interface/main.bicep b/modules/network/network-interface/main.bicep index 7140b9eabf..43f79f1528 100644 --- a/modules/network/network-interface/main.bicep +++ b/modules/network/network-interface/main.bicep @@ -34,6 +34,16 @@ param networkSecurityGroupResourceId string = '' @description('Optional. Auxiliary mode of Network Interface resource. Not all regions are enabled for Auxiliary Mode Nic.') param auxiliaryMode string = 'None' +@allowed([ + 'A1' + 'A2' + 'A4' + 'A8' + 'None' +]) +@description('Optional. Auxiliary sku of Network Interface resource. Not all regions are enabled for Auxiliary Mode Nic.') +param auxiliarySku string = 'None' + @description('Optional. Indicates whether to disable tcp state tracking. Subscription must be registered for the Microsoft.Network/AllowDisableTcpStateTracking feature before this property can be set to true.') param disableTcpStateTracking bool = false @@ -51,11 +61,6 @@ param lock string = '' @description('Optional. Array of role assignment objects that contain the \'roleDefinitionIdOrName\' and \'principalId\' to define RBAC role assignments on this resource. In the roleDefinitionIdOrName attribute, you can provide either the display name of the role definition, or its fully qualified ID in the following format: \'/providers/Microsoft.Authorization/roleDefinitions/c2f4ef07-c644-48eb-af81-4b1b4947fb11\'.') param roleAssignments array = [] -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -83,10 +88,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (enableDefaultTelemetry) { @@ -101,12 +102,13 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource networkInterface 'Microsoft.Network/networkInterfaces@2022-07-01' = { +resource networkInterface 'Microsoft.Network/networkInterfaces@2023-04-01' = { name: name location: location tags: tags properties: { auxiliaryMode: auxiliaryMode + auxiliarySku: auxiliarySku disableTcpStateTracking: disableTcpStateTracking dnsSettings: !empty(dnsServers) ? { dnsServers: dnsServers diff --git a/modules/network/network-interface/main.json b/modules/network/network-interface/main.json index 8efe63718b..f60e5a1aaf 100644 --- a/modules/network/network-interface/main.json +++ b/modules/network/network-interface/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4998852968640897249" - } + "version": "0.20.4.51522", + "templateHash": "4973390307671682303" + }, + "name": "Network Interface", + "description": "This module deploys a Network Interface.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -67,14 +70,28 @@ "auxiliaryMode": { "type": "string", "defaultValue": "None", - "metadata": { - "description": "Optional. Auxiliary mode of Network Interface resource. Not all regions are enabled for Auxiliary Mode Nic." - }, "allowedValues": [ "Floating", "MaxConnections", "None" - ] + ], + "metadata": { + "description": "Optional. Auxiliary mode of Network Interface resource. Not all regions are enabled for Auxiliary Mode Nic." + } + }, + "auxiliarySku": { + "type": "string", + "defaultValue": "None", + "allowedValues": [ + "A1", + "A2", + "A4", + "A8", + "None" + ], + "metadata": { + "description": "Optional. Auxiliary sku of Network Interface resource. Not all regions are enabled for Auxiliary Mode Nic." + } }, "disableTcpStateTracking": { "type": "bool", @@ -92,14 +109,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -108,15 +125,6 @@ "description": "Optional. Array of role assignment objects that contain the 'roleDefinitionIdOrName' and 'principalId' to define RBAC role assignments on this resource. In the roleDefinitionIdOrName attribute, you can provide either the display name of the role definition, or its fully qualified ID in the following format: '/providers/Microsoft.Authorization/roleDefinitions/c2f4ef07-c644-48eb-af81-4b1b4947fb11'." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -173,11 +181,7 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ] @@ -199,7 +203,7 @@ }, { "type": "Microsoft.Network/networkInterfaces", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -230,6 +234,7 @@ } ], "auxiliaryMode": "[parameters('auxiliaryMode')]", + "auxiliarySku": "[parameters('auxiliarySku')]", "disableTcpStateTracking": "[parameters('disableTcpStateTracking')]", "dnsSettings": "[if(not(empty(parameters('dnsServers'))), createObject('dnsServers', parameters('dnsServers')), null())]", "enableAcceleratedNetworking": "[parameters('enableAcceleratedNetworking')]", @@ -302,8 +307,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11217191875210502826" + "version": "0.20.4.51522", + "templateHash": "12768288729117926344" } }, "parameters": { @@ -473,7 +478,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/networkInterfaces', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/networkInterfaces', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/network-manager/.test/common/dependencies.bicep b/modules/network/network-manager/.test/common/dependencies.bicep index 8a9846af6a..501a5a13c0 100644 --- a/modules/network/network-manager/.test/common/dependencies.bicep +++ b/modules/network/network-manager/.test/common/dependencies.bicep @@ -23,7 +23,7 @@ var addressPrefixSpoke1 = '172.16.0.0/12' var addressPrefixSpoke2 = '192.168.0.0/16' var subnetName = 'defaultSubnet' -resource virtualNetworkHub 'Microsoft.Network/virtualNetworks@2023-02-01' = { +resource virtualNetworkHub 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkHubName location: location properties: { @@ -43,7 +43,7 @@ resource virtualNetworkHub 'Microsoft.Network/virtualNetworks@2023-02-01' = { } } -resource virtualNetworkSpoke1 'Microsoft.Network/virtualNetworks@2023-02-01' = { +resource virtualNetworkSpoke1 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkSpoke1Name location: location properties: { @@ -63,7 +63,7 @@ resource virtualNetworkSpoke1 'Microsoft.Network/virtualNetworks@2023-02-01' = { } } -resource virtualNetworkSpoke2 'Microsoft.Network/virtualNetworks@2023-02-01' = { +resource virtualNetworkSpoke2 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkSpoke2Name location: location properties: { diff --git a/modules/network/network-manager/connectivity-configuration/main.json b/modules/network/network-manager/connectivity-configuration/main.json index 233059da3a..f93f38ee52 100644 --- a/modules/network/network-manager/connectivity-configuration/main.json +++ b/modules/network/network-manager/connectivity-configuration/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4358706606848401992" - } + "version": "0.20.4.51522", + "templateHash": "13738709959380835083" + }, + "name": "Network Manager Connectivity Configurations", + "description": "This module deploys a Network Manager Connectivity Configuration.\r\nConnectivity configurations define hub-and-spoke or mesh topologies applied to one or more network groups.", + "owner": "Azure/module-maintainers" }, "parameters": { "networkManagerName": { @@ -17,18 +20,18 @@ }, "name": { "type": "string", + "maxLength": 64, "metadata": { "description": "Required. The name of the connectivity configuration." - }, - "maxLength": 64 + } }, "description": { "type": "string", "defaultValue": "", + "maxLength": 500, "metadata": { "description": "Optional. A description of the connectivity configuration." - }, - "maxLength": 500 + } }, "appliesToGroups": { "type": "array", @@ -39,13 +42,13 @@ }, "connectivityTopology": { "type": "string", - "metadata": { - "description": "Required. Connectivity topology type." - }, "allowedValues": [ "HubAndSpoke", "Mesh" - ] + ], + "metadata": { + "description": "Required. Connectivity topology type." + } }, "hubs": { "type": "array", @@ -57,24 +60,24 @@ "deleteExistingPeering": { "type": "string", "defaultValue": "False", - "metadata": { - "description": "Optional. Flag if need to remove current existing peerings. If set to \"True\", all peerings on virtual networks in selected network groups will be removed and replaced with the peerings defined by this configuration. Optional when connectivityTopology is of type \"HubAndSpoke\"." - }, "allowedValues": [ "True", "False" - ] + ], + "metadata": { + "description": "Optional. Flag if need to remove current existing peerings. If set to \"True\", all peerings on virtual networks in selected network groups will be removed and replaced with the peerings defined by this configuration. Optional when connectivityTopology is of type \"HubAndSpoke\"." + } }, "isGlobal": { "type": "string", "defaultValue": "False", - "metadata": { - "description": "Optional. Flag if global mesh is supported. By default, mesh connectivity is applied to virtual networks within the same region. If set to \"True\", a global mesh enables connectivity across regions." - }, "allowedValues": [ "True", "False" - ] + ], + "metadata": { + "description": "Optional. Flag if global mesh is supported. By default, mesh connectivity is applied to virtual networks within the same region. If set to \"True\", a global mesh enables connectivity across regions." + } }, "enableDefaultTelemetry": { "type": "bool", diff --git a/modules/network/network-manager/main.json b/modules/network/network-manager/main.json index 1b3c18bca1..4ed1b7f688 100644 --- a/modules/network/network-manager/main.json +++ b/modules/network/network-manager/main.json @@ -4,15 +4,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12215356854067543127" - } + "version": "0.20.4.51522", + "templateHash": "12431557271932409213" + }, + "name": "Network Managers", + "description": "This module deploys a Network Manager.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { "type": "string", - "maxLength": 64, "minLength": 1, + "maxLength": 64, "metadata": { "description": "Required. Name of the Network Manager." } @@ -27,14 +30,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -53,10 +56,10 @@ "description": { "type": "string", "defaultValue": "", + "maxLength": 500, "metadata": { "description": "Optional. A description of the network manager." - }, - "maxLength": 500 + } }, "networkManagerScopeAccesses": { "type": "array", @@ -182,9 +185,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13468442252867472721" - } + "version": "0.20.4.51522", + "templateHash": "1182394296109740179" + }, + "name": "Network Manager Network Groups", + "description": "This module deploys a Network Manager Network Group.\r\nA network group is a collection of same-type network resources that you can associate with network manager configurations. You can add same-type network resources after you create the network group.", + "owner": "Azure/module-maintainers" }, "parameters": { "networkManagerName": { @@ -195,18 +201,18 @@ }, "name": { "type": "string", + "maxLength": 64, "metadata": { "description": "Required. The name of the network group." - }, - "maxLength": 64 + } }, "description": { "type": "string", "defaultValue": "", + "maxLength": 500, "metadata": { "description": "Optional. A description of the network group." - }, - "maxLength": 500 + } }, "staticMembers": { "type": "array", @@ -285,9 +291,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16214310991903541469" - } + "version": "0.20.4.51522", + "templateHash": "12393286614459840374" + }, + "name": "Network Manager Network Group Static Members", + "description": "This module deploys a Network Manager Network Group Static Member.\r\nStatic membership allows you to explicitly add virtual networks to a group by manually selecting individual virtual networks.", + "owner": "Azure/module-maintainers" }, "parameters": { "networkManagerName": { @@ -445,9 +454,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4358706606848401992" - } + "version": "0.20.4.51522", + "templateHash": "13738709959380835083" + }, + "name": "Network Manager Connectivity Configurations", + "description": "This module deploys a Network Manager Connectivity Configuration.\r\nConnectivity configurations define hub-and-spoke or mesh topologies applied to one or more network groups.", + "owner": "Azure/module-maintainers" }, "parameters": { "networkManagerName": { @@ -458,18 +470,18 @@ }, "name": { "type": "string", + "maxLength": 64, "metadata": { "description": "Required. The name of the connectivity configuration." - }, - "maxLength": 64 + } }, "description": { "type": "string", "defaultValue": "", + "maxLength": 500, "metadata": { "description": "Optional. A description of the connectivity configuration." - }, - "maxLength": 500 + } }, "appliesToGroups": { "type": "array", @@ -480,13 +492,13 @@ }, "connectivityTopology": { "type": "string", - "metadata": { - "description": "Required. Connectivity topology type." - }, "allowedValues": [ "HubAndSpoke", "Mesh" - ] + ], + "metadata": { + "description": "Required. Connectivity topology type." + } }, "hubs": { "type": "array", @@ -498,24 +510,24 @@ "deleteExistingPeering": { "type": "string", "defaultValue": "False", - "metadata": { - "description": "Optional. Flag if need to remove current existing peerings. If set to \"True\", all peerings on virtual networks in selected network groups will be removed and replaced with the peerings defined by this configuration. Optional when connectivityTopology is of type \"HubAndSpoke\"." - }, "allowedValues": [ "True", "False" - ] + ], + "metadata": { + "description": "Optional. Flag if need to remove current existing peerings. If set to \"True\", all peerings on virtual networks in selected network groups will be removed and replaced with the peerings defined by this configuration. Optional when connectivityTopology is of type \"HubAndSpoke\"." + } }, "isGlobal": { "type": "string", "defaultValue": "False", - "metadata": { - "description": "Optional. Flag if global mesh is supported. By default, mesh connectivity is applied to virtual networks within the same region. If set to \"True\", a global mesh enables connectivity across regions." - }, "allowedValues": [ "True", "False" - ] + ], + "metadata": { + "description": "Optional. Flag if global mesh is supported. By default, mesh connectivity is applied to virtual networks within the same region. If set to \"True\", a global mesh enables connectivity across regions." + } }, "enableDefaultTelemetry": { "type": "bool", @@ -621,9 +633,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10543425561671785083" - } + "version": "0.20.4.51522", + "templateHash": "10403692977342355689" + }, + "name": "Network Manager Scope Connections", + "description": "This module deploys a Network Manager Scope Connection.\r\nCreate a cross-tenant connection to manage a resource from another tenant.", + "owner": "Azure/module-maintainers" }, "parameters": { "networkManagerName": { @@ -634,18 +649,18 @@ }, "name": { "type": "string", + "maxLength": 64, "metadata": { "description": "Required. The name of the scope connection." - }, - "maxLength": 64 + } }, "description": { "type": "string", "defaultValue": "", + "maxLength": 500, "metadata": { "description": "Optional. A description of the scope connection." - }, - "maxLength": 500 + } }, "resourceId": { "type": "string", @@ -757,9 +772,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11248739545153525651" - } + "version": "0.20.4.51522", + "templateHash": "509040400222226150" + }, + "name": "Network Manager Security Admin Configurations", + "description": "This module deploys an Network Manager Security Admin Configuration.\r\nA security admin configuration contains a set of rule collections. Each rule collection contains one or more security admin rules.", + "owner": "Azure/module-maintainers" }, "parameters": { "networkManagerName": { @@ -770,32 +788,32 @@ }, "name": { "type": "string", + "maxLength": 64, "metadata": { "description": "Required. The name of the security admin configuration." - }, - "maxLength": 64 + } }, "description": { "type": "string", "defaultValue": "", + "maxLength": 500, "metadata": { "description": "Optional. A description of the security admin configuration." - }, - "maxLength": 500 + } }, "applyOnNetworkIntentPolicyBasedServices": { "type": "array", "defaultValue": [ "None" ], - "metadata": { - "description": "Required. Enum list of network intent policy based services." - }, "allowedValues": [ "None", "All", "AllowRulesOnly" - ] + ], + "metadata": { + "description": "Required. Enum list of network intent policy based services." + } }, "ruleCollections": { "type": "array", @@ -876,9 +894,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15345246908056395599" - } + "version": "0.20.4.51522", + "templateHash": "3922899062083147081" + }, + "name": "Network Manager Security Admin Configuration Rule Collections", + "description": "This module deploys an Network Manager Security Admin Configuration Rule Collection.\r\nA security admin configuration contains a set of rule collections. Each rule collection contains one or more security admin rules. Security admin rules allows enforcing security policy criteria that matches the conditions set. Warning: A rule collection without rule will cause a deployment configuration for security admin goal state in network manager to fail.", + "owner": "Azure/module-maintainers" }, "parameters": { "networkManagerName": { @@ -895,18 +916,18 @@ }, "name": { "type": "string", + "maxLength": 64, "metadata": { "description": "Required. The name of the admin rule collection." - }, - "maxLength": 64 + } }, "description": { "type": "string", "defaultValue": "", + "maxLength": 500, "metadata": { "description": "Optional. A description of the admin rule collection." - }, - "maxLength": 500 + } }, "appliesToGroups": { "type": "array", @@ -1008,9 +1029,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11476125438194706048" - } + "version": "0.20.4.51522", + "templateHash": "493168310843879218" + }, + "name": "Network Manager Security Admin Configuration Rule Collection Rules", + "description": "This module deploys an Azure Virtual Network Manager (AVNM) Security Admin Configuration Rule Collection Rule.\r\nA security admin configuration contains a set of rule collections. Each rule collection contains one or more security admin rules.", + "owner": "Azure/module-maintainers" }, "parameters": { "networkManagerName": { @@ -1033,29 +1057,29 @@ }, "name": { "type": "string", + "maxLength": 64, "metadata": { "description": "Required. The name of the rule." - }, - "maxLength": 64 + } }, "description": { "type": "string", "defaultValue": "", + "maxLength": 500, "metadata": { "description": "Optional. A description of the rule." - }, - "maxLength": 500 + } }, "access": { "type": "string", - "metadata": { - "description": "Required. Indicates the access allowed for this particular rule. \"Allow\" means traffic matching this rule will be allowed. \"Deny\" means traffic matching this rule will be blocked. \"AlwaysAllow\" means that traffic matching this rule will be allowed regardless of other rules with lower priority or user-defined NSGs." - }, "allowedValues": [ "Allow", "AlwaysAllow", "Deny" - ] + ], + "metadata": { + "description": "Required. Indicates the access allowed for this particular rule. \"Allow\" means traffic matching this rule will be allowed. \"Deny\" means traffic matching this rule will be blocked. \"AlwaysAllow\" means that traffic matching this rule will be allowed regardless of other rules with lower priority or user-defined NSGs." + } }, "destinationPortRanges": { "type": "array", @@ -1073,27 +1097,24 @@ }, "direction": { "type": "string", - "metadata": { - "description": "Required. Indicates if the traffic matched against the rule in inbound or outbound." - }, "allowedValues": [ "Inbound", "Outbound" - ] + ], + "metadata": { + "description": "Required. Indicates if the traffic matched against the rule in inbound or outbound." + } }, "priority": { "type": "int", + "minValue": 1, + "maxValue": 4096, "metadata": { "description": "Required. The priority of the rule. The value can be between 1 and 4096. The priority number must be unique for each rule in the collection. The lower the priority number, the higher the priority of the rule." - }, - "maxValue": 4096, - "minValue": 1 + } }, "protocol": { "type": "string", - "metadata": { - "description": "Required. Network protocol this rule applies to." - }, "allowedValues": [ "Ah", "Any", @@ -1101,7 +1122,10 @@ "Icmp", "Tcp", "Udp" - ] + ], + "metadata": { + "description": "Required. Network protocol this rule applies to." + } }, "sourcePortRanges": { "type": "array", @@ -1282,8 +1306,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10175367214015467898" + "version": "0.20.4.51522", + "templateHash": "3627541728287633806" } }, "parameters": { diff --git a/modules/network/network-manager/network-group/main.json b/modules/network/network-manager/network-group/main.json index f784c10bd5..f5db35d400 100644 --- a/modules/network/network-manager/network-group/main.json +++ b/modules/network/network-manager/network-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13468442252867472721" - } + "version": "0.20.4.51522", + "templateHash": "1182394296109740179" + }, + "name": "Network Manager Network Groups", + "description": "This module deploys a Network Manager Network Group.\r\nA network group is a collection of same-type network resources that you can associate with network manager configurations. You can add same-type network resources after you create the network group.", + "owner": "Azure/module-maintainers" }, "parameters": { "networkManagerName": { @@ -17,18 +20,18 @@ }, "name": { "type": "string", + "maxLength": 64, "metadata": { "description": "Required. The name of the network group." - }, - "maxLength": 64 + } }, "description": { "type": "string", "defaultValue": "", + "maxLength": 500, "metadata": { "description": "Optional. A description of the network group." - }, - "maxLength": 500 + } }, "staticMembers": { "type": "array", @@ -107,9 +110,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16214310991903541469" - } + "version": "0.20.4.51522", + "templateHash": "12393286614459840374" + }, + "name": "Network Manager Network Group Static Members", + "description": "This module deploys a Network Manager Network Group Static Member.\r\nStatic membership allows you to explicitly add virtual networks to a group by manually selecting individual virtual networks.", + "owner": "Azure/module-maintainers" }, "parameters": { "networkManagerName": { diff --git a/modules/network/network-manager/network-group/static-member/main.json b/modules/network/network-manager/network-group/static-member/main.json index 02aa7302fb..1150de3107 100644 --- a/modules/network/network-manager/network-group/static-member/main.json +++ b/modules/network/network-manager/network-group/static-member/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16214310991903541469" - } + "version": "0.20.4.51522", + "templateHash": "12393286614459840374" + }, + "name": "Network Manager Network Group Static Members", + "description": "This module deploys a Network Manager Network Group Static Member.\r\nStatic membership allows you to explicitly add virtual networks to a group by manually selecting individual virtual networks.", + "owner": "Azure/module-maintainers" }, "parameters": { "networkManagerName": { diff --git a/modules/network/network-manager/scope-connection/main.json b/modules/network/network-manager/scope-connection/main.json index 2007073dd4..6f876db365 100644 --- a/modules/network/network-manager/scope-connection/main.json +++ b/modules/network/network-manager/scope-connection/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10543425561671785083" - } + "version": "0.20.4.51522", + "templateHash": "10403692977342355689" + }, + "name": "Network Manager Scope Connections", + "description": "This module deploys a Network Manager Scope Connection.\r\nCreate a cross-tenant connection to manage a resource from another tenant.", + "owner": "Azure/module-maintainers" }, "parameters": { "networkManagerName": { @@ -17,18 +20,18 @@ }, "name": { "type": "string", + "maxLength": 64, "metadata": { "description": "Required. The name of the scope connection." - }, - "maxLength": 64 + } }, "description": { "type": "string", "defaultValue": "", + "maxLength": 500, "metadata": { "description": "Optional. A description of the scope connection." - }, - "maxLength": 500 + } }, "resourceId": { "type": "string", diff --git a/modules/network/network-manager/security-admin-configuration/main.json b/modules/network/network-manager/security-admin-configuration/main.json index dbdba4f5aa..b74075fe1a 100644 --- a/modules/network/network-manager/security-admin-configuration/main.json +++ b/modules/network/network-manager/security-admin-configuration/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11248739545153525651" - } + "version": "0.20.4.51522", + "templateHash": "509040400222226150" + }, + "name": "Network Manager Security Admin Configurations", + "description": "This module deploys an Network Manager Security Admin Configuration.\r\nA security admin configuration contains a set of rule collections. Each rule collection contains one or more security admin rules.", + "owner": "Azure/module-maintainers" }, "parameters": { "networkManagerName": { @@ -17,32 +20,32 @@ }, "name": { "type": "string", + "maxLength": 64, "metadata": { "description": "Required. The name of the security admin configuration." - }, - "maxLength": 64 + } }, "description": { "type": "string", "defaultValue": "", + "maxLength": 500, "metadata": { "description": "Optional. A description of the security admin configuration." - }, - "maxLength": 500 + } }, "applyOnNetworkIntentPolicyBasedServices": { "type": "array", "defaultValue": [ "None" ], - "metadata": { - "description": "Required. Enum list of network intent policy based services." - }, "allowedValues": [ "None", "All", "AllowRulesOnly" - ] + ], + "metadata": { + "description": "Required. Enum list of network intent policy based services." + } }, "ruleCollections": { "type": "array", @@ -123,9 +126,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15345246908056395599" - } + "version": "0.20.4.51522", + "templateHash": "3922899062083147081" + }, + "name": "Network Manager Security Admin Configuration Rule Collections", + "description": "This module deploys an Network Manager Security Admin Configuration Rule Collection.\r\nA security admin configuration contains a set of rule collections. Each rule collection contains one or more security admin rules. Security admin rules allows enforcing security policy criteria that matches the conditions set. Warning: A rule collection without rule will cause a deployment configuration for security admin goal state in network manager to fail.", + "owner": "Azure/module-maintainers" }, "parameters": { "networkManagerName": { @@ -142,18 +148,18 @@ }, "name": { "type": "string", + "maxLength": 64, "metadata": { "description": "Required. The name of the admin rule collection." - }, - "maxLength": 64 + } }, "description": { "type": "string", "defaultValue": "", + "maxLength": 500, "metadata": { "description": "Optional. A description of the admin rule collection." - }, - "maxLength": 500 + } }, "appliesToGroups": { "type": "array", @@ -255,9 +261,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11476125438194706048" - } + "version": "0.20.4.51522", + "templateHash": "493168310843879218" + }, + "name": "Network Manager Security Admin Configuration Rule Collection Rules", + "description": "This module deploys an Azure Virtual Network Manager (AVNM) Security Admin Configuration Rule Collection Rule.\r\nA security admin configuration contains a set of rule collections. Each rule collection contains one or more security admin rules.", + "owner": "Azure/module-maintainers" }, "parameters": { "networkManagerName": { @@ -280,29 +289,29 @@ }, "name": { "type": "string", + "maxLength": 64, "metadata": { "description": "Required. The name of the rule." - }, - "maxLength": 64 + } }, "description": { "type": "string", "defaultValue": "", + "maxLength": 500, "metadata": { "description": "Optional. A description of the rule." - }, - "maxLength": 500 + } }, "access": { "type": "string", - "metadata": { - "description": "Required. Indicates the access allowed for this particular rule. \"Allow\" means traffic matching this rule will be allowed. \"Deny\" means traffic matching this rule will be blocked. \"AlwaysAllow\" means that traffic matching this rule will be allowed regardless of other rules with lower priority or user-defined NSGs." - }, "allowedValues": [ "Allow", "AlwaysAllow", "Deny" - ] + ], + "metadata": { + "description": "Required. Indicates the access allowed for this particular rule. \"Allow\" means traffic matching this rule will be allowed. \"Deny\" means traffic matching this rule will be blocked. \"AlwaysAllow\" means that traffic matching this rule will be allowed regardless of other rules with lower priority or user-defined NSGs." + } }, "destinationPortRanges": { "type": "array", @@ -320,27 +329,24 @@ }, "direction": { "type": "string", - "metadata": { - "description": "Required. Indicates if the traffic matched against the rule in inbound or outbound." - }, "allowedValues": [ "Inbound", "Outbound" - ] + ], + "metadata": { + "description": "Required. Indicates if the traffic matched against the rule in inbound or outbound." + } }, "priority": { "type": "int", + "minValue": 1, + "maxValue": 4096, "metadata": { "description": "Required. The priority of the rule. The value can be between 1 and 4096. The priority number must be unique for each rule in the collection. The lower the priority number, the higher the priority of the rule." - }, - "maxValue": 4096, - "minValue": 1 + } }, "protocol": { "type": "string", - "metadata": { - "description": "Required. Network protocol this rule applies to." - }, "allowedValues": [ "Ah", "Any", @@ -348,7 +354,10 @@ "Icmp", "Tcp", "Udp" - ] + ], + "metadata": { + "description": "Required. Network protocol this rule applies to." + } }, "sourcePortRanges": { "type": "array", diff --git a/modules/network/network-manager/security-admin-configuration/rule-collection/main.json b/modules/network/network-manager/security-admin-configuration/rule-collection/main.json index 019ba71fc4..76c720676e 100644 --- a/modules/network/network-manager/security-admin-configuration/rule-collection/main.json +++ b/modules/network/network-manager/security-admin-configuration/rule-collection/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15345246908056395599" - } + "version": "0.20.4.51522", + "templateHash": "3922899062083147081" + }, + "name": "Network Manager Security Admin Configuration Rule Collections", + "description": "This module deploys an Network Manager Security Admin Configuration Rule Collection.\r\nA security admin configuration contains a set of rule collections. Each rule collection contains one or more security admin rules. Security admin rules allows enforcing security policy criteria that matches the conditions set. Warning: A rule collection without rule will cause a deployment configuration for security admin goal state in network manager to fail.", + "owner": "Azure/module-maintainers" }, "parameters": { "networkManagerName": { @@ -23,18 +26,18 @@ }, "name": { "type": "string", + "maxLength": 64, "metadata": { "description": "Required. The name of the admin rule collection." - }, - "maxLength": 64 + } }, "description": { "type": "string", "defaultValue": "", + "maxLength": 500, "metadata": { "description": "Optional. A description of the admin rule collection." - }, - "maxLength": 500 + } }, "appliesToGroups": { "type": "array", @@ -136,9 +139,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11476125438194706048" - } + "version": "0.20.4.51522", + "templateHash": "493168310843879218" + }, + "name": "Network Manager Security Admin Configuration Rule Collection Rules", + "description": "This module deploys an Azure Virtual Network Manager (AVNM) Security Admin Configuration Rule Collection Rule.\r\nA security admin configuration contains a set of rule collections. Each rule collection contains one or more security admin rules.", + "owner": "Azure/module-maintainers" }, "parameters": { "networkManagerName": { @@ -161,29 +167,29 @@ }, "name": { "type": "string", + "maxLength": 64, "metadata": { "description": "Required. The name of the rule." - }, - "maxLength": 64 + } }, "description": { "type": "string", "defaultValue": "", + "maxLength": 500, "metadata": { "description": "Optional. A description of the rule." - }, - "maxLength": 500 + } }, "access": { "type": "string", - "metadata": { - "description": "Required. Indicates the access allowed for this particular rule. \"Allow\" means traffic matching this rule will be allowed. \"Deny\" means traffic matching this rule will be blocked. \"AlwaysAllow\" means that traffic matching this rule will be allowed regardless of other rules with lower priority or user-defined NSGs." - }, "allowedValues": [ "Allow", "AlwaysAllow", "Deny" - ] + ], + "metadata": { + "description": "Required. Indicates the access allowed for this particular rule. \"Allow\" means traffic matching this rule will be allowed. \"Deny\" means traffic matching this rule will be blocked. \"AlwaysAllow\" means that traffic matching this rule will be allowed regardless of other rules with lower priority or user-defined NSGs." + } }, "destinationPortRanges": { "type": "array", @@ -201,27 +207,24 @@ }, "direction": { "type": "string", - "metadata": { - "description": "Required. Indicates if the traffic matched against the rule in inbound or outbound." - }, "allowedValues": [ "Inbound", "Outbound" - ] + ], + "metadata": { + "description": "Required. Indicates if the traffic matched against the rule in inbound or outbound." + } }, "priority": { "type": "int", + "minValue": 1, + "maxValue": 4096, "metadata": { "description": "Required. The priority of the rule. The value can be between 1 and 4096. The priority number must be unique for each rule in the collection. The lower the priority number, the higher the priority of the rule." - }, - "maxValue": 4096, - "minValue": 1 + } }, "protocol": { "type": "string", - "metadata": { - "description": "Required. Network protocol this rule applies to." - }, "allowedValues": [ "Ah", "Any", @@ -229,7 +232,10 @@ "Icmp", "Tcp", "Udp" - ] + ], + "metadata": { + "description": "Required. Network protocol this rule applies to." + } }, "sourcePortRanges": { "type": "array", diff --git a/modules/network/network-manager/security-admin-configuration/rule-collection/rule/main.json b/modules/network/network-manager/security-admin-configuration/rule-collection/rule/main.json index e62c17cea1..d78574bf06 100644 --- a/modules/network/network-manager/security-admin-configuration/rule-collection/rule/main.json +++ b/modules/network/network-manager/security-admin-configuration/rule-collection/rule/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11476125438194706048" - } + "version": "0.20.4.51522", + "templateHash": "493168310843879218" + }, + "name": "Network Manager Security Admin Configuration Rule Collection Rules", + "description": "This module deploys an Azure Virtual Network Manager (AVNM) Security Admin Configuration Rule Collection Rule.\r\nA security admin configuration contains a set of rule collections. Each rule collection contains one or more security admin rules.", + "owner": "Azure/module-maintainers" }, "parameters": { "networkManagerName": { @@ -29,29 +32,29 @@ }, "name": { "type": "string", + "maxLength": 64, "metadata": { "description": "Required. The name of the rule." - }, - "maxLength": 64 + } }, "description": { "type": "string", "defaultValue": "", + "maxLength": 500, "metadata": { "description": "Optional. A description of the rule." - }, - "maxLength": 500 + } }, "access": { "type": "string", - "metadata": { - "description": "Required. Indicates the access allowed for this particular rule. \"Allow\" means traffic matching this rule will be allowed. \"Deny\" means traffic matching this rule will be blocked. \"AlwaysAllow\" means that traffic matching this rule will be allowed regardless of other rules with lower priority or user-defined NSGs." - }, "allowedValues": [ "Allow", "AlwaysAllow", "Deny" - ] + ], + "metadata": { + "description": "Required. Indicates the access allowed for this particular rule. \"Allow\" means traffic matching this rule will be allowed. \"Deny\" means traffic matching this rule will be blocked. \"AlwaysAllow\" means that traffic matching this rule will be allowed regardless of other rules with lower priority or user-defined NSGs." + } }, "destinationPortRanges": { "type": "array", @@ -69,27 +72,24 @@ }, "direction": { "type": "string", - "metadata": { - "description": "Required. Indicates if the traffic matched against the rule in inbound or outbound." - }, "allowedValues": [ "Inbound", "Outbound" - ] + ], + "metadata": { + "description": "Required. Indicates if the traffic matched against the rule in inbound or outbound." + } }, "priority": { "type": "int", + "minValue": 1, + "maxValue": 4096, "metadata": { "description": "Required. The priority of the rule. The value can be between 1 and 4096. The priority number must be unique for each rule in the collection. The lower the priority number, the higher the priority of the rule." - }, - "maxValue": 4096, - "minValue": 1 + } }, "protocol": { "type": "string", - "metadata": { - "description": "Required. Network protocol this rule applies to." - }, "allowedValues": [ "Ah", "Any", @@ -97,7 +97,10 @@ "Icmp", "Tcp", "Udp" - ] + ], + "metadata": { + "description": "Required. Network protocol this rule applies to." + } }, "sourcePortRanges": { "type": "array", diff --git a/modules/network/network-security-group/.bicep/nested_roleAssignments.bicep b/modules/network/network-security-group/.bicep/nested_roleAssignments.bicep index 926fda2165..c84dea0a9e 100644 --- a/modules/network/network-security-group/.bicep/nested_roleAssignments.bicep +++ b/modules/network/network-security-group/.bicep/nested_roleAssignments.bicep @@ -78,7 +78,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource networkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2021-08-01' existing = { +resource networkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2023-04-01' existing = { name: last(split(resourceId, '/'))! } diff --git a/modules/network/network-security-group/.test/common/dependencies.bicep b/modules/network/network-security-group/.test/common/dependencies.bicep index a57e2a9868..951c71af97 100644 --- a/modules/network/network-security-group/.test/common/dependencies.bicep +++ b/modules/network/network-security-group/.test/common/dependencies.bicep @@ -8,13 +8,13 @@ param managedIdentityName string param applicationSecurityGroupName string resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } -resource applicationSecurityGroup 'Microsoft.Network/applicationSecurityGroups@2022-01-01' = { - name: applicationSecurityGroupName - location: location +resource applicationSecurityGroup 'Microsoft.Network/applicationSecurityGroups@2023-04-01' = { + name: applicationSecurityGroupName + location: location } @description('The principal ID of the created Managed Identity.') diff --git a/modules/network/network-security-group/.test/common/main.test.bicep b/modules/network/network-security-group/.test/common/main.test.bicep index 8de614a0a2..fabfb5ecf0 100644 --- a/modules/network/network-security-group/.test/common/main.test.bicep +++ b/modules/network/network-security-group/.test/common/main.test.bicep @@ -64,7 +64,6 @@ module testDeployment '../../main.bicep' = { params: { enableDefaultTelemetry: enableDefaultTelemetry name: '${namePrefix}${serviceShort}001' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/network/network-security-group/README.md b/modules/network/network-security-group/README.md index 4155d7e0db..7e79e84023 100644 --- a/modules/network/network-security-group/README.md +++ b/modules/network/network-security-group/README.md @@ -17,8 +17,8 @@ This module deploys a Network security Group (NSG). | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/networkSecurityGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/networkSecurityGroups) | -| `Microsoft.Network/networkSecurityGroups/securityRules` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/networkSecurityGroups/securityRules) | +| `Microsoft.Network/networkSecurityGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/networkSecurityGroups) | +| `Microsoft.Network/networkSecurityGroups/securityRules` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/networkSecurityGroups/securityRules) | ## Parameters @@ -35,7 +35,6 @@ This module deploys a Network security Group (NSG). | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, NetworkSecurityGroupEvent, NetworkSecurityGroupRuleCounter]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | | `diagnosticWorkspaceId` | string | `''` | | Resource ID of the diagnostic log analytics workspace. | @@ -183,7 +182,6 @@ module networkSecurityGroup './network/network-security-group/main.bicep' = { // Non-required parameters diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -292,9 +290,6 @@ module networkSecurityGroup './network/network-security-group/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/network/network-security-group/main.bicep b/modules/network/network-security-group/main.bicep index 8503d03244..5ee9437903 100644 --- a/modules/network/network-security-group/main.bicep +++ b/modules/network/network-security-group/main.bicep @@ -17,11 +17,6 @@ param flushConnection bool = false @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic log analytics workspace.') param diagnosticWorkspaceId string = '' @@ -67,20 +62,12 @@ var enableReferencedModulesTelemetry = false var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -96,7 +83,7 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource networkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2022-07-01' = { +resource networkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2023-04-01' = { name: name location: location tags: tags diff --git a/modules/network/network-security-group/main.json b/modules/network/network-security-group/main.json index 2b6bcdeb53..365a31afdd 100644 --- a/modules/network/network-security-group/main.json +++ b/modules/network/network-security-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5818720461189205578" - } + "version": "0.20.4.51522", + "templateHash": "13278679090804720402" + }, + "name": "Network Security Groups", + "description": "This module deploys a Network security Group (NSG).", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -43,15 +46,6 @@ "description": "Optional. Resource ID of the diagnostic storage account." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticWorkspaceId": { "type": "string", "defaultValue": "", @@ -76,14 +70,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -136,16 +130,12 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], "enableReferencedModulesTelemetry": false, - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" }, "resources": [ { @@ -164,7 +154,7 @@ }, { "type": "Microsoft.Network/networkSecurityGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -282,9 +272,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11939435370198735476" - } + "version": "0.20.4.51522", + "templateHash": "4767935764969237300" + }, + "name": "Network Security Group (NSG) Security Rules", + "description": "This module deploys a Network Security Group (NSG) Security Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -443,7 +436,7 @@ }, { "type": "Microsoft.Network/networkSecurityGroups/securityRules", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('networkSecurityGroupName'), parameters('name'))]", "properties": { "access": "[parameters('access')]", @@ -527,8 +520,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14760097731901350181" + "version": "0.20.4.51522", + "templateHash": "15810256612189281963" } }, "parameters": { @@ -698,7 +691,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/networkSecurityGroups', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/networkSecurityGroups', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/network-security-group/security-rule/README.md b/modules/network/network-security-group/security-rule/README.md index 6dcd827065..57868287ca 100644 --- a/modules/network/network-security-group/security-rule/README.md +++ b/modules/network/network-security-group/security-rule/README.md @@ -13,7 +13,7 @@ This module deploys a Network Security Group (NSG) Security Rule. | Resource Type | API Version | | :-- | :-- | -| `Microsoft.Network/networkSecurityGroups/securityRules` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/networkSecurityGroups/securityRules) | +| `Microsoft.Network/networkSecurityGroups/securityRules` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/networkSecurityGroups/securityRules) | ## Parameters diff --git a/modules/network/network-security-group/security-rule/main.bicep b/modules/network/network-security-group/security-rule/main.bicep index 8dfda5c483..6ecda23638 100644 --- a/modules/network/network-security-group/security-rule/main.bicep +++ b/modules/network/network-security-group/security-rule/main.bicep @@ -85,11 +85,11 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource networkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2022-07-01' existing = { +resource networkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2023-04-01' existing = { name: networkSecurityGroupName } -resource securityRule 'Microsoft.Network/networkSecurityGroups/securityRules@2022-07-01' = { +resource securityRule 'Microsoft.Network/networkSecurityGroups/securityRules@2023-04-01' = { name: name parent: networkSecurityGroup properties: { diff --git a/modules/network/network-security-group/security-rule/main.json b/modules/network/network-security-group/security-rule/main.json index 9dc0f44146..f926892555 100644 --- a/modules/network/network-security-group/security-rule/main.json +++ b/modules/network/network-security-group/security-rule/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11939435370198735476" - } + "version": "0.20.4.51522", + "templateHash": "4767935764969237300" + }, + "name": "Network Security Group (NSG) Security Rules", + "description": "This module deploys a Network Security Group (NSG) Security Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -165,7 +168,7 @@ }, { "type": "Microsoft.Network/networkSecurityGroups/securityRules", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('networkSecurityGroupName'), parameters('name'))]", "properties": { "access": "[parameters('access')]", diff --git a/modules/network/network-watcher/.bicep/nested_roleAssignments.bicep b/modules/network/network-watcher/.bicep/nested_roleAssignments.bicep index 4d8318611f..b81fb2f9e5 100644 --- a/modules/network/network-watcher/.bicep/nested_roleAssignments.bicep +++ b/modules/network/network-watcher/.bicep/nested_roleAssignments.bicep @@ -78,7 +78,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource networkWatcher 'Microsoft.Network/networkWatchers@2022-07-01' existing = { +resource networkWatcher 'Microsoft.Network/networkWatchers@2023-04-01' existing = { name: last(split(resourceId, '/'))! } diff --git a/modules/network/network-watcher/.test/common/dependencies.bicep b/modules/network/network-watcher/.test/common/dependencies.bicep index e9c49b8ddc..ad8b34b848 100644 --- a/modules/network/network-watcher/.test/common/dependencies.bicep +++ b/modules/network/network-watcher/.test/common/dependencies.bicep @@ -22,113 +22,113 @@ param password string = newGuid() var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } -resource firstNetworkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2022-05-01' = { - name: firstNetworkSecurityGroupName - location: location +resource firstNetworkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2023-04-01' = { + name: firstNetworkSecurityGroupName + location: location } -resource secondNetworkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2022-05-01' = { - name: secondNetworkSecurityGroupName - location: location +resource secondNetworkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2023-04-01' = { + name: secondNetworkSecurityGroupName + location: location } -resource networkInterface 'Microsoft.Network/networkInterfaces@2022-05-01' = { - name: '${virtualMachineName}-nic' - location: location - properties: { - ipConfigurations: [ - { - name: 'ipconfig01' - properties: { - subnet: { - id: virtualNetwork.properties.subnets[0].id - } - } - } - ] - } +resource networkInterface 'Microsoft.Network/networkInterfaces@2023-04-01' = { + name: '${virtualMachineName}-nic' + location: location + properties: { + ipConfigurations: [ + { + name: 'ipconfig01' + properties: { + subnet: { + id: virtualNetwork.properties.subnets[0].id + } + } + } + ] + } } resource virtualMachine 'Microsoft.Compute/virtualMachines@2022-08-01' = { - name: virtualMachineName - location: location - properties: { - networkProfile: { - networkInterfaces: [ - { - id: networkInterface.id - properties: { - deleteOption: 'Delete' - primary: true - } - } - ] - } - storageProfile: { - imageReference: { - publisher: 'Canonical' - offer: '0001-com-ubuntu-server-jammy' - sku: '22_04-lts-gen2' - version: 'latest' - } - osDisk: { - deleteOption: 'Delete' - createOption: 'FromImage' - } - } - hardwareProfile: { - vmSize: 'Standard_B1ms' - } - osProfile: { - adminUsername: '${virtualMachineName}cake' - adminPassword: password - computerName: virtualMachineName - linuxConfiguration: { - disablePasswordAuthentication: false - } + name: virtualMachineName + location: location + properties: { + networkProfile: { + networkInterfaces: [ + { + id: networkInterface.id + properties: { + deleteOption: 'Delete' + primary: true + } } + ] + } + storageProfile: { + imageReference: { + publisher: 'Canonical' + offer: '0001-com-ubuntu-server-jammy' + sku: '22_04-lts-gen2' + version: 'latest' + } + osDisk: { + deleteOption: 'Delete' + createOption: 'FromImage' + } + } + hardwareProfile: { + vmSize: 'Standard_B1ms' } + osProfile: { + adminUsername: '${virtualMachineName}cake' + adminPassword: password + computerName: virtualMachineName + linuxConfiguration: { + disablePasswordAuthentication: false + } + } + } } resource extension 'Microsoft.Compute/virtualMachines/extensions@2021-07-01' = { - name: 'NetworkWatcherAgent' - parent: virtualMachine - location: location - properties: { - publisher: 'Microsoft.Azure.NetworkWatcher' - type: 'NetworkWatcherAgentLinux' - typeHandlerVersion: '1.4' - autoUpgradeMinorVersion: true - enableAutomaticUpgrade: false - settings: {} - protectedSettings: {} - suppressFailures: false - } + name: 'NetworkWatcherAgent' + parent: virtualMachine + location: location + properties: { + publisher: 'Microsoft.Azure.NetworkWatcher' + type: 'NetworkWatcherAgentLinux' + typeHandlerVersion: '1.4' + autoUpgradeMinorVersion: true + enableAutomaticUpgrade: false + settings: {} + protectedSettings: {} + suppressFailures: false + } } @description('The principal ID of the created Managed Identity.') diff --git a/modules/network/network-watcher/.test/common/main.test.bicep b/modules/network/network-watcher/.test/common/main.test.bicep index a8965015a2..12c7d3deaa 100644 --- a/modules/network/network-watcher/.test/common/main.test.bicep +++ b/modules/network/network-watcher/.test/common/main.test.bicep @@ -65,7 +65,7 @@ module diagnosticDependencies '../../../../.shared/.templates/diagnostic.depende var testLocation = 'westeurope' module testDeployment '../../main.bicep' = { scope: resourceGroup - name: '${uniqueString(deployment().name, location)}-test-${serviceShort}' + name: '${uniqueString(deployment().name, testLocation)}-test-${serviceShort}' params: { enableDefaultTelemetry: enableDefaultTelemetry name: 'NetworkWatcher_${testLocation}' diff --git a/modules/network/network-watcher/.test/min/main.test.bicep b/modules/network/network-watcher/.test/min/main.test.bicep index 451a5f6b11..f3694798e4 100644 --- a/modules/network/network-watcher/.test/min/main.test.bicep +++ b/modules/network/network-watcher/.test/min/main.test.bicep @@ -38,7 +38,7 @@ resource resourceGroup 'Microsoft.Resources/resourceGroups@2021-04-01' = { var testLocation = 'northeurope' module testDeployment '../../main.bicep' = { scope: resourceGroup - name: '${uniqueString(deployment().name, location)}-test-${serviceShort}' + name: '${uniqueString(deployment().name, testLocation)}-test-${serviceShort}' params: { enableDefaultTelemetry: enableDefaultTelemetry // Note: This value is not required and only set to enable testing diff --git a/modules/network/network-watcher/README.md b/modules/network/network-watcher/README.md index 4c74e3768f..a0c345ab40 100644 --- a/modules/network/network-watcher/README.md +++ b/modules/network/network-watcher/README.md @@ -16,9 +16,9 @@ This module deploys a Network Watcher. | :-- | :-- | | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | -| `Microsoft.Network/networkWatchers` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/networkWatchers) | -| `Microsoft.Network/networkWatchers/connectionMonitors` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/networkWatchers/connectionMonitors) | -| `Microsoft.Network/networkWatchers/flowLogs` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/networkWatchers/flowLogs) | +| `Microsoft.Network/networkWatchers` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/networkWatchers) | +| `Microsoft.Network/networkWatchers/connectionMonitors` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/networkWatchers/connectionMonitors) | +| `Microsoft.Network/networkWatchers/flowLogs` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/networkWatchers/flowLogs) | ## Parameters @@ -164,7 +164,7 @@ The following module usage examples are retrieved from the content of the files ```bicep module networkWatcher './network/network-watcher/main.bicep' = { - name: '${uniqueString(deployment().name, location)}-test-nnwcom' + name: '${uniqueString(deployment().name, testLocation)}-test-nnwcom' params: { connectionMonitors: [ { @@ -381,7 +381,7 @@ module networkWatcher './network/network-watcher/main.bicep' = { ```bicep module networkWatcher './network/network-watcher/main.bicep' = { - name: '${uniqueString(deployment().name, location)}-test-nnwmin' + name: '${uniqueString(deployment().name, testLocation)}-test-nnwmin' params: { enableDefaultTelemetry: '' location: '' diff --git a/modules/network/network-watcher/connection-monitor/README.md b/modules/network/network-watcher/connection-monitor/README.md index 622399cc3d..db814f4700 100644 --- a/modules/network/network-watcher/connection-monitor/README.md +++ b/modules/network/network-watcher/connection-monitor/README.md @@ -13,7 +13,7 @@ This module deploys a Network Watcher Connection Monitor. | Resource Type | API Version | | :-- | :-- | -| `Microsoft.Network/networkWatchers/connectionMonitors` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/networkWatchers/connectionMonitors) | +| `Microsoft.Network/networkWatchers/connectionMonitors` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/networkWatchers/connectionMonitors) | ## Parameters diff --git a/modules/network/network-watcher/connection-monitor/main.bicep b/modules/network/network-watcher/connection-monitor/main.bicep index 26b6c1413b..c150269b10 100644 --- a/modules/network/network-watcher/connection-monitor/main.bicep +++ b/modules/network/network-watcher/connection-monitor/main.bicep @@ -50,11 +50,11 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource networkWatcher 'Microsoft.Network/networkWatchers@2022-07-01' existing = { +resource networkWatcher 'Microsoft.Network/networkWatchers@2023-04-01' existing = { name: networkWatcherName } -resource connectionMonitor 'Microsoft.Network/networkWatchers/connectionMonitors@2022-07-01' = { +resource connectionMonitor 'Microsoft.Network/networkWatchers/connectionMonitors@2023-04-01' = { name: name parent: networkWatcher tags: tags diff --git a/modules/network/network-watcher/connection-monitor/main.json b/modules/network/network-watcher/connection-monitor/main.json index 7386e8c0fa..e76438a305 100644 --- a/modules/network/network-watcher/connection-monitor/main.json +++ b/modules/network/network-watcher/connection-monitor/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17070074753032626378" - } + "version": "0.20.4.51522", + "templateHash": "9435199226792787351" + }, + "name": "Network Watchers Connection Monitors", + "description": "This module deploys a Network Watcher Connection Monitor.", + "owner": "Azure/module-maintainers" }, "parameters": { "networkWatcherName": { @@ -92,7 +95,7 @@ }, { "type": "Microsoft.Network/networkWatchers/connectionMonitors", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('networkWatcherName'), parameters('name'))]", "tags": "[parameters('tags')]", "location": "[parameters('location')]", @@ -131,7 +134,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/networkWatchers/connectionMonitors', parameters('networkWatcherName'), parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/networkWatchers/connectionMonitors', parameters('networkWatcherName'), parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/network-watcher/flow-log/README.md b/modules/network/network-watcher/flow-log/README.md index 5e964425c6..e0f8e669df 100644 --- a/modules/network/network-watcher/flow-log/README.md +++ b/modules/network/network-watcher/flow-log/README.md @@ -14,7 +14,7 @@ This module controls the Network Security Group Flow Logs and analytics settings | Resource Type | API Version | | :-- | :-- | -| `Microsoft.Network/networkWatchers/flowLogs` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/networkWatchers/flowLogs) | +| `Microsoft.Network/networkWatchers/flowLogs` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/networkWatchers/flowLogs) | ## Parameters diff --git a/modules/network/network-watcher/flow-log/main.bicep b/modules/network/network-watcher/flow-log/main.bicep index 83e96a128d..11ab0bfa85 100644 --- a/modules/network/network-watcher/flow-log/main.bicep +++ b/modules/network/network-watcher/flow-log/main.bicep @@ -73,11 +73,11 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource networkWatcher 'Microsoft.Network/networkWatchers@2022-07-01' existing = { +resource networkWatcher 'Microsoft.Network/networkWatchers@2023-04-01' existing = { name: networkWatcherName } -resource flowLog 'Microsoft.Network/networkWatchers/flowLogs@2022-07-01' = { +resource flowLog 'Microsoft.Network/networkWatchers/flowLogs@2023-04-01' = { name: name parent: networkWatcher tags: tags diff --git a/modules/network/network-watcher/flow-log/main.json b/modules/network/network-watcher/flow-log/main.json index 3fb7ed43c9..1a9023a4ba 100644 --- a/modules/network/network-watcher/flow-log/main.json +++ b/modules/network/network-watcher/flow-log/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12327372918876579570" - } + "version": "0.20.4.51522", + "templateHash": "11308204478162486459" + }, + "name": "NSG Flow Logs", + "description": "This module controls the Network Security Group Flow Logs and analytics settings.\r\n**Note: this module must be run on the Resource Group where Network Watcher is deployed**", + "owner": "Azure/module-maintainers" }, "parameters": { "networkWatcherName": { @@ -88,8 +91,8 @@ "retentionInDays": { "type": "int", "defaultValue": 365, - "maxValue": 365, "minValue": 0, + "maxValue": 365, "metadata": { "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." } @@ -122,7 +125,7 @@ }, { "type": "Microsoft.Network/networkWatchers/flowLogs", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('networkWatcherName'), parameters('name'))]", "tags": "[parameters('tags')]", "location": "[parameters('location')]", @@ -169,7 +172,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/networkWatchers/flowLogs', parameters('networkWatcherName'), parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/networkWatchers/flowLogs', parameters('networkWatcherName'), parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/network-watcher/main.bicep b/modules/network/network-watcher/main.bicep index b88325faf5..2fbae1f1cd 100644 --- a/modules/network/network-watcher/main.bicep +++ b/modules/network/network-watcher/main.bicep @@ -46,7 +46,7 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource networkWatcher 'Microsoft.Network/networkWatchers@2022-07-01' = { +resource networkWatcher 'Microsoft.Network/networkWatchers@2023-04-01' = { name: name location: location tags: tags diff --git a/modules/network/network-watcher/main.json b/modules/network/network-watcher/main.json index f017b14eee..c696c5ffef 100644 --- a/modules/network/network-watcher/main.json +++ b/modules/network/network-watcher/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "850842372551317782" - } + "version": "0.20.4.51522", + "templateHash": "13223558022940005793" + }, + "name": "Network Watchers", + "description": "This module deploys a Network Watcher.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -41,14 +44,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -92,7 +95,7 @@ }, { "type": "Microsoft.Network/networkWatchers", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -146,8 +149,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6580260885848172083" + "version": "0.20.4.51522", + "templateHash": "1939834340828490356" } }, "parameters": { @@ -323,9 +326,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17070074753032626378" - } + "version": "0.20.4.51522", + "templateHash": "9435199226792787351" + }, + "name": "Network Watchers Connection Monitors", + "description": "This module deploys a Network Watcher Connection Monitor.", + "owner": "Azure/module-maintainers" }, "parameters": { "networkWatcherName": { @@ -411,7 +417,7 @@ }, { "type": "Microsoft.Network/networkWatchers/connectionMonitors", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('networkWatcherName'), parameters('name'))]", "tags": "[parameters('tags')]", "location": "[parameters('location')]", @@ -450,7 +456,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/networkWatchers/connectionMonitors', parameters('networkWatcherName'), parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/networkWatchers/connectionMonitors', parameters('networkWatcherName'), parameters('name')), '2023-04-01', 'full').location]" } } } @@ -499,9 +505,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12327372918876579570" - } + "version": "0.20.4.51522", + "templateHash": "11308204478162486459" + }, + "name": "NSG Flow Logs", + "description": "This module controls the Network Security Group Flow Logs and analytics settings.\r\n**Note: this module must be run on the Resource Group where Network Watcher is deployed**", + "owner": "Azure/module-maintainers" }, "parameters": { "networkWatcherName": { @@ -583,8 +592,8 @@ "retentionInDays": { "type": "int", "defaultValue": 365, - "maxValue": 365, "minValue": 0, + "maxValue": 365, "metadata": { "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." } @@ -617,7 +626,7 @@ }, { "type": "Microsoft.Network/networkWatchers/flowLogs", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('networkWatcherName'), parameters('name'))]", "tags": "[parameters('tags')]", "location": "[parameters('location')]", @@ -664,7 +673,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/networkWatchers/flowLogs', parameters('networkWatcherName'), parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/networkWatchers/flowLogs', parameters('networkWatcherName'), parameters('name')), '2023-04-01', 'full').location]" } } } @@ -701,7 +710,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/networkWatchers', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/networkWatchers', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/private-dns-zone/.test/common/dependencies.bicep b/modules/network/private-dns-zone/.test/common/dependencies.bicep index 581b2cd449..6a414d2247 100644 --- a/modules/network/private-dns-zone/.test/common/dependencies.bicep +++ b/modules/network/private-dns-zone/.test/common/dependencies.bicep @@ -9,29 +9,29 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network.') diff --git a/modules/network/private-dns-zone/a/main.json b/modules/network/private-dns-zone/a/main.json index 8f902cdbd8..413cc464b5 100644 --- a/modules/network/private-dns-zone/a/main.json +++ b/modules/network/private-dns-zone/a/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6047601354596152845" - } + "version": "0.20.4.51522", + "templateHash": "2464749993448285338" + }, + "name": "Private DNS Zone A record", + "description": "This module deploys a Private DNS Zone A record.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateDnsZoneName": { @@ -116,8 +119,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16695146267293590018" + "version": "0.20.4.51522", + "templateHash": "16462248861146180112" } }, "parameters": { diff --git a/modules/network/private-dns-zone/aaaa/main.json b/modules/network/private-dns-zone/aaaa/main.json index d42e147d5a..506b619a23 100644 --- a/modules/network/private-dns-zone/aaaa/main.json +++ b/modules/network/private-dns-zone/aaaa/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6638492265857422958" - } + "version": "0.20.4.51522", + "templateHash": "2479547994885250676" + }, + "name": "Private DNS Zone AAAA record", + "description": "This module deploys a Private DNS Zone AAAA record.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateDnsZoneName": { @@ -116,8 +119,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12606064376282730035" + "version": "0.20.4.51522", + "templateHash": "8284082844313029952" } }, "parameters": { diff --git a/modules/network/private-dns-zone/cname/main.json b/modules/network/private-dns-zone/cname/main.json index 9a41eb654a..ac82b9556b 100644 --- a/modules/network/private-dns-zone/cname/main.json +++ b/modules/network/private-dns-zone/cname/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11683398732491402698" - } + "version": "0.20.4.51522", + "templateHash": "3131685819107198557" + }, + "name": "Private DNS Zone CNAME record", + "description": "This module deploys a Private DNS Zone CNAME record.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateDnsZoneName": { @@ -116,8 +119,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17914042186704125412" + "version": "0.20.4.51522", + "templateHash": "14977392232463085529" } }, "parameters": { diff --git a/modules/network/private-dns-zone/main.json b/modules/network/private-dns-zone/main.json index 7338bde860..8ab32eb667 100644 --- a/modules/network/private-dns-zone/main.json +++ b/modules/network/private-dns-zone/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4933813900023249033" - } + "version": "0.20.4.51522", + "templateHash": "8712959825749640715" + }, + "name": "Private DNS Zones", + "description": "This module deploys a Private DNS zone.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -102,14 +105,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "enableDefaultTelemetry": { "type": "bool", @@ -192,9 +195,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6047601354596152845" - } + "version": "0.20.4.51522", + "templateHash": "2464749993448285338" + }, + "name": "Private DNS Zone A record", + "description": "This module deploys a Private DNS Zone A record.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateDnsZoneName": { @@ -304,8 +310,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16695146267293590018" + "version": "0.20.4.51522", + "templateHash": "16462248861146180112" } }, "parameters": { @@ -511,9 +517,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6638492265857422958" - } + "version": "0.20.4.51522", + "templateHash": "2479547994885250676" + }, + "name": "Private DNS Zone AAAA record", + "description": "This module deploys a Private DNS Zone AAAA record.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateDnsZoneName": { @@ -623,8 +632,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12606064376282730035" + "version": "0.20.4.51522", + "templateHash": "8284082844313029952" } }, "parameters": { @@ -830,9 +839,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11683398732491402698" - } + "version": "0.20.4.51522", + "templateHash": "3131685819107198557" + }, + "name": "Private DNS Zone CNAME record", + "description": "This module deploys a Private DNS Zone CNAME record.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateDnsZoneName": { @@ -942,8 +954,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17914042186704125412" + "version": "0.20.4.51522", + "templateHash": "14977392232463085529" } }, "parameters": { @@ -1155,9 +1167,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6723715268718525683" - } + "version": "0.20.4.51522", + "templateHash": "6965287962374254577" + }, + "name": "Private DNS Zone MX record", + "description": "This module deploys a Private DNS Zone MX record.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateDnsZoneName": { @@ -1267,8 +1282,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8278394296424173490" + "version": "0.20.4.51522", + "templateHash": "11594799085721281275" } }, "parameters": { @@ -1474,9 +1489,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18014827023007277307" - } + "version": "0.20.4.51522", + "templateHash": "13259276818307387958" + }, + "name": "Private DNS Zone PTR record", + "description": "This module deploys a Private DNS Zone PTR record.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateDnsZoneName": { @@ -1586,8 +1604,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18134124109529472754" + "version": "0.20.4.51522", + "templateHash": "11481493487541604106" } }, "parameters": { @@ -1793,9 +1811,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8747868386608568641" - } + "version": "0.20.4.51522", + "templateHash": "1534736495493771844" + }, + "name": "Private DNS Zone SOA record", + "description": "This module deploys a Private DNS Zone SOA record.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateDnsZoneName": { @@ -1905,8 +1926,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13404705877173488957" + "version": "0.20.4.51522", + "templateHash": "13036989829941135965" } }, "parameters": { @@ -2112,9 +2133,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2085806698183309640" - } + "version": "0.20.4.51522", + "templateHash": "6444239705368252849" + }, + "name": "Private DNS Zone SRV record", + "description": "This module deploys a Private DNS Zone SRV record.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateDnsZoneName": { @@ -2224,8 +2248,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5929739225162043332" + "version": "0.20.4.51522", + "templateHash": "17805809595422297514" } }, "parameters": { @@ -2431,9 +2455,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6988918118495561067" - } + "version": "0.20.4.51522", + "templateHash": "11503781556355030458" + }, + "name": "Private DNS Zone TXT record", + "description": "This module deploys a Private DNS Zone TXT record.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateDnsZoneName": { @@ -2543,8 +2570,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1209368876108232061" + "version": "0.20.4.51522", + "templateHash": "9559644743323745935" } }, "parameters": { @@ -2750,9 +2777,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3078466302064524268" - } + "version": "0.20.4.51522", + "templateHash": "8504562326898440676" + }, + "name": "Private DNS Zone Virtual Network Link", + "description": "This module deploys a Private DNS Zone Virtual Network Link.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateDnsZoneName": { @@ -2902,8 +2932,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "936813671106035056" + "version": "0.20.4.51522", + "templateHash": "7847385116490998659" } }, "parameters": { diff --git a/modules/network/private-dns-zone/mx/main.json b/modules/network/private-dns-zone/mx/main.json index b33ec7a269..418f721f60 100644 --- a/modules/network/private-dns-zone/mx/main.json +++ b/modules/network/private-dns-zone/mx/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6723715268718525683" - } + "version": "0.20.4.51522", + "templateHash": "6965287962374254577" + }, + "name": "Private DNS Zone MX record", + "description": "This module deploys a Private DNS Zone MX record.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateDnsZoneName": { @@ -116,8 +119,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8278394296424173490" + "version": "0.20.4.51522", + "templateHash": "11594799085721281275" } }, "parameters": { diff --git a/modules/network/private-dns-zone/ptr/main.json b/modules/network/private-dns-zone/ptr/main.json index 62661e401f..06a5084efd 100644 --- a/modules/network/private-dns-zone/ptr/main.json +++ b/modules/network/private-dns-zone/ptr/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18014827023007277307" - } + "version": "0.20.4.51522", + "templateHash": "13259276818307387958" + }, + "name": "Private DNS Zone PTR record", + "description": "This module deploys a Private DNS Zone PTR record.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateDnsZoneName": { @@ -116,8 +119,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18134124109529472754" + "version": "0.20.4.51522", + "templateHash": "11481493487541604106" } }, "parameters": { diff --git a/modules/network/private-dns-zone/soa/main.json b/modules/network/private-dns-zone/soa/main.json index 211543a400..e3427de316 100644 --- a/modules/network/private-dns-zone/soa/main.json +++ b/modules/network/private-dns-zone/soa/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8747868386608568641" - } + "version": "0.20.4.51522", + "templateHash": "1534736495493771844" + }, + "name": "Private DNS Zone SOA record", + "description": "This module deploys a Private DNS Zone SOA record.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateDnsZoneName": { @@ -116,8 +119,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13404705877173488957" + "version": "0.20.4.51522", + "templateHash": "13036989829941135965" } }, "parameters": { diff --git a/modules/network/private-dns-zone/srv/main.json b/modules/network/private-dns-zone/srv/main.json index 3a458c1609..f52d859ff7 100644 --- a/modules/network/private-dns-zone/srv/main.json +++ b/modules/network/private-dns-zone/srv/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2085806698183309640" - } + "version": "0.20.4.51522", + "templateHash": "6444239705368252849" + }, + "name": "Private DNS Zone SRV record", + "description": "This module deploys a Private DNS Zone SRV record.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateDnsZoneName": { @@ -116,8 +119,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5929739225162043332" + "version": "0.20.4.51522", + "templateHash": "17805809595422297514" } }, "parameters": { diff --git a/modules/network/private-dns-zone/txt/main.json b/modules/network/private-dns-zone/txt/main.json index 68ca6b8e4c..9bc41b0ee0 100644 --- a/modules/network/private-dns-zone/txt/main.json +++ b/modules/network/private-dns-zone/txt/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6988918118495561067" - } + "version": "0.20.4.51522", + "templateHash": "11503781556355030458" + }, + "name": "Private DNS Zone TXT record", + "description": "This module deploys a Private DNS Zone TXT record.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateDnsZoneName": { @@ -116,8 +119,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1209368876108232061" + "version": "0.20.4.51522", + "templateHash": "9559644743323745935" } }, "parameters": { diff --git a/modules/network/private-dns-zone/virtual-network-link/main.json b/modules/network/private-dns-zone/virtual-network-link/main.json index 3deb666646..7d0bc4e594 100644 --- a/modules/network/private-dns-zone/virtual-network-link/main.json +++ b/modules/network/private-dns-zone/virtual-network-link/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3078466302064524268" - } + "version": "0.20.4.51522", + "templateHash": "8504562326898440676" + }, + "name": "Private DNS Zone Virtual Network Link", + "description": "This module deploys a Private DNS Zone Virtual Network Link.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateDnsZoneName": { diff --git a/modules/network/private-endpoint/.bicep/nested_roleAssignments.bicep b/modules/network/private-endpoint/.bicep/nested_roleAssignments.bicep index f2e1414197..817cb46aa6 100644 --- a/modules/network/private-endpoint/.bicep/nested_roleAssignments.bicep +++ b/modules/network/private-endpoint/.bicep/nested_roleAssignments.bicep @@ -78,7 +78,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource privateEndpoint 'Microsoft.Network/privateEndpoints@2021-08-01' existing = { +resource privateEndpoint 'Microsoft.Network/privateEndpoints@2023-04-01' existing = { name: last(split(resourceId, '/'))! } diff --git a/modules/network/private-endpoint/.test/common/dependencies.bicep b/modules/network/private-endpoint/.test/common/dependencies.bicep index 39fcecbe59..2ce877b015 100644 --- a/modules/network/private-endpoint/.test/common/dependencies.bicep +++ b/modules/network/private-endpoint/.test/common/dependencies.bicep @@ -15,68 +15,68 @@ param applicationSecurityGroupName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource keyVault 'Microsoft.KeyVault/vaults@2022-07-01' = { - name: keyVaultName - location: location - properties: { - sku: { - family: 'A' - name: 'standard' - } - tenantId: tenant().tenantId - enablePurgeProtection: null - enabledForTemplateDeployment: true - enabledForDiskEncryption: true - enabledForDeployment: true - enableRbacAuthorization: true - accessPolicies: [] + name: keyVaultName + location: location + properties: { + sku: { + family: 'A' + name: 'standard' } + tenantId: tenant().tenantId + enablePurgeProtection: null + enabledForTemplateDeployment: true + enabledForDiskEncryption: true + enabledForDeployment: true + enableRbacAuthorization: true + accessPolicies: [] + } } -resource applicationSecurityGroup 'Microsoft.Network/applicationSecurityGroups@2022-05-01' = { - name: applicationSecurityGroupName - location: location +resource applicationSecurityGroup 'Microsoft.Network/applicationSecurityGroups@2023-04-01' = { + name: applicationSecurityGroupName + location: location } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.vaultcore.azure.net' - location: 'global' + name: 'privatelink.vaultcore.azure.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/network/private-endpoint/.test/min/dependencies.bicep b/modules/network/private-endpoint/.test/min/dependencies.bicep index 6237b32712..536bf16704 100644 --- a/modules/network/private-endpoint/.test/min/dependencies.bicep +++ b/modules/network/private-endpoint/.test/min/dependencies.bicep @@ -9,42 +9,42 @@ param keyVaultName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource keyVault 'Microsoft.KeyVault/vaults@2022-07-01' = { - name: keyVaultName - location: location - properties: { - sku: { - family: 'A' - name: 'standard' - } - tenantId: tenant().tenantId - enablePurgeProtection: null - enabledForTemplateDeployment: true - enabledForDiskEncryption: true - enabledForDeployment: true - enableRbacAuthorization: true - accessPolicies: [] + name: keyVaultName + location: location + properties: { + sku: { + family: 'A' + name: 'standard' } + tenantId: tenant().tenantId + enablePurgeProtection: null + enabledForTemplateDeployment: true + enabledForDiskEncryption: true + enabledForDeployment: true + enableRbacAuthorization: true + accessPolicies: [] + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/network/private-endpoint/README.md b/modules/network/private-endpoint/README.md index 18541322bd..1480d9ba84 100644 --- a/modules/network/private-endpoint/README.md +++ b/modules/network/private-endpoint/README.md @@ -16,8 +16,8 @@ This module deploys a Private Endpoint. | :-- | :-- | | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | ### Resource dependency diff --git a/modules/network/private-endpoint/main.bicep b/modules/network/private-endpoint/main.bicep index b0420647e1..c43e6c55ef 100644 --- a/modules/network/private-endpoint/main.bicep +++ b/modules/network/private-endpoint/main.bicep @@ -66,7 +66,7 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource privateEndpoint 'Microsoft.Network/privateEndpoints@2022-07-01' = { +resource privateEndpoint 'Microsoft.Network/privateEndpoints@2023-04-01' = { name: name location: location tags: tags diff --git a/modules/network/private-endpoint/main.json b/modules/network/private-endpoint/main.json index 8bb7cfb2b2..ab7eacf336 100644 --- a/modules/network/private-endpoint/main.json +++ b/modules/network/private-endpoint/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -71,14 +74,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -136,7 +139,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -201,9 +204,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -214,8 +220,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -266,7 +272,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -336,8 +342,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -507,7 +513,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/private-endpoint/private-dns-zone-group/README.md b/modules/network/private-endpoint/private-dns-zone-group/README.md index 08764e80c8..e1d46b8986 100644 --- a/modules/network/private-endpoint/private-dns-zone-group/README.md +++ b/modules/network/private-endpoint/private-dns-zone-group/README.md @@ -13,7 +13,7 @@ This module deploys a Private Endpoint Private DNS Zone Group. | Resource Type | API Version | | :-- | :-- | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | ## Parameters diff --git a/modules/network/private-endpoint/private-dns-zone-group/main.bicep b/modules/network/private-endpoint/private-dns-zone-group/main.bicep index 04ad6b03e2..316f0800b6 100644 --- a/modules/network/private-endpoint/private-dns-zone-group/main.bicep +++ b/modules/network/private-endpoint/private-dns-zone-group/main.bicep @@ -35,11 +35,11 @@ var privateDnsZoneConfigs = [for privateDNSResourceId in privateDNSResourceIds: } }] -resource privateEndpoint 'Microsoft.Network/privateEndpoints@2022-07-01' existing = { +resource privateEndpoint 'Microsoft.Network/privateEndpoints@2023-04-01' existing = { name: privateEndpointName } -resource privateDnsZoneGroup 'Microsoft.Network/privateEndpoints/privateDnsZoneGroups@2022-07-01' = { +resource privateDnsZoneGroup 'Microsoft.Network/privateEndpoints/privateDnsZoneGroups@2023-04-01' = { name: name parent: privateEndpoint properties: { diff --git a/modules/network/private-endpoint/private-dns-zone-group/main.json b/modules/network/private-endpoint/private-dns-zone-group/main.json index 9ec37c9710..93baa64a6d 100644 --- a/modules/network/private-endpoint/private-dns-zone-group/main.json +++ b/modules/network/private-endpoint/private-dns-zone-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -17,8 +20,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -69,7 +72,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" diff --git a/modules/network/private-link-service/.test/common/dependencies.bicep b/modules/network/private-link-service/.test/common/dependencies.bicep index a397647201..1b1935e899 100644 --- a/modules/network/private-link-service/.test/common/dependencies.bicep +++ b/modules/network/private-link-service/.test/common/dependencies.bicep @@ -12,50 +12,50 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-11-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - privateLinkServiceNetworkPolicies: 'Disabled' - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + privateLinkServiceNetworkPolicies: 'Disabled' + } + } + ] + } } -resource loadBalancer 'Microsoft.Network/loadBalancers@2022-11-01' = { - name: loadBalancerName - location: location - sku: { - name: 'Standard' - } - properties: { - frontendIPConfigurations: [ - { - name: 'frontendIPConfiguration' - properties: { - subnet: { - id: virtualNetwork.properties.subnets[0].id - } - } - } - ] - } +resource loadBalancer 'Microsoft.Network/loadBalancers@2023-04-01' = { + name: loadBalancerName + location: location + sku: { + name: 'Standard' + } + properties: { + frontendIPConfigurations: [ + { + name: 'frontendIPConfiguration' + properties: { + subnet: { + id: virtualNetwork.properties.subnets[0].id + } + } + } + ] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2023-01-31' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/network/private-link-service/.test/min/dependencies.bicep b/modules/network/private-link-service/.test/min/dependencies.bicep index b466cdd4e8..56367307a9 100644 --- a/modules/network/private-link-service/.test/min/dependencies.bicep +++ b/modules/network/private-link-service/.test/min/dependencies.bicep @@ -9,45 +9,45 @@ param loadBalancerName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-11-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - privateLinkServiceNetworkPolicies: 'Disabled' - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + privateLinkServiceNetworkPolicies: 'Disabled' + } + } + ] + } } -resource loadBalancer 'Microsoft.Network/loadBalancers@2022-11-01' = { - name: loadBalancerName - location: location - sku: { - name: 'Standard' - } - properties: { - frontendIPConfigurations: [ - { - name: 'frontendIPConfiguration' - properties: { - subnet: { - id: virtualNetwork.properties.subnets[0].id - } - } - } - ] - } +resource loadBalancer 'Microsoft.Network/loadBalancers@2023-04-01' = { + name: loadBalancerName + location: location + sku: { + name: 'Standard' + } + properties: { + frontendIPConfigurations: [ + { + name: 'frontendIPConfiguration' + properties: { + subnet: { + id: virtualNetwork.properties.subnets[0].id + } + } + } + ] + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/network/private-link-service/main.json b/modules/network/private-link-service/main.json index 8f810ba58d..5b5556160a 100644 --- a/modules/network/private-link-service/main.json +++ b/modules/network/private-link-service/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14906035198606347075" - } + "version": "0.20.4.51522", + "templateHash": "9204364662417527435" + }, + "name": "Private Link Services", + "description": "This module deploys a Private Link Service.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -25,14 +28,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "tags": { "type": "object", @@ -184,8 +187,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14466444549971089331" + "version": "0.20.4.51522", + "templateHash": "16284074528369884784" } }, "parameters": { diff --git a/modules/network/public-ip-address/.bicep/nested_roleAssignments.bicep b/modules/network/public-ip-address/.bicep/nested_roleAssignments.bicep index a078fac39b..9943b5bd9d 100644 --- a/modules/network/public-ip-address/.bicep/nested_roleAssignments.bicep +++ b/modules/network/public-ip-address/.bicep/nested_roleAssignments.bicep @@ -78,7 +78,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource publicIpAddress 'Microsoft.Network/publicIPAddresses@2022-07-01' existing = { +resource publicIpAddress 'Microsoft.Network/publicIPAddresses@2023-04-01' existing = { name: last(split(resourceId, '/'))! } diff --git a/modules/network/public-ip-address/.test/common/main.test.bicep b/modules/network/public-ip-address/.test/common/main.test.bicep index 90906c965b..b5fa77c643 100644 --- a/modules/network/public-ip-address/.test/common/main.test.bicep +++ b/modules/network/public-ip-address/.test/common/main.test.bicep @@ -63,7 +63,6 @@ module testDeployment '../../main.bicep' = { params: { enableDefaultTelemetry: enableDefaultTelemetry name: '${namePrefix}${serviceShort}001' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/network/public-ip-address/README.md b/modules/network/public-ip-address/README.md index 65a7b06232..abd33c1bba 100644 --- a/modules/network/public-ip-address/README.md +++ b/modules/network/public-ip-address/README.md @@ -17,7 +17,7 @@ This module deploys a Public IP Address. | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/publicIPAddresses` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/publicIPAddresses) | +| `Microsoft.Network/publicIPAddresses` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/publicIPAddresses) | ## Parameters @@ -34,12 +34,12 @@ This module deploys a Public IP Address. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, DDoSMitigationFlowLogs, DDoSMitigationReports, DDoSProtectionNotifications]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | | `diagnosticWorkspaceId` | string | `''` | | Resource ID of the diagnostic log analytics workspace. | | `domainNameLabel` | string | `''` | | The domain name label. The concatenation of the domain name label and the regionalized DNS zone make up the fully qualified domain name associated with the public IP address. If a domain name label is specified, an A DNS record is created for the public IP in the Microsoft Azure DNS system. | +| `domainNameLabelScope` | string | `''` | `['', NoReuse, ResourceGroupReuse, SubscriptionReuse, TenantReuse]` | The domain name label scope. If a domain name label and a domain name label scope are specified, an A DNS record is created for the public IP in the Microsoft Azure DNS system with a hashed value includes in FQDN. | | `enableDefaultTelemetry` | bool | `True` | | Enable telemetry via a Globally Unique Identifier (GUID). | | `fqdn` | string | `''` | | The Fully Qualified Domain Name of the A DNS record associated with the public IP. This is the concatenation of the domainNameLabel and the regionalized DNS zone. | | `location` | string | `[resourceGroup().location]` | | Location for all resources. | @@ -191,7 +191,6 @@ module publicIpAddress './network/public-ip-address/main.bicep' = { // Non-required parameters diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -243,9 +242,6 @@ module publicIpAddress './network/public-ip-address/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/network/public-ip-address/main.bicep b/modules/network/public-ip-address/main.bicep index e51920ad5b..77d07b8959 100644 --- a/modules/network/public-ip-address/main.bicep +++ b/modules/network/public-ip-address/main.bicep @@ -39,11 +39,6 @@ param zones array = [] ]) param publicIPAddressVersion string = 'IPv4' -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -59,6 +54,16 @@ param diagnosticEventHubName string = '' @description('Optional. The domain name label. The concatenation of the domain name label and the regionalized DNS zone make up the fully qualified domain name associated with the public IP address. If a domain name label is specified, an A DNS record is created for the public IP in the Microsoft Azure DNS system.') param domainNameLabel string = '' +@allowed([ + '' + 'NoReuse' + 'ResourceGroupReuse' + 'SubscriptionReuse' + 'TenantReuse' +]) +@description('Optional. The domain name label scope. If a domain name label and a domain name label scope are specified, an A DNS record is created for the public IP in the Microsoft Azure DNS system with a hashed value includes in FQDN.') +param domainNameLabelScope string = '' + @description('Optional. The Fully Qualified Domain Name of the A DNS record associated with the public IP. This is the concatenation of the domainNameLabel and the regionalized DNS zone.') param fqdn string = '' @@ -111,20 +116,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -132,10 +129,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (enableDefaultTelemetry) { @@ -150,7 +143,7 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource publicIpAddress 'Microsoft.Network/publicIPAddresses@2022-07-01' = { +resource publicIpAddress 'Microsoft.Network/publicIPAddresses@2023-04-01' = { name: name location: location tags: tags @@ -162,6 +155,7 @@ resource publicIpAddress 'Microsoft.Network/publicIPAddresses@2022-07-01' = { properties: { dnsSettings: !empty(domainNameLabel) ? { domainNameLabel: domainNameLabel + domainNameLabelScope: domainNameLabelScope fqdn: fqdn reverseFqdn: reverseFqdn } : null diff --git a/modules/network/public-ip-address/main.json b/modules/network/public-ip-address/main.json index 3b308daba8..2b027e8a9d 100644 --- a/modules/network/public-ip-address/main.json +++ b/modules/network/public-ip-address/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1954871673414826097" - } + "version": "0.20.4.51522", + "templateHash": "7444990895328873286" + }, + "name": "Public IP Addresses", + "description": "This module deploys a Public IP Address.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -73,15 +76,6 @@ "description": "Optional. IP address version." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -117,6 +111,20 @@ "description": "Optional. The domain name label. The concatenation of the domain name label and the regionalized DNS zone make up the fully qualified domain name associated with the public IP address. If a domain name label is specified, an A DNS record is created for the public IP in the Microsoft Azure DNS system." } }, + "domainNameLabelScope": { + "type": "string", + "defaultValue": "", + "allowedValues": [ + "", + "NoReuse", + "ResourceGroupReuse", + "SubscriptionReuse", + "TenantReuse" + ], + "metadata": { + "description": "Optional. The domain name label scope. If a domain name label and a domain name label scope are specified, an A DNS record is created for the public IP in the Microsoft Azure DNS system with a hashed value includes in FQDN." + } + }, "fqdn": { "type": "string", "defaultValue": "", @@ -134,14 +142,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "location": { "type": "string", @@ -214,11 +222,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -227,15 +231,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" }, "resources": [ { @@ -254,7 +254,7 @@ }, { "type": "Microsoft.Network/publicIPAddresses", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -264,7 +264,7 @@ }, "zones": "[parameters('zones')]", "properties": { - "dnsSettings": "[if(not(empty(parameters('domainNameLabel'))), createObject('domainNameLabel', parameters('domainNameLabel'), 'fqdn', parameters('fqdn'), 'reverseFqdn', parameters('reverseFqdn')), null())]", + "dnsSettings": "[if(not(empty(parameters('domainNameLabel'))), createObject('domainNameLabel', parameters('domainNameLabel'), 'domainNameLabelScope', parameters('domainNameLabelScope'), 'fqdn', parameters('fqdn'), 'reverseFqdn', parameters('reverseFqdn')), null())]", "publicIPAddressVersion": "[parameters('publicIPAddressVersion')]", "publicIPAllocationMethod": "[parameters('publicIPAllocationMethod')]", "publicIPPrefix": "[if(not(empty(parameters('publicIPPrefixResourceId'))), createObject('id', parameters('publicIPPrefixResourceId')), null())]", @@ -338,8 +338,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7927074872480917952" + "version": "0.20.4.51522", + "templateHash": "11249227806125160411" } }, "parameters": { @@ -509,14 +509,14 @@ "metadata": { "description": "The public IP address of the public IP address resource." }, - "value": "[if(contains(reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2022-07-01'), 'ipAddress'), reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2022-07-01').ipAddress, '')]" + "value": "[if(contains(reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2023-04-01'), 'ipAddress'), reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2023-04-01').ipAddress, '')]" }, "location": { "type": "string", "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/public-ip-prefix/.bicep/nested_roleAssignments.bicep b/modules/network/public-ip-prefix/.bicep/nested_roleAssignments.bicep index 25739f5cba..ac7f1d6f8f 100644 --- a/modules/network/public-ip-prefix/.bicep/nested_roleAssignments.bicep +++ b/modules/network/public-ip-prefix/.bicep/nested_roleAssignments.bicep @@ -78,7 +78,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource publicIpPrefix 'Microsoft.Network/publicIPPrefixes@2021-08-01' existing = { +resource publicIpPrefix 'Microsoft.Network/publicIPPrefixes@2023-04-01' existing = { name: last(split(resourceId, '/'))! } diff --git a/modules/network/public-ip-prefix/README.md b/modules/network/public-ip-prefix/README.md index 7f568db336..931296e9d4 100644 --- a/modules/network/public-ip-prefix/README.md +++ b/modules/network/public-ip-prefix/README.md @@ -16,7 +16,7 @@ This module deploys a Public IP Prefix. | :-- | :-- | | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | -| `Microsoft.Network/publicIPPrefixes` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/publicIPPrefixes) | +| `Microsoft.Network/publicIPPrefixes` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/publicIPPrefixes) | ## Parameters diff --git a/modules/network/public-ip-prefix/main.bicep b/modules/network/public-ip-prefix/main.bicep index bfa874572a..2781103a65 100644 --- a/modules/network/public-ip-prefix/main.bicep +++ b/modules/network/public-ip-prefix/main.bicep @@ -46,7 +46,7 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource publicIpPrefix 'Microsoft.Network/publicIPPrefixes@2022-07-01' = { +resource publicIpPrefix 'Microsoft.Network/publicIPPrefixes@2023-04-01' = { name: name location: location tags: tags diff --git a/modules/network/public-ip-prefix/main.json b/modules/network/public-ip-prefix/main.json index 58d85c7c8f..e92774a054 100644 --- a/modules/network/public-ip-prefix/main.json +++ b/modules/network/public-ip-prefix/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14918050419458548250" - } + "version": "0.20.4.51522", + "templateHash": "17525971950172483496" + }, + "name": "Public IP Prefixes", + "description": "This module deploys a Public IP Prefix.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -25,8 +28,8 @@ }, "prefixLength": { "type": "int", - "maxValue": 31, "minValue": 28, + "maxValue": 31, "metadata": { "description": "Required. Length of the Public IP Prefix." } @@ -34,14 +37,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -89,7 +92,7 @@ }, { "type": "Microsoft.Network/publicIPPrefixes", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -150,8 +153,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15498009263298237197" + "version": "0.20.4.51522", + "templateHash": "12022352001401552775" } }, "parameters": { @@ -321,7 +324,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/publicIPPrefixes', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/publicIPPrefixes', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/route-table/.bicep/nested_roleAssignments.bicep b/modules/network/route-table/.bicep/nested_roleAssignments.bicep index 98437ecf09..f801db3937 100644 --- a/modules/network/route-table/.bicep/nested_roleAssignments.bicep +++ b/modules/network/route-table/.bicep/nested_roleAssignments.bicep @@ -78,7 +78,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource routeTable 'Microsoft.Network/routeTables@2021-08-01' existing = { +resource routeTable 'Microsoft.Network/routeTables@2023-04-01' existing = { name: last(split(resourceId, '/'))! } diff --git a/modules/network/route-table/README.md b/modules/network/route-table/README.md index a76478d9a8..dd28168401 100644 --- a/modules/network/route-table/README.md +++ b/modules/network/route-table/README.md @@ -16,7 +16,7 @@ This module deploys a User Defined Route Table (UDR). | :-- | :-- | | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | -| `Microsoft.Network/routeTables` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/routeTables) | +| `Microsoft.Network/routeTables` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/routeTables) | ## Parameters diff --git a/modules/network/route-table/main.bicep b/modules/network/route-table/main.bicep index d19714cd8d..f32660a665 100644 --- a/modules/network/route-table/main.bicep +++ b/modules/network/route-table/main.bicep @@ -43,7 +43,7 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource routeTable 'Microsoft.Network/routeTables@2022-07-01' = { +resource routeTable 'Microsoft.Network/routeTables@2023-04-01' = { name: name location: location tags: tags diff --git a/modules/network/route-table/main.json b/modules/network/route-table/main.json index 2e60a82c11..076d0ca74b 100644 --- a/modules/network/route-table/main.json +++ b/modules/network/route-table/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6267793583428414969" - } + "version": "0.20.4.51522", + "templateHash": "178889211673212602" + }, + "name": "Route Tables", + "description": "This module deploys a User Defined Route Table (UDR).", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -39,14 +42,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -87,7 +90,7 @@ }, { "type": "Microsoft.Network/routeTables", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -144,8 +147,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16752813498867197745" + "version": "0.20.4.51522", + "templateHash": "15433672522856459960" } }, "parameters": { @@ -315,7 +318,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/routeTables', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/routeTables', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/service-endpoint-policy/.bicep/nested_roleAssignments.bicep b/modules/network/service-endpoint-policy/.bicep/nested_roleAssignments.bicep index de0258969e..6bd3061e96 100644 --- a/modules/network/service-endpoint-policy/.bicep/nested_roleAssignments.bicep +++ b/modules/network/service-endpoint-policy/.bicep/nested_roleAssignments.bicep @@ -78,7 +78,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource serviceEndpointPolicy 'Microsoft.Network/serviceEndpointPolicies@2022-07-01' existing = { +resource serviceEndpointPolicy 'Microsoft.Network/serviceEndpointPolicies@2023-04-01' existing = { name: last(split(resourceId, '/'))! } diff --git a/modules/network/service-endpoint-policy/README.md b/modules/network/service-endpoint-policy/README.md index b6728b963c..d70eea19a0 100644 --- a/modules/network/service-endpoint-policy/README.md +++ b/modules/network/service-endpoint-policy/README.md @@ -16,7 +16,7 @@ This module deploys a Service Endpoint Policy. | :-- | :-- | | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | -| `Microsoft.Network/serviceEndpointPolicies` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/serviceEndpointPolicies) | +| `Microsoft.Network/serviceEndpointPolicies` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/serviceEndpointPolicies) | ## Parameters diff --git a/modules/network/service-endpoint-policy/main.bicep b/modules/network/service-endpoint-policy/main.bicep index a2e2bcb313..357a2055e5 100644 --- a/modules/network/service-endpoint-policy/main.bicep +++ b/modules/network/service-endpoint-policy/main.bicep @@ -46,7 +46,7 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource serviceEndpointPolicy 'Microsoft.Network/serviceEndpointPolicies@2022-07-01' = { +resource serviceEndpointPolicy 'Microsoft.Network/serviceEndpointPolicies@2023-04-01' = { name: name location: location tags: tags diff --git a/modules/network/service-endpoint-policy/main.json b/modules/network/service-endpoint-policy/main.json index 3f87cbd310..7f9f5a02f2 100644 --- a/modules/network/service-endpoint-policy/main.json +++ b/modules/network/service-endpoint-policy/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8174648505463409401" - } + "version": "0.20.4.51522", + "templateHash": "3871903400441194755" + }, + "name": "Service Endpoint Policies", + "description": "This module deploys a Service Endpoint Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -46,14 +49,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -94,7 +97,7 @@ }, { "type": "Microsoft.Network/serviceEndpointPolicies", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -152,8 +155,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2676751245670262624" + "version": "0.20.4.51522", + "templateHash": "11744949434447908326" } }, "parameters": { @@ -323,7 +326,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/serviceEndpointPolicies', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/serviceEndpointPolicies', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/trafficmanagerprofile/.test/common/main.test.bicep b/modules/network/trafficmanagerprofile/.test/common/main.test.bicep index 207638d325..38180305f9 100644 --- a/modules/network/trafficmanagerprofile/.test/common/main.test.bicep +++ b/modules/network/trafficmanagerprofile/.test/common/main.test.bicep @@ -64,7 +64,6 @@ module testDeployment '../../main.bicep' = { enableDefaultTelemetry: enableDefaultTelemetry name: resourceName relativeName: resourceName - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/network/trafficmanagerprofile/README.md b/modules/network/trafficmanagerprofile/README.md index 61fe35d3df..5726c8c35f 100644 --- a/modules/network/trafficmanagerprofile/README.md +++ b/modules/network/trafficmanagerprofile/README.md @@ -35,7 +35,6 @@ This module deploys a Traffic Manager Profile. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, ProbeHealthStatusEvents]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -278,7 +277,6 @@ module trafficmanagerprofile './network/trafficmanagerprofile/main.bicep' = { // Non-required parameters diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -326,9 +324,6 @@ module trafficmanagerprofile './network/trafficmanagerprofile/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/network/trafficmanagerprofile/main.bicep b/modules/network/trafficmanagerprofile/main.bicep index 254f7ed1e6..bfb057fe76 100644 --- a/modules/network/trafficmanagerprofile/main.bicep +++ b/modules/network/trafficmanagerprofile/main.bicep @@ -50,11 +50,6 @@ param trafficViewEnrollmentStatus string = 'Disabled' @description('Optional. Maximum number of endpoints to be returned for MultiValue routing type.') param maxReturn int = 1 -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -108,20 +103,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -129,10 +116,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (enableDefaultTelemetry) { diff --git a/modules/network/trafficmanagerprofile/main.json b/modules/network/trafficmanagerprofile/main.json index 7676c5ef44..609a1c00e6 100644 --- a/modules/network/trafficmanagerprofile/main.json +++ b/modules/network/trafficmanagerprofile/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10717328847534611454" - } + "version": "0.20.4.51522", + "templateHash": "11826110444839615156" + }, + "name": "Traffic Manager Profiles", + "description": "This module deploys a Traffic Manager Profile.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -91,15 +94,6 @@ "description": "Optional. Maximum number of endpoints to be returned for MultiValue routing type." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -131,14 +125,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -202,11 +196,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -215,15 +205,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" }, "resources": [ { @@ -325,8 +311,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9779359192040618252" + "version": "0.20.4.51522", + "templateHash": "12919047416876893123" } }, "parameters": { diff --git a/modules/network/virtual-hub/.test/common/dependencies.bicep b/modules/network/virtual-hub/.test/common/dependencies.bicep index 1c86b0f68e..e8d9b0d404 100644 --- a/modules/network/virtual-hub/.test/common/dependencies.bicep +++ b/modules/network/virtual-hub/.test/common/dependencies.bicep @@ -9,12 +9,12 @@ param location string = resourceGroup().location var addressPrefix = '10.0.0.0/16' -resource virtualWan 'Microsoft.Network/virtualWans@2021-05-01' = { +resource virtualWan 'Microsoft.Network/virtualWans@2023-04-01' = { name: virtualWANName location: location } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkName location: location properties: { diff --git a/modules/network/virtual-hub/.test/min/dependencies.bicep b/modules/network/virtual-hub/.test/min/dependencies.bicep index 6b1819ebea..bb151ad9d8 100644 --- a/modules/network/virtual-hub/.test/min/dependencies.bicep +++ b/modules/network/virtual-hub/.test/min/dependencies.bicep @@ -4,7 +4,7 @@ param virtualWANName string @description('Optional. The location to deploy resources to.') param location string = resourceGroup().location -resource virtualWan 'Microsoft.Network/virtualWans@2021-05-01' = { +resource virtualWan 'Microsoft.Network/virtualWans@2023-04-01' = { name: virtualWANName location: location } diff --git a/modules/network/virtual-hub/hub-route-table/main.json b/modules/network/virtual-hub/hub-route-table/main.json index bd363ddd37..895c3a3a4f 100644 --- a/modules/network/virtual-hub/hub-route-table/main.json +++ b/modules/network/virtual-hub/hub-route-table/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13419259770629993067" - } + "version": "0.20.4.51522", + "templateHash": "14518513912380539716" + }, + "name": "Virtual Hub Route Tables", + "description": "This module deploys a Virtual Hub Route Table.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/network/virtual-hub/hub-virtual-network-connection/main.json b/modules/network/virtual-hub/hub-virtual-network-connection/main.json index c47ff73a0c..3fe3471be2 100644 --- a/modules/network/virtual-hub/hub-virtual-network-connection/main.json +++ b/modules/network/virtual-hub/hub-virtual-network-connection/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2118079772329732249" - } + "version": "0.20.4.51522", + "templateHash": "5767473063979797254" + }, + "name": "Virtual Hub Virtual Network Connections", + "description": "This module deploys a Virtual Hub Virtual Network Connection.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/network/virtual-hub/main.json b/modules/network/virtual-hub/main.json index 9a3d91ba34..1a73f8eb1c 100644 --- a/modules/network/virtual-hub/main.json +++ b/modules/network/virtual-hub/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14355316798617081412" - } + "version": "0.20.4.51522", + "templateHash": "8880725217295361508" + }, + "name": "Virtual Hubs", + "description": "This module deploys a Virtual Hub.\r\nIf you are planning to deploy a Secure Virtual Hub (with an Azure Firewall integrated), please refer to the Azure Firewall module.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -93,13 +96,13 @@ "sku": { "type": "string", "defaultValue": "Standard", - "metadata": { - "description": "Optional. The sku of this VirtualHub." - }, "allowedValues": [ "Basic", "Standard" - ] + ], + "metadata": { + "description": "Optional. The sku of this VirtualHub." + } }, "virtualHubRouteTableV2s": { "type": "array", @@ -152,14 +155,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "enableDefaultTelemetry": { "type": "bool", @@ -258,9 +261,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13419259770629993067" - } + "version": "0.20.4.51522", + "templateHash": "14518513912380539716" + }, + "name": "Virtual Hub Route Tables", + "description": "This module deploys a Virtual Hub Route Table.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -386,9 +392,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2118079772329732249" - } + "version": "0.20.4.51522", + "templateHash": "5767473063979797254" + }, + "name": "Virtual Hub Virtual Network Connections", + "description": "This module deploys a Virtual Hub Virtual Network Connection.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/network/virtual-network-gateway/.bicep/nested_roleAssignments.bicep b/modules/network/virtual-network-gateway/.bicep/nested_roleAssignments.bicep index f6a444107a..51ed7dd0ac 100644 --- a/modules/network/virtual-network-gateway/.bicep/nested_roleAssignments.bicep +++ b/modules/network/virtual-network-gateway/.bicep/nested_roleAssignments.bicep @@ -78,7 +78,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource virtualNetworkGateway 'Microsoft.Network/virtualNetworkGateways@2021-08-01' existing = { +resource virtualNetworkGateway 'Microsoft.Network/virtualNetworkGateways@2023-04-01' existing = { name: last(split(resourceId, '/'))! } diff --git a/modules/network/virtual-network-gateway/.test/aadvpn/dependencies.bicep b/modules/network/virtual-network-gateway/.test/aadvpn/dependencies.bicep index 49ffdf8cda..514b611718 100644 --- a/modules/network/virtual-network-gateway/.test/aadvpn/dependencies.bicep +++ b/modules/network/virtual-network-gateway/.test/aadvpn/dependencies.bicep @@ -9,29 +9,29 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'GatewaySubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'GatewaySubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network.') diff --git a/modules/network/virtual-network-gateway/.test/expressRoute/dependencies.bicep b/modules/network/virtual-network-gateway/.test/expressRoute/dependencies.bicep index 49ffdf8cda..514b611718 100644 --- a/modules/network/virtual-network-gateway/.test/expressRoute/dependencies.bicep +++ b/modules/network/virtual-network-gateway/.test/expressRoute/dependencies.bicep @@ -9,29 +9,29 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'GatewaySubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'GatewaySubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network.') diff --git a/modules/network/virtual-network-gateway/.test/expressRoute/main.test.bicep b/modules/network/virtual-network-gateway/.test/expressRoute/main.test.bicep index a3300192ee..9f100cf2ac 100644 --- a/modules/network/virtual-network-gateway/.test/expressRoute/main.test.bicep +++ b/modules/network/virtual-network-gateway/.test/expressRoute/main.test.bicep @@ -67,7 +67,6 @@ module testDeployment '../../main.bicep' = { skuName: 'ErGw1AZ' gatewayType: 'ExpressRoute' vNetResourceId: nestedDependencies.outputs.vnetResourceId - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/network/virtual-network-gateway/.test/vpn/dependencies.bicep b/modules/network/virtual-network-gateway/.test/vpn/dependencies.bicep index d1b8588e4b..f3028cc281 100644 --- a/modules/network/virtual-network-gateway/.test/vpn/dependencies.bicep +++ b/modules/network/virtual-network-gateway/.test/vpn/dependencies.bicep @@ -12,42 +12,42 @@ param localNetworkGatewayName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'GatewaySubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'GatewaySubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } -resource localNetworkGateway 'Microsoft.Network/localNetworkGateways@2022-07-01' = { - name: localNetworkGatewayName - location: location - properties: { - gatewayIpAddress: '100.100.100.100' - localNetworkAddressSpace: { - addressPrefixes: [ - '192.168.0.0/24' - ] - } +resource localNetworkGateway 'Microsoft.Network/localNetworkGateways@2023-04-01' = { + name: localNetworkGatewayName + location: location + properties: { + gatewayIpAddress: '100.100.100.100' + localNetworkAddressSpace: { + addressPrefixes: [ + '192.168.0.0/24' + ] } + } } @description('The resource ID of the created Virtual Network.') diff --git a/modules/network/virtual-network-gateway/.test/vpn/main.test.bicep b/modules/network/virtual-network-gateway/.test/vpn/main.test.bicep index 4a6bb7cb1b..fdc18c8d60 100644 --- a/modules/network/virtual-network-gateway/.test/vpn/main.test.bicep +++ b/modules/network/virtual-network-gateway/.test/vpn/main.test.bicep @@ -70,7 +70,6 @@ module testDeployment '../../main.bicep' = { gatewayType: 'Vpn' vNetResourceId: nestedDependencies.outputs.vnetResourceId activeActive: true - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/network/virtual-network-gateway/README.md b/modules/network/virtual-network-gateway/README.md index d612514139..1aebcbb3a5 100644 --- a/modules/network/virtual-network-gateway/README.md +++ b/modules/network/virtual-network-gateway/README.md @@ -17,9 +17,9 @@ This module deploys a Virtual Network Gateway. | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/publicIPAddresses` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/publicIPAddresses) | -| `Microsoft.Network/virtualNetworkGateways` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/virtualNetworkGateways) | -| `Microsoft.Network/virtualNetworkGateways/natRules` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/virtualNetworkGateways/natRules) | +| `Microsoft.Network/publicIPAddresses` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/publicIPAddresses) | +| `Microsoft.Network/virtualNetworkGateways` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/virtualNetworkGateways) | +| `Microsoft.Network/virtualNetworkGateways/natRules` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/virtualNetworkGateways/natRules) | ## Parameters @@ -45,7 +45,6 @@ This module deploys a Virtual Network Gateway. | `clientRootCertData` | string | `''` | | Client root certificate data used to authenticate VPN clients. Cannot be configured if vpnClientAadConfiguration is provided. | | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -440,7 +439,6 @@ module virtualNetworkGateway './network/virtual-network-gateway/main.bicep' = { // Non-required parameters diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' domainNameLabel: [ @@ -500,9 +498,6 @@ module virtualNetworkGateway './network/virtual-network-gateway/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, @@ -567,7 +562,6 @@ module virtualNetworkGateway './network/virtual-network-gateway/main.bicep' = { allowRemoteVnetTraffic: true diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' disableIPSecReplayProtection: true @@ -672,9 +666,6 @@ module virtualNetworkGateway './network/virtual-network-gateway/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/network/virtual-network-gateway/main.bicep b/modules/network/virtual-network-gateway/main.bicep index 79773ecd11..3603f8132e 100644 --- a/modules/network/virtual-network-gateway/main.bicep +++ b/modules/network/virtual-network-gateway/main.bicep @@ -112,11 +112,6 @@ param clientRootCertData string = '' @description('Optional. Thumbprint of the revoked certificate. This would revoke VPN client certificates matching this thumbprint from connecting to the VNet.') param clientRevokedCertThumbprint string = '' -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -197,20 +192,12 @@ param publicIpDiagnosticSettingsName string = '' var virtualNetworkGatewayDiagnosticsLogsSpecified = [for category in filter(virtualNetworkGatewaydiagnosticLogCategoriesToEnable, item => item != 'allLogs'): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var virtualNetworkGatewayDiagnosticsLogs = contains(virtualNetworkGatewaydiagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : virtualNetworkGatewayDiagnosticsLogsSpecified @@ -218,10 +205,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] // Other Variables @@ -373,7 +356,7 @@ module publicIPAddress '../public-ip-address/main.bicep' = [for (virtualGatewayP // VNET Gateway // ============ -resource virtualNetworkGateway 'Microsoft.Network/virtualNetworkGateways@2022-07-01' = { +resource virtualNetworkGateway 'Microsoft.Network/virtualNetworkGateways@2023-04-01' = { name: name location: location tags: tags diff --git a/modules/network/virtual-network-gateway/main.json b/modules/network/virtual-network-gateway/main.json index 65f9265dcd..36124a43cd 100644 --- a/modules/network/virtual-network-gateway/main.json +++ b/modules/network/virtual-network-gateway/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3661581255162235432" - } + "version": "0.20.4.51522", + "templateHash": "13367766135108394301" + }, + "name": "Virtual Network Gateways", + "description": "This module deploys a Virtual Network Gateway.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -219,15 +222,6 @@ "description": "Optional. Thumbprint of the revoked certificate. This would revoke VPN client certificates matching this thumbprint from connecting to the VNet." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -266,14 +260,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "tags": { "type": "object", @@ -364,11 +358,7 @@ "count": "[length(filter(parameters('virtualNetworkGatewaydiagnosticLogCategoriesToEnable'), lambda('item', not(equals(lambdaVariables('item'), 'allLogs')))))]", "input": { "category": "[filter(parameters('virtualNetworkGatewaydiagnosticLogCategoriesToEnable'), lambda('item', not(equals(lambdaVariables('item'), 'allLogs'))))[copyIndex('virtualNetworkGatewayDiagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -377,15 +367,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "virtualNetworkGatewayDiagnosticsLogs": "[if(contains(parameters('virtualNetworkGatewaydiagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), variables('virtualNetworkGatewayDiagnosticsLogsSpecified'))]", + "virtualNetworkGatewayDiagnosticsLogs": "[if(contains(parameters('virtualNetworkGatewaydiagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), variables('virtualNetworkGatewayDiagnosticsLogsSpecified'))]", "zoneRedundantSkus": [ "VpnGw1AZ", "VpnGw2AZ", @@ -426,7 +412,7 @@ }, { "type": "Microsoft.Network/virtualNetworkGateways", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -553,9 +539,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1954871673414826097" - } + "version": "0.20.4.51522", + "templateHash": "7444990895328873286" + }, + "name": "Public IP Addresses", + "description": "This module deploys a Public IP Address.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -622,15 +611,6 @@ "description": "Optional. IP address version." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -666,6 +646,20 @@ "description": "Optional. The domain name label. The concatenation of the domain name label and the regionalized DNS zone make up the fully qualified domain name associated with the public IP address. If a domain name label is specified, an A DNS record is created for the public IP in the Microsoft Azure DNS system." } }, + "domainNameLabelScope": { + "type": "string", + "defaultValue": "", + "allowedValues": [ + "", + "NoReuse", + "ResourceGroupReuse", + "SubscriptionReuse", + "TenantReuse" + ], + "metadata": { + "description": "Optional. The domain name label scope. If a domain name label and a domain name label scope are specified, an A DNS record is created for the public IP in the Microsoft Azure DNS system with a hashed value includes in FQDN." + } + }, "fqdn": { "type": "string", "defaultValue": "", @@ -683,14 +677,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "location": { "type": "string", @@ -763,11 +757,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -776,15 +766,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]" }, "resources": [ { @@ -803,7 +789,7 @@ }, { "type": "Microsoft.Network/publicIPAddresses", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -813,7 +799,7 @@ }, "zones": "[parameters('zones')]", "properties": { - "dnsSettings": "[if(not(empty(parameters('domainNameLabel'))), createObject('domainNameLabel', parameters('domainNameLabel'), 'fqdn', parameters('fqdn'), 'reverseFqdn', parameters('reverseFqdn')), null())]", + "dnsSettings": "[if(not(empty(parameters('domainNameLabel'))), createObject('domainNameLabel', parameters('domainNameLabel'), 'domainNameLabelScope', parameters('domainNameLabelScope'), 'fqdn', parameters('fqdn'), 'reverseFqdn', parameters('reverseFqdn')), null())]", "publicIPAddressVersion": "[parameters('publicIPAddressVersion')]", "publicIPAllocationMethod": "[parameters('publicIPAllocationMethod')]", "publicIPPrefix": "[if(not(empty(parameters('publicIPPrefixResourceId'))), createObject('id', parameters('publicIPPrefixResourceId')), null())]", @@ -887,8 +873,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7927074872480917952" + "version": "0.20.4.51522", + "templateHash": "11249227806125160411" } }, "parameters": { @@ -1058,14 +1044,14 @@ "metadata": { "description": "The public IP address of the public IP address resource." }, - "value": "[if(contains(reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2022-07-01'), 'ipAddress'), reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2022-07-01').ipAddress, '')]" + "value": "[if(contains(reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2023-04-01'), 'ipAddress'), reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2023-04-01').ipAddress, '')]" }, "location": { "type": "string", "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/publicIPAddresses', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -1106,9 +1092,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6604741649541233041" - } + "version": "0.20.4.51522", + "templateHash": "15664896159925545005" + }, + "name": "VPN Gateway NAT Rules", + "description": "This module deploys a Virtual Network Gateway NAT Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1193,7 +1182,7 @@ }, { "type": "Microsoft.Network/virtualNetworkGateways/natRules", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('virtualNetworkGatewayName'), parameters('name'))]", "properties": { "externalMappings": "[parameters('externalMappings')]", @@ -1267,8 +1256,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1445235181338876133" + "version": "0.20.4.51522", + "templateHash": "6647636585152280249" } }, "parameters": { @@ -1438,14 +1427,14 @@ "metadata": { "description": "Shows if the virtual network gateway is configured in active-active mode." }, - "value": "[reference(resourceId('Microsoft.Network/virtualNetworkGateways', parameters('name')), '2022-07-01').activeActive]" + "value": "[reference(resourceId('Microsoft.Network/virtualNetworkGateways', parameters('name')), '2023-04-01').activeActive]" }, "location": { "type": "string", "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/virtualNetworkGateways', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/virtualNetworkGateways', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/virtual-network-gateway/nat-rule/README.md b/modules/network/virtual-network-gateway/nat-rule/README.md index f4f6a00e2f..3cd7056388 100644 --- a/modules/network/virtual-network-gateway/nat-rule/README.md +++ b/modules/network/virtual-network-gateway/nat-rule/README.md @@ -13,7 +13,7 @@ This module deploys a Virtual Network Gateway NAT Rule. | Resource Type | API Version | | :-- | :-- | -| `Microsoft.Network/virtualNetworkGateways/natRules` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/virtualNetworkGateways/natRules) | +| `Microsoft.Network/virtualNetworkGateways/natRules` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/virtualNetworkGateways/natRules) | ## Parameters diff --git a/modules/network/virtual-network-gateway/nat-rule/main.bicep b/modules/network/virtual-network-gateway/nat-rule/main.bicep index 522859f0fe..5410c01508 100644 --- a/modules/network/virtual-network-gateway/nat-rule/main.bicep +++ b/modules/network/virtual-network-gateway/nat-rule/main.bicep @@ -48,11 +48,11 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource virtualNetworkGateway 'Microsoft.Network/virtualNetworkGateways@2022-07-01' existing = { +resource virtualNetworkGateway 'Microsoft.Network/virtualNetworkGateways@2023-04-01' existing = { name: virtualNetworkGatewayName } -resource natRule 'Microsoft.Network/virtualNetworkGateways/natRules@2022-07-01' = { +resource natRule 'Microsoft.Network/virtualNetworkGateways/natRules@2023-04-01' = { name: name parent: virtualNetworkGateway properties: { diff --git a/modules/network/virtual-network-gateway/nat-rule/main.json b/modules/network/virtual-network-gateway/nat-rule/main.json index 4bd424dfc4..d1e0ab62f4 100644 --- a/modules/network/virtual-network-gateway/nat-rule/main.json +++ b/modules/network/virtual-network-gateway/nat-rule/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6604741649541233041" - } + "version": "0.20.4.51522", + "templateHash": "15664896159925545005" + }, + "name": "VPN Gateway NAT Rules", + "description": "This module deploys a Virtual Network Gateway NAT Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -91,7 +94,7 @@ }, { "type": "Microsoft.Network/virtualNetworkGateways/natRules", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('virtualNetworkGatewayName'), parameters('name'))]", "properties": { "externalMappings": "[parameters('externalMappings')]", diff --git a/modules/network/virtual-network/.bicep/nested_roleAssignments.bicep b/modules/network/virtual-network/.bicep/nested_roleAssignments.bicep index c9f8304b8e..b6685d3853 100644 --- a/modules/network/virtual-network/.bicep/nested_roleAssignments.bicep +++ b/modules/network/virtual-network/.bicep/nested_roleAssignments.bicep @@ -78,7 +78,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2021-08-01' existing = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' existing = { name: last(split(resourceId, '/'))! } diff --git a/modules/network/virtual-network/.test/common/dependencies.bicep b/modules/network/virtual-network/.test/common/dependencies.bicep index a2fb172d43..065c08da1e 100644 --- a/modules/network/virtual-network/.test/common/dependencies.bicep +++ b/modules/network/virtual-network/.test/common/dependencies.bicep @@ -11,18 +11,18 @@ param routeTableName string param networkSecurityGroupName string resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } -resource routeTable 'Microsoft.Network/routeTables@2022-01-01' = { - name: routeTableName - location: location +resource routeTable 'Microsoft.Network/routeTables@2023-04-01' = { + name: routeTableName + location: location } -resource networkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2022-01-01' = { - name: networkSecurityGroupName - location: location +resource networkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2023-04-01' = { + name: networkSecurityGroupName + location: location } @description('The resource ID of the created Route Table.') diff --git a/modules/network/virtual-network/.test/common/main.test.bicep b/modules/network/virtual-network/.test/common/main.test.bicep index f2b76e6d32..33c4c94f4a 100644 --- a/modules/network/virtual-network/.test/common/main.test.bicep +++ b/modules/network/virtual-network/.test/common/main.test.bicep @@ -68,7 +68,6 @@ module testDeployment '../../main.bicep' = { addressPrefixes: [ '10.0.0.0/16' ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/network/virtual-network/.test/vnetPeering/dependencies.bicep b/modules/network/virtual-network/.test/vnetPeering/dependencies.bicep index 249436cb05..6cba4515d9 100644 --- a/modules/network/virtual-network/.test/vnetPeering/dependencies.bicep +++ b/modules/network/virtual-network/.test/vnetPeering/dependencies.bicep @@ -6,24 +6,24 @@ param virtualNetworkName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } @description('The resource ID of the created Virtual Network.') diff --git a/modules/network/virtual-network/README.md b/modules/network/virtual-network/README.md index bccfd1f292..4e7cc4be91 100644 --- a/modules/network/virtual-network/README.md +++ b/modules/network/virtual-network/README.md @@ -18,9 +18,9 @@ This module deploys a Virtual Network (vNet). | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/virtualNetworks` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/virtualNetworks) | -| `Microsoft.Network/virtualNetworks/subnets` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/virtualNetworks/subnets) | -| `Microsoft.Network/virtualNetworks/virtualNetworkPeerings` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/virtualNetworks/virtualNetworkPeerings) | +| `Microsoft.Network/virtualNetworks` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/virtualNetworks) | +| `Microsoft.Network/virtualNetworks/subnets` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/virtualNetworks/subnets) | +| `Microsoft.Network/virtualNetworks/virtualNetworkPeerings` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/virtualNetworks/virtualNetworkPeerings) | ## Parameters @@ -39,7 +39,6 @@ This module deploys a Virtual Network (vNet). | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, VMProtectionAlerts]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -382,7 +381,6 @@ module virtualNetwork './network/virtual-network/main.bicep' = { // Non-required parameters diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' dnsServers: [ @@ -484,9 +482,6 @@ module virtualNetwork './network/virtual-network/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/network/virtual-network/main.bicep b/modules/network/virtual-network/main.bicep index 90f857a94e..1b00114e5e 100644 --- a/modules/network/virtual-network/main.bicep +++ b/modules/network/virtual-network/main.bicep @@ -37,11 +37,6 @@ param vnetEncryptionEnforcement string = 'AllowUnencrypted' @description('Optional. The flow timeout in minutes for the Virtual Network, which is used to enable connection tracking for intra-VM flows. Possible values are between 4 and 30 minutes. Default value 0 will set the property to null.') param flowTimeoutInMinutes int = 0 -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -95,20 +90,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -116,10 +103,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var dnsServersVar = { @@ -144,7 +127,7 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-07-01' = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: name location: location tags: tags @@ -165,7 +148,7 @@ resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-07-01' = { properties: { addressPrefix: subnet.addressPrefix addressPrefixes: contains(subnet, 'addressPrefixes') ? subnet.addressPrefixes : [] - applicationGatewayIpConfigurations: contains(subnet, 'applicationGatewayIpConfigurations') ? subnet.applicationGatewayIpConfigurations : [] + applicationGatewayIPConfigurations: contains(subnet, 'applicationGatewayIPConfigurations') ? subnet.applicationGatewayIPConfigurations : [] delegations: contains(subnet, 'delegations') ? subnet.delegations : [] ipAllocations: contains(subnet, 'ipAllocations') ? subnet.ipAllocations : [] natGateway: contains(subnet, 'natGatewayId') ? { @@ -201,7 +184,7 @@ module virtualNetwork_subnets 'subnet/main.bicep' = [for (subnet, index) in subn name: subnet.name addressPrefix: subnet.addressPrefix addressPrefixes: contains(subnet, 'addressPrefixes') ? subnet.addressPrefixes : [] - applicationGatewayIpConfigurations: contains(subnet, 'applicationGatewayIpConfigurations') ? subnet.applicationGatewayIpConfigurations : [] + applicationGatewayIPConfigurations: contains(subnet, 'applicationGatewayIPConfigurations') ? subnet.applicationGatewayIPConfigurations : [] delegations: contains(subnet, 'delegations') ? subnet.delegations : [] ipAllocations: contains(subnet, 'ipAllocations') ? subnet.ipAllocations : [] natGatewayId: contains(subnet, 'natGatewayId') ? subnet.natGatewayId : '' diff --git a/modules/network/virtual-network/main.json b/modules/network/virtual-network/main.json index 757cd98099..0623aad896 100644 --- a/modules/network/virtual-network/main.json +++ b/modules/network/virtual-network/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8050151724516154993" - } + "version": "0.20.4.51522", + "templateHash": "4809931164972194036" + }, + "name": "Virtual Networks", + "description": "This module deploys a Virtual Network (vNet).", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -66,29 +69,20 @@ "vnetEncryptionEnforcement": { "type": "string", "defaultValue": "AllowUnencrypted", - "metadata": { - "description": "Optional. If the encrypted VNet allows VM that does not support encryption. Can only be used when vnetEncryption is enabled." - }, "allowedValues": [ "AllowUnencrypted", "DropUnencrypted" - ] + ], + "metadata": { + "description": "Optional. If the encrypted VNet allows VM that does not support encryption. Can only be used when vnetEncryption is enabled." + } }, "flowTimeoutInMinutes": { "type": "int", "defaultValue": 0, + "maxValue": 30, "metadata": { "description": "Optional. The flow timeout in minutes for the Virtual Network, which is used to enable connection tracking for intra-VM flows. Possible values are between 4 and 30 minutes. Default value 0 will set the property to null." - }, - "maxValue": 30 - }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." } }, "diagnosticStorageAccountId": { @@ -122,14 +116,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -193,11 +187,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -206,15 +196,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "dnsServersVar": { "dnsServers": "[array(parameters('dnsServers'))]" }, @@ -240,7 +226,7 @@ }, { "type": "Microsoft.Network/virtualNetworks", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -254,7 +240,7 @@ "properties": { "addressPrefix": "[parameters('subnets')[copyIndex('subnets')].addressPrefix]", "addressPrefixes": "[if(contains(parameters('subnets')[copyIndex('subnets')], 'addressPrefixes'), parameters('subnets')[copyIndex('subnets')].addressPrefixes, createArray())]", - "applicationGatewayIpConfigurations": "[if(contains(parameters('subnets')[copyIndex('subnets')], 'applicationGatewayIpConfigurations'), parameters('subnets')[copyIndex('subnets')].applicationGatewayIpConfigurations, createArray())]", + "applicationGatewayIPConfigurations": "[if(contains(parameters('subnets')[copyIndex('subnets')], 'applicationGatewayIPConfigurations'), parameters('subnets')[copyIndex('subnets')].applicationGatewayIPConfigurations, createArray())]", "delegations": "[if(contains(parameters('subnets')[copyIndex('subnets')], 'delegations'), parameters('subnets')[copyIndex('subnets')].delegations, createArray())]", "ipAllocations": "[if(contains(parameters('subnets')[copyIndex('subnets')], 'ipAllocations'), parameters('subnets')[copyIndex('subnets')].ipAllocations, createArray())]", "natGateway": "[if(contains(parameters('subnets')[copyIndex('subnets')], 'natGatewayId'), createObject('id', parameters('subnets')[copyIndex('subnets')].natGatewayId), null())]", @@ -334,7 +320,7 @@ "value": "[parameters('subnets')[copyIndex()].addressPrefix]" }, "addressPrefixes": "[if(contains(parameters('subnets')[copyIndex()], 'addressPrefixes'), createObject('value', parameters('subnets')[copyIndex()].addressPrefixes), createObject('value', createArray()))]", - "applicationGatewayIpConfigurations": "[if(contains(parameters('subnets')[copyIndex()], 'applicationGatewayIpConfigurations'), createObject('value', parameters('subnets')[copyIndex()].applicationGatewayIpConfigurations), createObject('value', createArray()))]", + "applicationGatewayIPConfigurations": "[if(contains(parameters('subnets')[copyIndex()], 'applicationGatewayIPConfigurations'), createObject('value', parameters('subnets')[copyIndex()].applicationGatewayIPConfigurations), createObject('value', createArray()))]", "delegations": "[if(contains(parameters('subnets')[copyIndex()], 'delegations'), createObject('value', parameters('subnets')[copyIndex()].delegations), createObject('value', createArray()))]", "ipAllocations": "[if(contains(parameters('subnets')[copyIndex()], 'ipAllocations'), createObject('value', parameters('subnets')[copyIndex()].ipAllocations), createObject('value', createArray()))]", "natGatewayId": "[if(contains(parameters('subnets')[copyIndex()], 'natGatewayId'), createObject('value', parameters('subnets')[copyIndex()].natGatewayId), createObject('value', ''))]", @@ -355,9 +341,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5239437568291997506" - } + "version": "0.20.4.51522", + "templateHash": "17563066367289258796" + }, + "name": "Virtual Network Subnets", + "description": "This module deploys a Virtual Network Subnet.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -444,7 +433,7 @@ "description": "Optional. List of address prefixes for the subnet." } }, - "applicationGatewayIpConfigurations": { + "applicationGatewayIPConfigurations": { "type": "array", "defaultValue": [], "metadata": { @@ -497,7 +486,7 @@ }, { "type": "Microsoft.Network/virtualNetworks/subnets", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('virtualNetworkName'), parameters('name'))]", "properties": { "addressPrefix": "[parameters('addressPrefix')]", @@ -509,7 +498,7 @@ "privateEndpointNetworkPolicies": "[if(not(empty(parameters('privateEndpointNetworkPolicies'))), parameters('privateEndpointNetworkPolicies'), null())]", "privateLinkServiceNetworkPolicies": "[if(not(empty(parameters('privateLinkServiceNetworkPolicies'))), parameters('privateLinkServiceNetworkPolicies'), null())]", "addressPrefixes": "[parameters('addressPrefixes')]", - "applicationGatewayIpConfigurations": "[parameters('applicationGatewayIpConfigurations')]", + "applicationGatewayIPConfigurations": "[parameters('applicationGatewayIPConfigurations')]", "ipAllocations": "[parameters('ipAllocations')]", "serviceEndpointPolicies": "[parameters('serviceEndpointPolicies')]" } @@ -548,8 +537,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16022559382364910663" + "version": "0.20.4.51522", + "templateHash": "11765890115463110578" } }, "parameters": { @@ -719,14 +708,14 @@ "metadata": { "description": "The address prefix for the subnet." }, - "value": "[reference(resourceId('Microsoft.Network/virtualNetworks/subnets', parameters('virtualNetworkName'), parameters('name')), '2022-07-01').addressPrefix]" + "value": "[reference(resourceId('Microsoft.Network/virtualNetworks/subnets', parameters('virtualNetworkName'), parameters('name')), '2023-04-01').addressPrefix]" }, "subnetAddressPrefixes": { "type": "array", "metadata": { "description": "List of address prefixes for the subnet." }, - "value": "[if(not(empty(parameters('addressPrefixes'))), reference(resourceId('Microsoft.Network/virtualNetworks/subnets', parameters('virtualNetworkName'), parameters('name')), '2022-07-01').addressPrefixes, createArray())]" + "value": "[if(not(empty(parameters('addressPrefixes'))), reference(resourceId('Microsoft.Network/virtualNetworks/subnets', parameters('virtualNetworkName'), parameters('name')), '2023-04-01').addressPrefixes, createArray())]" } } } @@ -771,9 +760,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2278855343435905865" - } + "version": "0.20.4.51522", + "templateHash": "6880392752659964193" + }, + "name": "Virtual Network Peerings", + "description": "This module deploys a Virtual Network Peering.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -855,7 +847,7 @@ }, { "type": "Microsoft.Network/virtualNetworks/virtualNetworkPeerings", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('localVnetName'), parameters('name'))]", "properties": { "allowForwardedTraffic": "[parameters('allowForwardedTraffic')]", @@ -937,9 +929,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2278855343435905865" - } + "version": "0.20.4.51522", + "templateHash": "6880392752659964193" + }, + "name": "Virtual Network Peerings", + "description": "This module deploys a Virtual Network Peering.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1021,7 +1016,7 @@ }, { "type": "Microsoft.Network/virtualNetworks/virtualNetworkPeerings", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('localVnetName'), parameters('name'))]", "properties": { "allowForwardedTraffic": "[parameters('allowForwardedTraffic')]", @@ -1098,8 +1093,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5870660949078211536" + "version": "0.20.4.51522", + "templateHash": "17359386532940218799" } }, "parameters": { @@ -1289,7 +1284,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/virtualNetworks', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/virtualNetworks', parameters('name')), '2023-04-01', 'full').location]" }, "diagnosticsLogs": { "type": "array", diff --git a/modules/network/virtual-network/subnet/.bicep/nested_roleAssignments.bicep b/modules/network/virtual-network/subnet/.bicep/nested_roleAssignments.bicep index 6ba5f56cad..5095a2d7c0 100644 --- a/modules/network/virtual-network/subnet/.bicep/nested_roleAssignments.bicep +++ b/modules/network/virtual-network/subnet/.bicep/nested_roleAssignments.bicep @@ -78,7 +78,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource subnet 'Microsoft.Network/virtualNetworks/subnets@2021-03-01' existing = { +resource subnet 'Microsoft.Network/virtualNetworks/subnets@2023-04-01' existing = { name: '${split(resourceId, '/')[8]}/${split(resourceId, '/')[10]}' } diff --git a/modules/network/virtual-network/subnet/README.md b/modules/network/virtual-network/subnet/README.md index 4e558cdc9d..4ce9842e69 100644 --- a/modules/network/virtual-network/subnet/README.md +++ b/modules/network/virtual-network/subnet/README.md @@ -15,7 +15,7 @@ This module deploys a Virtual Network Subnet. | Resource Type | API Version | | :-- | :-- | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | -| `Microsoft.Network/virtualNetworks/subnets` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/virtualNetworks/subnets) | +| `Microsoft.Network/virtualNetworks/subnets` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/virtualNetworks/subnets) | ## Parameters @@ -36,7 +36,7 @@ This module deploys a Virtual Network Subnet. | Parameter Name | Type | Default Value | Allowed Values | Description | | :-- | :-- | :-- | :-- | :-- | | `addressPrefixes` | array | `[]` | | List of address prefixes for the subnet. | -| `applicationGatewayIpConfigurations` | array | `[]` | | Application gateway IP configurations of virtual network resource. | +| `applicationGatewayIPConfigurations` | array | `[]` | | Application gateway IP configurations of virtual network resource. | | `delegations` | array | `[]` | | The delegations to enable on the subnet. | | `enableDefaultTelemetry` | bool | `True` | | Enable telemetry via a Globally Unique Identifier (GUID). | | `ipAllocations` | array | `[]` | | Array of IpAllocation which reference this subnet. | diff --git a/modules/network/virtual-network/subnet/main.bicep b/modules/network/virtual-network/subnet/main.bicep index 37bc70cfac..a114960005 100644 --- a/modules/network/virtual-network/subnet/main.bicep +++ b/modules/network/virtual-network/subnet/main.bicep @@ -46,7 +46,7 @@ param privateLinkServiceNetworkPolicies string = '' param addressPrefixes array = [] @description('Optional. Application gateway IP configurations of virtual network resource.') -param applicationGatewayIpConfigurations array = [] +param applicationGatewayIPConfigurations array = [] @description('Optional. Array of IpAllocation which reference this subnet.') param ipAllocations array = [] @@ -72,11 +72,11 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-07-01' existing = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' existing = { name: virtualNetworkName } -resource subnet 'Microsoft.Network/virtualNetworks/subnets@2022-07-01' = { +resource subnet 'Microsoft.Network/virtualNetworks/subnets@2023-04-01' = { name: name parent: virtualNetwork properties: { @@ -95,7 +95,7 @@ resource subnet 'Microsoft.Network/virtualNetworks/subnets@2022-07-01' = { privateEndpointNetworkPolicies: !empty(privateEndpointNetworkPolicies) ? any(privateEndpointNetworkPolicies) : null privateLinkServiceNetworkPolicies: !empty(privateLinkServiceNetworkPolicies) ? any(privateLinkServiceNetworkPolicies) : null addressPrefixes: addressPrefixes - applicationGatewayIpConfigurations: applicationGatewayIpConfigurations + applicationGatewayIPConfigurations: applicationGatewayIPConfigurations ipAllocations: ipAllocations serviceEndpointPolicies: serviceEndpointPolicies } diff --git a/modules/network/virtual-network/subnet/main.json b/modules/network/virtual-network/subnet/main.json index 7c57a8cc1e..aa1af62d0a 100644 --- a/modules/network/virtual-network/subnet/main.json +++ b/modules/network/virtual-network/subnet/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5239437568291997506" - } + "version": "0.20.4.51522", + "templateHash": "17563066367289258796" + }, + "name": "Virtual Network Subnets", + "description": "This module deploys a Virtual Network Subnet.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -93,7 +96,7 @@ "description": "Optional. List of address prefixes for the subnet." } }, - "applicationGatewayIpConfigurations": { + "applicationGatewayIPConfigurations": { "type": "array", "defaultValue": [], "metadata": { @@ -146,7 +149,7 @@ }, { "type": "Microsoft.Network/virtualNetworks/subnets", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('virtualNetworkName'), parameters('name'))]", "properties": { "addressPrefix": "[parameters('addressPrefix')]", @@ -158,7 +161,7 @@ "privateEndpointNetworkPolicies": "[if(not(empty(parameters('privateEndpointNetworkPolicies'))), parameters('privateEndpointNetworkPolicies'), null())]", "privateLinkServiceNetworkPolicies": "[if(not(empty(parameters('privateLinkServiceNetworkPolicies'))), parameters('privateLinkServiceNetworkPolicies'), null())]", "addressPrefixes": "[parameters('addressPrefixes')]", - "applicationGatewayIpConfigurations": "[parameters('applicationGatewayIpConfigurations')]", + "applicationGatewayIPConfigurations": "[parameters('applicationGatewayIPConfigurations')]", "ipAllocations": "[parameters('ipAllocations')]", "serviceEndpointPolicies": "[parameters('serviceEndpointPolicies')]" } @@ -197,8 +200,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16022559382364910663" + "version": "0.20.4.51522", + "templateHash": "11765890115463110578" } }, "parameters": { @@ -368,14 +371,14 @@ "metadata": { "description": "The address prefix for the subnet." }, - "value": "[reference(resourceId('Microsoft.Network/virtualNetworks/subnets', parameters('virtualNetworkName'), parameters('name')), '2022-07-01').addressPrefix]" + "value": "[reference(resourceId('Microsoft.Network/virtualNetworks/subnets', parameters('virtualNetworkName'), parameters('name')), '2023-04-01').addressPrefix]" }, "subnetAddressPrefixes": { "type": "array", "metadata": { "description": "List of address prefixes for the subnet." }, - "value": "[if(not(empty(parameters('addressPrefixes'))), reference(resourceId('Microsoft.Network/virtualNetworks/subnets', parameters('virtualNetworkName'), parameters('name')), '2022-07-01').addressPrefixes, createArray())]" + "value": "[if(not(empty(parameters('addressPrefixes'))), reference(resourceId('Microsoft.Network/virtualNetworks/subnets', parameters('virtualNetworkName'), parameters('name')), '2023-04-01').addressPrefixes, createArray())]" } } } \ No newline at end of file diff --git a/modules/network/virtual-network/virtual-network-peering/README.md b/modules/network/virtual-network/virtual-network-peering/README.md index a034f30c37..059f1d9ef1 100644 --- a/modules/network/virtual-network/virtual-network-peering/README.md +++ b/modules/network/virtual-network/virtual-network-peering/README.md @@ -13,7 +13,7 @@ This module deploys a Virtual Network Peering. | Resource Type | API Version | | :-- | :-- | -| `Microsoft.Network/virtualNetworks/virtualNetworkPeerings` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/virtualNetworks/virtualNetworkPeerings) | +| `Microsoft.Network/virtualNetworks/virtualNetworkPeerings` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/virtualNetworks/virtualNetworkPeerings) | ### Resource dependency diff --git a/modules/network/virtual-network/virtual-network-peering/main.bicep b/modules/network/virtual-network/virtual-network-peering/main.bicep index 9c2b8bdf17..861b4727d3 100644 --- a/modules/network/virtual-network/virtual-network-peering/main.bicep +++ b/modules/network/virtual-network/virtual-network-peering/main.bicep @@ -41,11 +41,11 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-07-01' existing = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' existing = { name: localVnetName } -resource virtualNetworkPeering 'Microsoft.Network/virtualNetworks/virtualNetworkPeerings@2022-07-01' = { +resource virtualNetworkPeering 'Microsoft.Network/virtualNetworks/virtualNetworkPeerings@2023-04-01' = { name: name parent: virtualNetwork properties: { diff --git a/modules/network/virtual-network/virtual-network-peering/main.json b/modules/network/virtual-network/virtual-network-peering/main.json index 6375477a95..50c7a9f2a1 100644 --- a/modules/network/virtual-network/virtual-network-peering/main.json +++ b/modules/network/virtual-network/virtual-network-peering/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2278855343435905865" - } + "version": "0.20.4.51522", + "templateHash": "6880392752659964193" + }, + "name": "Virtual Network Peerings", + "description": "This module deploys a Virtual Network Peering.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -88,7 +91,7 @@ }, { "type": "Microsoft.Network/virtualNetworks/virtualNetworkPeerings", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('localVnetName'), parameters('name'))]", "properties": { "allowForwardedTraffic": "[parameters('allowForwardedTraffic')]", diff --git a/modules/network/virtual-wan/.bicep/nested_roleAssignments.bicep b/modules/network/virtual-wan/.bicep/nested_roleAssignments.bicep index b93a816bba..7a505837c0 100644 --- a/modules/network/virtual-wan/.bicep/nested_roleAssignments.bicep +++ b/modules/network/virtual-wan/.bicep/nested_roleAssignments.bicep @@ -78,7 +78,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource virtualWan 'Microsoft.Network/virtualWans@2021-08-01' existing = { +resource virtualWan 'Microsoft.Network/virtualWans@2023-04-01' existing = { name: last(split(resourceId, '/'))! } diff --git a/modules/network/virtual-wan/README.md b/modules/network/virtual-wan/README.md index a12d773711..fb9f0f54a9 100644 --- a/modules/network/virtual-wan/README.md +++ b/modules/network/virtual-wan/README.md @@ -16,7 +16,7 @@ This module deploys a Virtual WAN. | :-- | :-- | | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | -| `Microsoft.Network/virtualWans` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/virtualWans) | +| `Microsoft.Network/virtualWans` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/virtualWans) | ## Parameters diff --git a/modules/network/virtual-wan/main.bicep b/modules/network/virtual-wan/main.bicep index 7d70576dc2..320389906b 100644 --- a/modules/network/virtual-wan/main.bicep +++ b/modules/network/virtual-wan/main.bicep @@ -53,7 +53,7 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource virtualWan 'Microsoft.Network/virtualWans@2022-07-01' = { +resource virtualWan 'Microsoft.Network/virtualWans@2023-04-01' = { name: name location: location tags: tags diff --git a/modules/network/virtual-wan/main.json b/modules/network/virtual-wan/main.json index 4985256d9f..4a1ac4640f 100644 --- a/modules/network/virtual-wan/main.json +++ b/modules/network/virtual-wan/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17876215770494516610" - } + "version": "0.20.4.51522", + "templateHash": "6041610175822689218" + }, + "name": "Virtual WANs", + "description": "This module deploys a Virtual WAN.", + "owner": "Azure/module-maintainers" }, "parameters": { "location": { @@ -78,14 +81,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } } }, "resources": [ @@ -105,7 +108,7 @@ }, { "type": "Microsoft.Network/virtualWans", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -164,8 +167,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14638659886066248315" + "version": "0.20.4.51522", + "templateHash": "8897739081481879538" } }, "parameters": { @@ -335,7 +338,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/virtualWans', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/virtualWans', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/vpn-gateway/.test/common/dependencies.bicep b/modules/network/vpn-gateway/.test/common/dependencies.bicep index cc25cd12d5..a15b268388 100644 --- a/modules/network/vpn-gateway/.test/common/dependencies.bicep +++ b/modules/network/vpn-gateway/.test/common/dependencies.bicep @@ -10,7 +10,7 @@ param vpnSiteName string @description('Required. The name of the virtual WAN to create.') param virtualWANName string -resource virtualWan 'Microsoft.Network/virtualWans@2021-05-01' = { +resource virtualWan 'Microsoft.Network/virtualWans@2023-04-01' = { name: virtualWANName location: location } @@ -26,7 +26,7 @@ resource virtualHub 'Microsoft.Network/virtualHubs@2022-01-01' = { } } -resource vpnSite 'Microsoft.Network/vpnSites@2022-01-01' = { +resource vpnSite 'Microsoft.Network/vpnSites@2023-04-01' = { name: vpnSiteName location: location properties: { diff --git a/modules/network/vpn-gateway/.test/min/dependencies.bicep b/modules/network/vpn-gateway/.test/min/dependencies.bicep index e8e34ac823..3b2439f31c 100644 --- a/modules/network/vpn-gateway/.test/min/dependencies.bicep +++ b/modules/network/vpn-gateway/.test/min/dependencies.bicep @@ -7,7 +7,7 @@ param virtualHubName string @description('Required. The name of the virtual WAN to create.') param virtualWANName string -resource virtualWan 'Microsoft.Network/virtualWans@2021-05-01' = { +resource virtualWan 'Microsoft.Network/virtualWans@2023-04-01' = { name: virtualWANName location: location } diff --git a/modules/network/vpn-gateway/README.md b/modules/network/vpn-gateway/README.md index 28809fbc81..faa6358fac 100644 --- a/modules/network/vpn-gateway/README.md +++ b/modules/network/vpn-gateway/README.md @@ -15,9 +15,9 @@ This module deploys a VPN Gateway. | Resource Type | API Version | | :-- | :-- | | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | -| `Microsoft.Network/vpnGateways` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/vpnGateways) | -| `Microsoft.Network/vpnGateways/natRules` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/vpnGateways/natRules) | -| `Microsoft.Network/vpnGateways/vpnConnections` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/vpnGateways/vpnConnections) | +| `Microsoft.Network/vpnGateways` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/vpnGateways) | +| `Microsoft.Network/vpnGateways/natRules` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/vpnGateways/natRules) | +| `Microsoft.Network/vpnGateways/vpnConnections` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/vpnGateways/vpnConnections) | ## Parameters diff --git a/modules/network/vpn-gateway/main.bicep b/modules/network/vpn-gateway/main.bicep index 54288b6e18..58acd01951 100644 --- a/modules/network/vpn-gateway/main.bicep +++ b/modules/network/vpn-gateway/main.bicep @@ -57,7 +57,7 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource vpnGateway 'Microsoft.Network/vpnGateways@2022-07-01' = { +resource vpnGateway 'Microsoft.Network/vpnGateways@2023-04-01' = { name: name location: location tags: tags @@ -112,6 +112,9 @@ module vpnGateway_vpnConnections 'vpn-connection/main.bicep' = [for (connection, usePolicyBasedTrafficSelectors: contains(connection, 'usePolicyBasedTrafficSelectors') ? connection.usePolicyBasedTrafficSelectors : false vpnConnectionProtocolType: contains(connection, 'vpnConnectionProtocolType') ? connection.vpnConnectionProtocolType : 'IKEv2' enableDefaultTelemetry: enableReferencedModulesTelemetry + ipsecPolicies: contains(connection, 'ipsecPolicies') ? connection.ipsecPolicies : [] + trafficSelectorPolicies: contains(connection, 'trafficSelectorPolicies') ? connection.trafficSelectorPolicies : [] + vpnLinkConnections: contains(connection, 'vpnLinkConnections') ? connection.vpnLinkConnections : [] } }] diff --git a/modules/network/vpn-gateway/main.json b/modules/network/vpn-gateway/main.json index 15afe4a6df..c33ca37474 100644 --- a/modules/network/vpn-gateway/main.json +++ b/modules/network/vpn-gateway/main.json @@ -5,7 +5,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "10067626025010436242" + "templateHash": "965959360882540315" }, "name": "VPN Gateways", "description": "This module deploys a VPN Gateway.", @@ -120,7 +120,7 @@ }, { "type": "Microsoft.Network/vpnGateways", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -184,7 +184,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "8392038973787732390" + "templateHash": "6991949008498259337" }, "name": "VPN Gateway NAT Rules", "description": "This module deploys a VPN Gateway NAT Rule.", @@ -273,7 +273,7 @@ }, { "type": "Microsoft.Network/vpnGateways/natRules", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('vpnGatewayName'), parameters('name'))]", "properties": { "externalMappings": "[parameters('externalMappings')]", @@ -346,7 +346,10 @@ "vpnConnectionProtocolType": "[if(contains(parameters('vpnConnections')[copyIndex()], 'vpnConnectionProtocolType'), createObject('value', parameters('vpnConnections')[copyIndex()].vpnConnectionProtocolType), createObject('value', 'IKEv2'))]", "enableDefaultTelemetry": { "value": "[variables('enableReferencedModulesTelemetry')]" - } + }, + "ipsecPolicies": "[if(contains(parameters('vpnConnections')[copyIndex()], 'ipsecPolicies'), createObject('value', parameters('vpnConnections')[copyIndex()].ipsecPolicies), createObject('value', createArray()))]", + "trafficSelectorPolicies": "[if(contains(parameters('vpnConnections')[copyIndex()], 'trafficSelectorPolicies'), createObject('value', parameters('vpnConnections')[copyIndex()].trafficSelectorPolicies), createObject('value', createArray()))]", + "vpnLinkConnections": "[if(contains(parameters('vpnConnections')[copyIndex()], 'vpnLinkConnections'), createObject('value', parameters('vpnConnections')[copyIndex()].vpnLinkConnections), createObject('value', createArray()))]" }, "template": { "$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#", @@ -355,7 +358,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "17179690973269419309" + "templateHash": "16568762636851429677" }, "name": "VPN Gateway VPN Connections", "description": "This module deploys a VPN Gateway VPN Connection.", @@ -501,7 +504,7 @@ }, { "type": "Microsoft.Network/vpnGateways/vpnConnections", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('vpnGatewayName'), parameters('name'))]", "properties": { "connectionBandwidth": "[parameters('connectionBandwidth')]", @@ -578,7 +581,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/vpnGateways', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/vpnGateways', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/network/vpn-gateway/nat-rule/README.md b/modules/network/vpn-gateway/nat-rule/README.md index 4da90d954c..6155ca0fc1 100644 --- a/modules/network/vpn-gateway/nat-rule/README.md +++ b/modules/network/vpn-gateway/nat-rule/README.md @@ -13,7 +13,7 @@ This module deploys a VPN Gateway NAT Rule. | Resource Type | API Version | | :-- | :-- | -| `Microsoft.Network/vpnGateways/natRules` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/vpnGateways/natRules) | +| `Microsoft.Network/vpnGateways/natRules` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/vpnGateways/natRules) | ## Parameters diff --git a/modules/network/vpn-gateway/nat-rule/main.bicep b/modules/network/vpn-gateway/nat-rule/main.bicep index 24b5016757..8ab92f9e52 100644 --- a/modules/network/vpn-gateway/nat-rule/main.bicep +++ b/modules/network/vpn-gateway/nat-rule/main.bicep @@ -48,11 +48,11 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource vpnGateway 'Microsoft.Network/vpnGateways@2022-07-01' existing = { +resource vpnGateway 'Microsoft.Network/vpnGateways@2023-04-01' existing = { name: vpnGatewayName } -resource natRule 'Microsoft.Network/vpnGateways/natRules@2022-07-01' = { +resource natRule 'Microsoft.Network/vpnGateways/natRules@2023-04-01' = { name: name parent: vpnGateway properties: { diff --git a/modules/network/vpn-gateway/nat-rule/main.json b/modules/network/vpn-gateway/nat-rule/main.json index 9c7c175294..2bf42881b7 100644 --- a/modules/network/vpn-gateway/nat-rule/main.json +++ b/modules/network/vpn-gateway/nat-rule/main.json @@ -5,7 +5,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "8392038973787732390" + "templateHash": "6991949008498259337" }, "name": "VPN Gateway NAT Rules", "description": "This module deploys a VPN Gateway NAT Rule.", @@ -94,7 +94,7 @@ }, { "type": "Microsoft.Network/vpnGateways/natRules", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('vpnGatewayName'), parameters('name'))]", "properties": { "externalMappings": "[parameters('externalMappings')]", diff --git a/modules/network/vpn-gateway/vpn-connection/README.md b/modules/network/vpn-gateway/vpn-connection/README.md index b3f8ad040b..0774cc5ca5 100644 --- a/modules/network/vpn-gateway/vpn-connection/README.md +++ b/modules/network/vpn-gateway/vpn-connection/README.md @@ -13,7 +13,7 @@ This module deploys a VPN Gateway VPN Connection. | Resource Type | API Version | | :-- | :-- | -| `Microsoft.Network/vpnGateways/vpnConnections` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/vpnGateways/vpnConnections) | +| `Microsoft.Network/vpnGateways/vpnConnections` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/vpnGateways/vpnConnections) | ## Parameters diff --git a/modules/network/vpn-gateway/vpn-connection/main.bicep b/modules/network/vpn-gateway/vpn-connection/main.bicep index 2f2f68353d..f978ecc3ae 100644 --- a/modules/network/vpn-gateway/vpn-connection/main.bicep +++ b/modules/network/vpn-gateway/vpn-connection/main.bicep @@ -69,11 +69,11 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource vpnGateway 'Microsoft.Network/vpnGateways@2022-07-01' existing = { +resource vpnGateway 'Microsoft.Network/vpnGateways@2023-04-01' existing = { name: vpnGatewayName } -resource vpnConnection 'Microsoft.Network/vpnGateways/vpnConnections@2022-07-01' = { +resource vpnConnection 'Microsoft.Network/vpnGateways/vpnConnections@2023-04-01' = { name: name parent: vpnGateway properties: { diff --git a/modules/network/vpn-gateway/vpn-connection/main.json b/modules/network/vpn-gateway/vpn-connection/main.json index 8778d671db..f92946fb9a 100644 --- a/modules/network/vpn-gateway/vpn-connection/main.json +++ b/modules/network/vpn-gateway/vpn-connection/main.json @@ -5,7 +5,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "17179690973269419309" + "templateHash": "16568762636851429677" }, "name": "VPN Gateway VPN Connections", "description": "This module deploys a VPN Gateway VPN Connection.", @@ -151,7 +151,7 @@ }, { "type": "Microsoft.Network/vpnGateways/vpnConnections", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('vpnGatewayName'), parameters('name'))]", "properties": { "connectionBandwidth": "[parameters('connectionBandwidth')]", diff --git a/modules/network/vpn-site/.bicep/nested_roleAssignments.bicep b/modules/network/vpn-site/.bicep/nested_roleAssignments.bicep index 8095acfbf4..2ba49c6f30 100644 --- a/modules/network/vpn-site/.bicep/nested_roleAssignments.bicep +++ b/modules/network/vpn-site/.bicep/nested_roleAssignments.bicep @@ -48,7 +48,7 @@ var builtInRoleNames = { 'Windows Admin Center Administrator Login': subscriptionResourceId('Microsoft.Authorization/roleDefinitions', 'a6333a3e-0164-44c3-b281-7a577aff287f') } -resource vpnSite 'Microsoft.Network/vpnSites@2022-07-01' existing = { +resource vpnSite 'Microsoft.Network/vpnSites@2023-04-01' existing = { name: last(split(resourceId, '/'))! } diff --git a/modules/network/vpn-site/.test/common/dependencies.bicep b/modules/network/vpn-site/.test/common/dependencies.bicep index 958f2e3650..8e2694c27f 100644 --- a/modules/network/vpn-site/.test/common/dependencies.bicep +++ b/modules/network/vpn-site/.test/common/dependencies.bicep @@ -12,7 +12,7 @@ resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018- location: location } -resource virtualWan 'Microsoft.Network/virtualWans@2021-05-01' = { +resource virtualWan 'Microsoft.Network/virtualWans@2023-04-01' = { name: virtualWANName location: location } diff --git a/modules/network/vpn-site/.test/min/dependencies.bicep b/modules/network/vpn-site/.test/min/dependencies.bicep index 6b1819ebea..bb151ad9d8 100644 --- a/modules/network/vpn-site/.test/min/dependencies.bicep +++ b/modules/network/vpn-site/.test/min/dependencies.bicep @@ -4,7 +4,7 @@ param virtualWANName string @description('Optional. The location to deploy resources to.') param location string = resourceGroup().location -resource virtualWan 'Microsoft.Network/virtualWans@2021-05-01' = { +resource virtualWan 'Microsoft.Network/virtualWans@2023-04-01' = { name: virtualWANName location: location } diff --git a/modules/network/vpn-site/README.md b/modules/network/vpn-site/README.md index 0365e2b321..7ee7fcbca5 100644 --- a/modules/network/vpn-site/README.md +++ b/modules/network/vpn-site/README.md @@ -16,7 +16,7 @@ This module deploys a VPN Site. | :-- | :-- | | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | -| `Microsoft.Network/vpnSites` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/vpnSites) | +| `Microsoft.Network/vpnSites` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/vpnSites) | ## Parameters diff --git a/modules/network/vpn-site/main.bicep b/modules/network/vpn-site/main.bicep index 689adb1be3..3d50b1d9d2 100644 --- a/modules/network/vpn-site/main.bicep +++ b/modules/network/vpn-site/main.bicep @@ -61,7 +61,7 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource vpnSite 'Microsoft.Network/vpnSites@2022-07-01' = { +resource vpnSite 'Microsoft.Network/vpnSites@2023-04-01' = { name: name location: location tags: tags diff --git a/modules/network/vpn-site/main.json b/modules/network/vpn-site/main.json index 9ddbe3288e..e47ad47b0d 100644 --- a/modules/network/vpn-site/main.json +++ b/modules/network/vpn-site/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "262103692668335899" - } + "version": "0.20.4.51522", + "templateHash": "17973868678788667576" + }, + "name": "VPN Sites", + "description": "This module deploys a VPN Site.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -94,14 +97,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -128,7 +131,7 @@ }, { "type": "Microsoft.Network/vpnSites", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -189,8 +192,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16444676877993222718" + "version": "0.20.4.51522", + "templateHash": "3653745242903782760" } }, "parameters": { @@ -305,7 +308,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/vpnSites', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/vpnSites', parameters('name')), '2023-04-01', 'full').location]" } } } \ No newline at end of file diff --git a/modules/operational-insights/workspace/.test/adv/main.test.bicep b/modules/operational-insights/workspace/.test/adv/main.test.bicep index 8810b63f0b..cd02694a03 100644 --- a/modules/operational-insights/workspace/.test/adv/main.test.bicep +++ b/modules/operational-insights/workspace/.test/adv/main.test.bicep @@ -158,7 +158,6 @@ module testDeployment '../../main.bicep' = { state: 'Enabled' } ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/operational-insights/workspace/.test/common/main.test.bicep b/modules/operational-insights/workspace/.test/common/main.test.bicep index 463912df68..080238e35c 100644 --- a/modules/operational-insights/workspace/.test/common/main.test.bicep +++ b/modules/operational-insights/workspace/.test/common/main.test.bicep @@ -156,7 +156,6 @@ module testDeployment '../../main.bicep' = { state: 'Enabled' } ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/operational-insights/workspace/README.md b/modules/operational-insights/workspace/README.md index dfc11de711..3c9127b79a 100644 --- a/modules/operational-insights/workspace/README.md +++ b/modules/operational-insights/workspace/README.md @@ -52,7 +52,6 @@ This module deploys a Log Analytics Workspace. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, Audit]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -637,7 +636,6 @@ module workspace './operational-insights/workspace/main.bicep' = { ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -892,9 +890,6 @@ module workspace './operational-insights/workspace/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, @@ -1142,7 +1137,6 @@ module workspace './operational-insights/workspace/main.bicep' = { ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -1324,9 +1318,6 @@ module workspace './operational-insights/workspace/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/operational-insights/workspace/data-export/main.json b/modules/operational-insights/workspace/data-export/main.json index eb953546ca..90194a5d43 100644 --- a/modules/operational-insights/workspace/data-export/main.json +++ b/modules/operational-insights/workspace/data-export/main.json @@ -4,15 +4,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1404193826490863720" - } + "version": "0.20.4.51522", + "templateHash": "6853475409424559635" + }, + "name": "Log Analytics Workspace Data Exports", + "description": "This module deploys a Log Analytics Workspace Data Export.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { "type": "string", - "maxLength": 63, "minLength": 4, + "maxLength": 63, "metadata": { "description": "Required. The data export rule name." } diff --git a/modules/operational-insights/workspace/data-source/main.json b/modules/operational-insights/workspace/data-source/main.json index af54cfd802..12e72aea0f 100644 --- a/modules/operational-insights/workspace/data-source/main.json +++ b/modules/operational-insights/workspace/data-source/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14800885279121710904" - } + "version": "0.20.4.51522", + "templateHash": "526173230944614742" + }, + "name": "Log Analytics Workspace Datasources", + "description": "This module deploys a Log Analytics Workspace Data Source.", + "owner": "Azure/module-maintainers" }, "parameters": { "logAnalyticsWorkspaceName": { diff --git a/modules/operational-insights/workspace/linked-service/main.json b/modules/operational-insights/workspace/linked-service/main.json index 75ece27c66..c66c428091 100644 --- a/modules/operational-insights/workspace/linked-service/main.json +++ b/modules/operational-insights/workspace/linked-service/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9104010996147858950" - } + "version": "0.20.4.51522", + "templateHash": "6123492600831728521" + }, + "name": "Log Analytics Workspace Linked Services", + "description": "This module deploys a Log Analytics Workspace Linked Service.", + "owner": "Azure/module-maintainers" }, "parameters": { "logAnalyticsWorkspaceName": { diff --git a/modules/operational-insights/workspace/linked-storage-account/main.json b/modules/operational-insights/workspace/linked-storage-account/main.json index b87c400772..ae62d06121 100644 --- a/modules/operational-insights/workspace/linked-storage-account/main.json +++ b/modules/operational-insights/workspace/linked-storage-account/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4207477883724473600" - } + "version": "0.20.4.51522", + "templateHash": "17235548432615830542" + }, + "name": "Log Analytics Workspace Linked Storage Accounts", + "description": "This module deploys a Log Analytics Workspace Linked Storage Account.", + "owner": "Azure/module-maintainers" }, "parameters": { "logAnalyticsWorkspaceName": { diff --git a/modules/operational-insights/workspace/main.bicep b/modules/operational-insights/workspace/main.bicep index 43c7763bc4..77f01cff47 100644 --- a/modules/operational-insights/workspace/main.bicep +++ b/modules/operational-insights/workspace/main.bicep @@ -82,11 +82,6 @@ param userAssignedIdentities object = {} @description('Optional. Set to \'true\' to use resource or workspace permissions and \'false\' (or leave empty) to require workspace permissions.') param useResourcePermissions bool = false -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -143,20 +138,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -164,10 +151,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var logAnalyticsSearchVersion = 1 diff --git a/modules/operational-insights/workspace/main.json b/modules/operational-insights/workspace/main.json index cb616f892c..fee2989894 100644 --- a/modules/operational-insights/workspace/main.json +++ b/modules/operational-insights/workspace/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9382617018780365951" - } + "version": "0.20.4.51522", + "templateHash": "15935041829541448463" + }, + "name": "Log Analytics Workspaces", + "description": "This module deploys a Log Analytics Workspace.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -42,11 +45,11 @@ "skuCapacityReservationLevel": { "type": "int", "defaultValue": 100, + "minValue": 100, + "maxValue": 5000, "metadata": { "description": "Optional. The capacity reservation level in GB for this workspace, when CapacityReservation sku is selected. Must be in increments of 100 between 100 and 5000." - }, - "maxValue": 5000, - "minValue": 100 + } }, "storageInsightsConfigs": { "type": "array", @@ -107,8 +110,8 @@ "dataRetention": { "type": "int", "defaultValue": 365, - "maxValue": 730, "minValue": 0, + "maxValue": 730, "metadata": { "description": "Optional. Number of days data will be retained for." } @@ -164,15 +167,6 @@ "description": "Optional. Set to 'true' to use resource or workspace permissions and 'false' (or leave empty) to require workspace permissions." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -211,14 +205,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -282,11 +276,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -295,15 +285,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "logAnalyticsSearchVersion": 1, "enableReferencedModulesTelemetry": false, "identityType": "[if(parameters('systemAssignedIdentity'), 'SystemAssigned', if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None'))]", @@ -413,9 +399,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5892497567322793672" - } + "version": "0.20.4.51522", + "templateHash": "5679144933666454393" + }, + "name": "Log Analytics Workspace Storage Insight Configs", + "description": "This module deploys a Log Analytics Workspace Storage Insight Config.", + "owner": "Azure/module-maintainers" }, "parameters": { "logAnalyticsWorkspaceName": { @@ -557,9 +546,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9104010996147858950" - } + "version": "0.20.4.51522", + "templateHash": "6123492600831728521" + }, + "name": "Log Analytics Workspace Linked Services", + "description": "This module deploys a Log Analytics Workspace Linked Service.", + "owner": "Azure/module-maintainers" }, "parameters": { "logAnalyticsWorkspaceName": { @@ -691,9 +683,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4207477883724473600" - } + "version": "0.20.4.51522", + "templateHash": "17235548432615830542" + }, + "name": "Log Analytics Workspace Linked Storage Accounts", + "description": "This module deploys a Log Analytics Workspace Linked Storage Account.", + "owner": "Azure/module-maintainers" }, "parameters": { "logAnalyticsWorkspaceName": { @@ -826,9 +821,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18377173330328914128" - } + "version": "0.20.4.51522", + "templateHash": "10184551811647520122" + }, + "name": "Log Analytics Workspace Saved Searches", + "description": "This module deploys a Log Analytics Workspace Saved Search.", + "owner": "Azure/module-maintainers" }, "parameters": { "logAnalyticsWorkspaceName": { @@ -998,15 +996,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1404193826490863720" - } + "version": "0.20.4.51522", + "templateHash": "6853475409424559635" + }, + "name": "Log Analytics Workspace Data Exports", + "description": "This module deploys a Log Analytics Workspace Data Export.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { "type": "string", - "maxLength": 63, "minLength": 4, + "maxLength": 63, "metadata": { "description": "Required. The data export rule name." } @@ -1145,9 +1146,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14800885279121710904" - } + "version": "0.20.4.51522", + "templateHash": "526173230944614742" + }, + "name": "Log Analytics Workspace Datasources", + "description": "This module deploys a Log Analytics Workspace Data Source.", + "owner": "Azure/module-maintainers" }, "parameters": { "logAnalyticsWorkspaceName": { @@ -1372,9 +1376,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "174331240044920355" - } + "version": "0.20.4.51522", + "templateHash": "761158132904084297" + }, + "name": "Log Analytics Workspace Tables", + "description": "This module deploys a Log Analytics Workspace Table.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1417,8 +1424,8 @@ "retentionInDays": { "type": "int", "defaultValue": -1, - "maxValue": 730, "minValue": -1, + "maxValue": 730, "metadata": { "description": "Optional. The table retention in days, between 4 and 730. Setting this property to -1 will default to the workspace retention." } @@ -1440,8 +1447,8 @@ "totalRetentionInDays": { "type": "int", "defaultValue": -1, - "maxValue": 2555, "minValue": -1, + "maxValue": 2555, "metadata": { "description": "Optional. The table total retention in days, between 4 and 2555. Setting this property to -1 will default to table retention." } @@ -1541,9 +1548,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6203827990364745107" - } + "version": "0.20.4.51522", + "templateHash": "16708625392312836324" + }, + "name": "Operations Management Solutions", + "description": "This module deploys an Operations Management Solution.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1692,8 +1702,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7475502990358761120" + "version": "0.20.4.51522", + "templateHash": "9516912265776834381" } }, "parameters": { diff --git a/modules/operational-insights/workspace/saved-searche/main.json b/modules/operational-insights/workspace/saved-searche/main.json index e4c106f6e7..02992ba89d 100644 --- a/modules/operational-insights/workspace/saved-searche/main.json +++ b/modules/operational-insights/workspace/saved-searche/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18377173330328914128" - } + "version": "0.20.4.51522", + "templateHash": "10184551811647520122" + }, + "name": "Log Analytics Workspace Saved Searches", + "description": "This module deploys a Log Analytics Workspace Saved Search.", + "owner": "Azure/module-maintainers" }, "parameters": { "logAnalyticsWorkspaceName": { diff --git a/modules/operational-insights/workspace/storage-insight-config/main.json b/modules/operational-insights/workspace/storage-insight-config/main.json index 4f07959081..86d2fdda8b 100644 --- a/modules/operational-insights/workspace/storage-insight-config/main.json +++ b/modules/operational-insights/workspace/storage-insight-config/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5892497567322793672" - } + "version": "0.20.4.51522", + "templateHash": "5679144933666454393" + }, + "name": "Log Analytics Workspace Storage Insight Configs", + "description": "This module deploys a Log Analytics Workspace Storage Insight Config.", + "owner": "Azure/module-maintainers" }, "parameters": { "logAnalyticsWorkspaceName": { diff --git a/modules/operational-insights/workspace/table/main.json b/modules/operational-insights/workspace/table/main.json index a570736373..83bbc2a91d 100644 --- a/modules/operational-insights/workspace/table/main.json +++ b/modules/operational-insights/workspace/table/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "174331240044920355" - } + "version": "0.20.4.51522", + "templateHash": "761158132904084297" + }, + "name": "Log Analytics Workspace Tables", + "description": "This module deploys a Log Analytics Workspace Table.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -49,8 +52,8 @@ "retentionInDays": { "type": "int", "defaultValue": -1, - "maxValue": 730, "minValue": -1, + "maxValue": 730, "metadata": { "description": "Optional. The table retention in days, between 4 and 730. Setting this property to -1 will default to the workspace retention." } @@ -72,8 +75,8 @@ "totalRetentionInDays": { "type": "int", "defaultValue": -1, - "maxValue": 2555, "minValue": -1, + "maxValue": 2555, "metadata": { "description": "Optional. The table total retention in days, between 4 and 2555. Setting this property to -1 will default to table retention." } diff --git a/modules/operations-management/solution/main.json b/modules/operations-management/solution/main.json index 60d9c62d2c..2cc9b68e33 100644 --- a/modules/operations-management/solution/main.json +++ b/modules/operations-management/solution/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6203827990364745107" - } + "version": "0.20.4.51522", + "templateHash": "16708625392312836324" + }, + "name": "Operations Management Solutions", + "description": "This module deploys an Operations Management Solution.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/policy-insights/remediation/main.json b/modules/policy-insights/remediation/main.json index c2aa0f2d11..fc4f8cf994 100644 --- a/modules/policy-insights/remediation/main.json +++ b/modules/policy-insights/remediation/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14392825922290602980" - } + "version": "0.20.4.51522", + "templateHash": "2388535043106462043" + }, + "name": "Policy Insights Remediations", + "description": "This module deploys a Policy Insights Remediation.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -32,8 +35,8 @@ "parallelDeployments": { "type": "int", "defaultValue": 10, - "maxValue": 30, "minValue": 1, + "maxValue": 30, "metadata": { "description": "Optional. Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. Can be between 1-30. Higher values will cause the remediation to complete more quickly, but increase the risk of throttling. If not provided, the default parallel deployments value is used." } @@ -41,8 +44,8 @@ "resourceCount": { "type": "int", "defaultValue": 500, - "maxValue": 50000, "minValue": 1, + "maxValue": 50000, "metadata": { "description": "Optional. Determines the max number of resources that can be remediated by the remediation job. Can be between 1-50000. If not provided, the default resource count is used." } @@ -176,9 +179,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6787307117626777666" - } + "version": "0.20.4.51522", + "templateHash": "1304798094791157917" + }, + "name": "Policy Insights Remediations (Management Group scope)", + "description": "This module deploys a Policy Insights Remediation on a Management Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -204,8 +210,8 @@ "parallelDeployments": { "type": "int", "defaultValue": 10, - "maxValue": 30, "minValue": 1, + "maxValue": 30, "metadata": { "description": "Optional. Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. Can be between 1-30. Higher values will cause the remediation to complete more quickly, but increase the risk of throttling. If not provided, the default parallel deployments value is used." } @@ -213,8 +219,8 @@ "resourceCount": { "type": "int", "defaultValue": 500, - "maxValue": 50000, "minValue": 1, + "maxValue": 50000, "metadata": { "description": "Optional. Determines the max number of resources that can be remediated by the remediation job. Can be between 1-50000. If not provided, the default resource count is used." } @@ -369,9 +375,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4686786682838572629" - } + "version": "0.20.4.51522", + "templateHash": "16781098206548824638" + }, + "name": "Policy Insights Remediations (Subscription scope)", + "description": "This module deploys a Policy Insights Remediation on a Subscription scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -397,8 +406,8 @@ "parallelDeployments": { "type": "int", "defaultValue": 10, - "maxValue": 30, "minValue": 1, + "maxValue": 30, "metadata": { "description": "Optional. Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. Can be between 1-30. Higher values will cause the remediation to complete more quickly, but increase the risk of throttling. If not provided, the default parallel deployments value is used." } @@ -406,8 +415,8 @@ "resourceCount": { "type": "int", "defaultValue": 500, - "maxValue": 50000, "minValue": 1, + "maxValue": 50000, "metadata": { "description": "Optional. Determines the max number of resources that can be remediated by the remediation job. Can be between 1-50000. If not provided, the default resource count is used." } @@ -562,9 +571,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1267717863880241904" - } + "version": "0.20.4.51522", + "templateHash": "16839903448259241444" + }, + "name": "Policy Insights Remediations (Resource Group scope)", + "description": "This module deploys a Policy Insights Remediation on a Resource Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -590,8 +602,8 @@ "parallelDeployments": { "type": "int", "defaultValue": 10, - "maxValue": 30, "minValue": 1, + "maxValue": 30, "metadata": { "description": "Optional. Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. Can be between 1-30. Higher values will cause the remediation to complete more quickly, but increase the risk of throttling. If not provided, the default parallel deployments value is used." } @@ -599,8 +611,8 @@ "resourceCount": { "type": "int", "defaultValue": 500, - "maxValue": 50000, "minValue": 1, + "maxValue": 50000, "metadata": { "description": "Optional. Determines the max number of resources that can be remediated by the remediation job. Can be between 1-50000. If not provided, the default resource count is used." } diff --git a/modules/policy-insights/remediation/management-group/main.json b/modules/policy-insights/remediation/management-group/main.json index c88735579b..0a87c250c0 100644 --- a/modules/policy-insights/remediation/management-group/main.json +++ b/modules/policy-insights/remediation/management-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6787307117626777666" - } + "version": "0.20.4.51522", + "templateHash": "1304798094791157917" + }, + "name": "Policy Insights Remediations (Management Group scope)", + "description": "This module deploys a Policy Insights Remediation on a Management Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -32,8 +35,8 @@ "parallelDeployments": { "type": "int", "defaultValue": 10, - "maxValue": 30, "minValue": 1, + "maxValue": 30, "metadata": { "description": "Optional. Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. Can be between 1-30. Higher values will cause the remediation to complete more quickly, but increase the risk of throttling. If not provided, the default parallel deployments value is used." } @@ -41,8 +44,8 @@ "resourceCount": { "type": "int", "defaultValue": 500, - "maxValue": 50000, "minValue": 1, + "maxValue": 50000, "metadata": { "description": "Optional. Determines the max number of resources that can be remediated by the remediation job. Can be between 1-50000. If not provided, the default resource count is used." } diff --git a/modules/policy-insights/remediation/resource-group/main.json b/modules/policy-insights/remediation/resource-group/main.json index 16a348daaa..be6c9e58b0 100644 --- a/modules/policy-insights/remediation/resource-group/main.json +++ b/modules/policy-insights/remediation/resource-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1267717863880241904" - } + "version": "0.20.4.51522", + "templateHash": "16839903448259241444" + }, + "name": "Policy Insights Remediations (Resource Group scope)", + "description": "This module deploys a Policy Insights Remediation on a Resource Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -32,8 +35,8 @@ "parallelDeployments": { "type": "int", "defaultValue": 10, - "maxValue": 30, "minValue": 1, + "maxValue": 30, "metadata": { "description": "Optional. Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. Can be between 1-30. Higher values will cause the remediation to complete more quickly, but increase the risk of throttling. If not provided, the default parallel deployments value is used." } @@ -41,8 +44,8 @@ "resourceCount": { "type": "int", "defaultValue": 500, - "maxValue": 50000, "minValue": 1, + "maxValue": 50000, "metadata": { "description": "Optional. Determines the max number of resources that can be remediated by the remediation job. Can be between 1-50000. If not provided, the default resource count is used." } diff --git a/modules/policy-insights/remediation/subscription/main.json b/modules/policy-insights/remediation/subscription/main.json index 9acadf95df..499c963670 100644 --- a/modules/policy-insights/remediation/subscription/main.json +++ b/modules/policy-insights/remediation/subscription/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4686786682838572629" - } + "version": "0.20.4.51522", + "templateHash": "16781098206548824638" + }, + "name": "Policy Insights Remediations (Subscription scope)", + "description": "This module deploys a Policy Insights Remediation on a Subscription scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -32,8 +35,8 @@ "parallelDeployments": { "type": "int", "defaultValue": 10, - "maxValue": 30, "minValue": 1, + "maxValue": 30, "metadata": { "description": "Optional. Determines how many resources to remediate at any given time. Can be used to increase or reduce the pace of the remediation. Can be between 1-30. Higher values will cause the remediation to complete more quickly, but increase the risk of throttling. If not provided, the default parallel deployments value is used." } @@ -41,8 +44,8 @@ "resourceCount": { "type": "int", "defaultValue": 500, - "maxValue": 50000, "minValue": 1, + "maxValue": 50000, "metadata": { "description": "Optional. Determines the max number of resources that can be remediated by the remediation job. Can be between 1-50000. If not provided, the default resource count is used." } diff --git a/modules/power-bi-dedicated/capacity/main.json b/modules/power-bi-dedicated/capacity/main.json index eaa39b0729..778b2470ff 100644 --- a/modules/power-bi-dedicated/capacity/main.json +++ b/modules/power-bi-dedicated/capacity/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7703424854561797533" - } + "version": "0.20.4.51522", + "templateHash": "12231844858437277938" + }, + "name": "Power BI Dedicated Capacities", + "description": "This module deploys a Power BI Dedicated Capacity.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -45,9 +48,6 @@ "skuName": { "type": "string", "defaultValue": "A1", - "metadata": { - "description": "Optional. SkuCapacity of the resource." - }, "allowedValues": [ "A1", "A2", @@ -55,19 +55,22 @@ "A4", "A5", "A6" - ] + ], + "metadata": { + "description": "Optional. SkuCapacity of the resource." + } }, "skuTier": { "type": "string", "defaultValue": "PBIE_Azure", - "metadata": { - "description": "Optional. SkuCapacity of the resource." - }, "allowedValues": [ "AutoPremiumHost", "PBIE_Azure", "Premium" - ] + ], + "metadata": { + "description": "Optional. SkuCapacity of the resource." + } }, "members": { "type": "array", @@ -78,26 +81,26 @@ "mode": { "type": "string", "defaultValue": "Gen2", - "metadata": { - "description": "Optional. Mode of the resource." - }, "allowedValues": [ "Gen1", "Gen2" - ] + ], + "metadata": { + "description": "Optional. Mode of the resource." + } }, "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "NotSpecified", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -181,8 +184,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11763558823755974016" + "version": "0.20.4.51522", + "templateHash": "5472906726478084470" } }, "parameters": { diff --git a/modules/purview/account/.test/common/dependencies.bicep b/modules/purview/account/.test/common/dependencies.bicep index 0987da418b..669c8c9d7f 100644 --- a/modules/purview/account/.test/common/dependencies.bicep +++ b/modules/purview/account/.test/common/dependencies.bicep @@ -17,7 +17,7 @@ var privateDNSZoneNames = [ 'privatelink.servicebus.windows.net' ] -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkName location: location properties: { diff --git a/modules/purview/account/.test/common/main.test.bicep b/modules/purview/account/.test/common/main.test.bicep index 8ab221a468..24f46c7d6e 100644 --- a/modules/purview/account/.test/common/main.test.bicep +++ b/modules/purview/account/.test/common/main.test.bicep @@ -73,7 +73,6 @@ module testDeployment '../../main.bicep' = { } managedResourceGroupName: '${namePrefix}${serviceShort}001-managed-rg' publicNetworkAccess: 'Disabled' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/purview/account/README.md b/modules/purview/account/README.md index 00e1aed6f0..e1dc61fcc7 100644 --- a/modules/purview/account/README.md +++ b/modules/purview/account/README.md @@ -17,8 +17,8 @@ This module deploys a Purview Account. | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | | `Microsoft.Purview/accounts` | [2021-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Purview/2021-07-01/accounts) | ## Parameters @@ -37,7 +37,6 @@ This module deploys a Purview Account. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, DataSensitivity, PurviewAccountAuditEvents, ScanStatus]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub. | @@ -251,7 +250,6 @@ module account './purview/account/main.bicep' = { diagnosticLogCategoriesToEnable: [ 'allLogs' ] - diagnosticLogsRetentionInDays: 7 diagnosticMetricsToEnable: [ 'AllMetrics' ] @@ -387,9 +385,6 @@ module account './purview/account/main.bicep' = { "allLogs" ] }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticMetricsToEnable": { "value": [ "AllMetrics" diff --git a/modules/purview/account/main.bicep b/modules/purview/account/main.bicep index 6d888fb1ed..2ff193993b 100644 --- a/modules/purview/account/main.bicep +++ b/modules/purview/account/main.bicep @@ -27,11 +27,6 @@ param managedResourceGroupName string = 'managed-rg-${name}' ]) param publicNetworkAccess string = 'NotSpecified' -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub.') param diagnosticStorageAccountId string = '' @@ -103,20 +98,12 @@ param lock string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -124,10 +111,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var identityType = !empty(userAssignedIdentities) ? 'SystemAssigned,UserAssigned' : 'SystemAssigned' diff --git a/modules/purview/account/main.json b/modules/purview/account/main.json index 889d07d440..b7c65353b7 100644 --- a/modules/purview/account/main.json +++ b/modules/purview/account/main.json @@ -4,15 +4,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12242183150805712614" - } + "version": "0.20.4.51522", + "templateHash": "7070720012428002907" + }, + "name": "Purview Accounts", + "description": "This module deploys a Purview Account.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { "type": "string", - "maxLength": 63, "minLength": 3, + "maxLength": 63, "metadata": { "description": "Required. Name of the Purview Account." } @@ -57,15 +60,6 @@ "description": "Optional. Whether or not public network access is allowed for this resource. For security reasons it should be disabled. If not specified, it will be disabled by default if private endpoints are set." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -181,14 +175,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } } }, "variables": { @@ -198,11 +192,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -211,15 +201,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "identityType": "[if(not(empty(parameters('userAssignedIdentities'))), 'SystemAssigned,UserAssigned', 'SystemAssigned')]", "identity": "[if(not(equals(variables('identityType'), 'None')), createObject('type', variables('identityType'), 'userAssignedIdentities', if(not(empty(parameters('userAssignedIdentities'))), parameters('userAssignedIdentities'), null())), null())]", "enableReferencedModulesTelemetry": false @@ -332,9 +318,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -399,14 +388,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -464,7 +453,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -529,9 +518,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -542,8 +534,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -594,7 +586,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -664,8 +656,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -835,7 +827,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -892,9 +884,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -959,14 +954,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -1024,7 +1019,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -1089,9 +1084,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -1102,8 +1100,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -1154,7 +1152,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -1224,8 +1222,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -1395,7 +1393,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -1452,9 +1450,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1519,14 +1520,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -1584,7 +1585,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -1649,9 +1650,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -1662,8 +1666,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -1714,7 +1718,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -1784,8 +1788,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -1955,7 +1959,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -2012,9 +2016,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -2079,14 +2086,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -2144,7 +2151,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -2209,9 +2216,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -2222,8 +2232,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -2274,7 +2284,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -2344,8 +2354,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -2515,7 +2525,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -2572,9 +2582,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -2639,14 +2652,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -2704,7 +2717,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -2769,9 +2782,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -2782,8 +2798,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -2834,7 +2850,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -2904,8 +2920,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -3075,7 +3091,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -3118,8 +3134,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4354641790580055350" + "version": "0.20.4.51522", + "templateHash": "1139691228456337328" } }, "parameters": { diff --git a/modules/recovery-services/vault/.test/common/dependencies.bicep b/modules/recovery-services/vault/.test/common/dependencies.bicep index 416aefa8b7..4651dd3d2c 100644 --- a/modules/recovery-services/vault/.test/common/dependencies.bicep +++ b/modules/recovery-services/vault/.test/common/dependencies.bicep @@ -9,45 +9,45 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.siterecovery.windowsazure.com' - location: 'global' + name: 'privatelink.siterecovery.windowsazure.com' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/recovery-services/vault/.test/common/main.test.bicep b/modules/recovery-services/vault/.test/common/main.test.bicep index 4320fda6a6..d2640a4acd 100644 --- a/modules/recovery-services/vault/.test/common/main.test.bicep +++ b/modules/recovery-services/vault/.test/common/main.test.bicep @@ -309,7 +309,6 @@ module testDeployment '../../main.bicep' = { locale: 'en-US' sendToOwners: 'Send' } - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/recovery-services/vault/README.md b/modules/recovery-services/vault/README.md index d1e3ff99a9..8bb79128ee 100644 --- a/modules/recovery-services/vault/README.md +++ b/modules/recovery-services/vault/README.md @@ -17,8 +17,8 @@ This module deploys a Recovery Services Vault. | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | | `Microsoft.RecoveryServices/vaults` | [2023-01-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.RecoveryServices/2023-01-01/vaults) | | `Microsoft.RecoveryServices/vaults/backupconfig` | [2023-01-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.RecoveryServices/2023-01-01/vaults/backupconfig) | | `Microsoft.RecoveryServices/vaults/backupFabrics/protectionContainers` | [2023-01-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.RecoveryServices/2023-01-01/vaults/backupFabrics/protectionContainers) | @@ -49,7 +49,6 @@ This module deploys a Recovery Services Vault. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', AddonAzureBackupAlerts, AddonAzureBackupJobs, AddonAzureBackupPolicy, AddonAzureBackupProtectedInstance, AddonAzureBackupStorage, allLogs, AzureBackupReport, AzureSiteRecoveryEvents, AzureSiteRecoveryJobs, AzureSiteRecoveryProtectedDiskDataChurn, AzureSiteRecoveryRecoveryPoints, AzureSiteRecoveryReplicatedItems, AzureSiteRecoveryReplicationDataUploadRate, AzureSiteRecoveryReplicationStats, CoreAzureBackup]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[Health]` | `[Health]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -1190,7 +1189,6 @@ module vault './recovery-services/vault/main.bicep' = { } diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -1514,9 +1512,6 @@ module vault './recovery-services/vault/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/recovery-services/vault/main.bicep b/modules/recovery-services/vault/main.bicep index 0bdd7f612a..fb430886da 100644 --- a/modules/recovery-services/vault/main.bicep +++ b/modules/recovery-services/vault/main.bicep @@ -35,11 +35,6 @@ param replicationPolicies array = [] @description('Optional. Replication alert settings.') param replicationAlertSettings object = {} -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -125,20 +120,12 @@ param publicNetworkAccess string = 'Disabled' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -146,10 +133,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var identityType = systemAssignedIdentity ? (!empty(userAssignedIdentities) ? 'SystemAssigned,UserAssigned' : 'SystemAssigned') : (!empty(userAssignedIdentities) ? 'UserAssigned' : 'None') diff --git a/modules/recovery-services/vault/main.json b/modules/recovery-services/vault/main.json index 1883946846..ccde94fb9b 100644 --- a/modules/recovery-services/vault/main.json +++ b/modules/recovery-services/vault/main.json @@ -5,7 +5,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "16293846439301048579" + "templateHash": "2454346461488348861" }, "name": "Recovery Services Vaults", "description": "This module deploys a Recovery Services Vault.", @@ -84,15 +84,6 @@ "description": "Optional. Replication alert settings." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "minValue": 0, - "maxValue": 365, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -247,11 +238,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -260,15 +247,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "identityType": "[if(parameters('systemAssignedIdentity'), if(not(empty(parameters('userAssignedIdentities'))), 'SystemAssigned,UserAssigned', 'SystemAssigned'), if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None'))]", "identity": "[if(not(equals(variables('identityType'), 'None')), createObject('type', variables('identityType'), 'userAssignedIdentities', if(not(empty(parameters('userAssignedIdentities'))), parameters('userAssignedIdentities'), null())), null())]", "enableReferencedModulesTelemetry": false @@ -1940,7 +1923,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "609426544615556519" + "templateHash": "13560297539192628062" }, "name": "Private Endpoints", "description": "This module deploys a Private Endpoint.", @@ -2074,7 +2057,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -2140,7 +2123,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "18114841529204248478" + "templateHash": "17831763001460207830" }, "name": "Private Endpoint Private DNS Zone Groups", "description": "This module deploys a Private Endpoint Private DNS Zone Group.", @@ -2207,7 +2190,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -2448,7 +2431,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } diff --git a/modules/relay/namespace/.test/common/dependencies.bicep b/modules/relay/namespace/.test/common/dependencies.bicep index 4df36073d0..7b0b0e73c1 100644 --- a/modules/relay/namespace/.test/common/dependencies.bicep +++ b/modules/relay/namespace/.test/common/dependencies.bicep @@ -9,45 +9,45 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.servicebus.windows.net' - location: 'global' + name: 'privatelink.servicebus.windows.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/relay/namespace/.test/common/main.test.bicep b/modules/relay/namespace/.test/common/main.test.bicep index 1a53c17303..33dc81515e 100644 --- a/modules/relay/namespace/.test/common/main.test.bicep +++ b/modules/relay/namespace/.test/common/main.test.bicep @@ -148,7 +148,6 @@ module testDeployment '../../main.bicep' = { relayType: 'NetTcp' } ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/relay/namespace/.test/pe/dependencies.bicep b/modules/relay/namespace/.test/pe/dependencies.bicep index e84295c592..e78fb9a0d8 100644 --- a/modules/relay/namespace/.test/pe/dependencies.bicep +++ b/modules/relay/namespace/.test/pe/dependencies.bicep @@ -6,40 +6,40 @@ param virtualNetworkName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.servicebus.windows.net' - location: 'global' + name: 'privatelink.servicebus.windows.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/relay/namespace/README.md b/modules/relay/namespace/README.md index e241f834b9..b2718c4bcc 100644 --- a/modules/relay/namespace/README.md +++ b/modules/relay/namespace/README.md @@ -17,8 +17,8 @@ This module deploys a Relay Namespace | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | | `Microsoft.Relay/namespaces` | [2021-11-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Relay/2021-11-01/namespaces) | | `Microsoft.Relay/namespaces/authorizationRules` | [2021-11-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Relay/2021-11-01/namespaces/authorizationRules) | | `Microsoft.Relay/namespaces/hybridConnections` | [2021-11-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Relay/2021-11-01/namespaces/hybridConnections) | @@ -43,7 +43,6 @@ This module deploys a Relay Namespace | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs, hybridConnectionsEvent]` | `['', allLogs, hybridConnectionsEvent, OperationalLogs]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -316,7 +315,6 @@ module namespace './relay/namespace/main.bicep' = { ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -448,9 +446,6 @@ module namespace './relay/namespace/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/relay/namespace/authorization-rule/main.json b/modules/relay/namespace/authorization-rule/main.json index 1c63ed923b..838638b05f 100644 --- a/modules/relay/namespace/authorization-rule/main.json +++ b/modules/relay/namespace/authorization-rule/main.json @@ -4,15 +4,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9763854483927913724" - } + "version": "0.20.4.51522", + "templateHash": "2910468169645277295" + }, + "name": "Relay Namespace Authorization Rules", + "description": "This module deploys a Relay Namespace Authorization Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Conditional. The name of the parent Relay Namespace for the Relay Hybrid Connection. Required if the template is used in a standalone deployment." } diff --git a/modules/relay/namespace/hybrid-connection/authorization-rule/main.json b/modules/relay/namespace/hybrid-connection/authorization-rule/main.json index eba0fb4038..e9e3874815 100644 --- a/modules/relay/namespace/hybrid-connection/authorization-rule/main.json +++ b/modules/relay/namespace/hybrid-connection/authorization-rule/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17231058756777007644" - } + "version": "0.20.4.51522", + "templateHash": "9718423441307347496" + }, + "name": "Hybrid Connection Authorization Rules", + "description": "This module deploys a Hybrid Connection Authorization Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/relay/namespace/hybrid-connection/main.json b/modules/relay/namespace/hybrid-connection/main.json index a025fb1b67..2a4a626c8c 100644 --- a/modules/relay/namespace/hybrid-connection/main.json +++ b/modules/relay/namespace/hybrid-connection/main.json @@ -4,23 +4,26 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7847404424450621571" - } + "version": "0.20.4.51522", + "templateHash": "5587843022604046042" + }, + "name": "Relay Namespace Hybrid Connections", + "description": "This module deploys a Relay Namespace Hybrid Connection.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Conditional. The name of the parent Relay Namespace for the Relay Hybrid Connection. Required if the template is used in a standalone deployment." } }, "name": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Required. The name of the hybrid connection." } @@ -69,14 +72,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -168,9 +171,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17231058756777007644" - } + "version": "0.20.4.51522", + "templateHash": "9718423441307347496" + }, + "name": "Hybrid Connection Authorization Rules", + "description": "This module deploys a Hybrid Connection Authorization Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -298,8 +304,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "232914041275606585" + "version": "0.20.4.51522", + "templateHash": "5814555714153100571" } }, "parameters": { diff --git a/modules/relay/namespace/main.bicep b/modules/relay/namespace/main.bicep index 6287d52dd6..3eeae7b77e 100644 --- a/modules/relay/namespace/main.bicep +++ b/modules/relay/namespace/main.bicep @@ -28,11 +28,6 @@ param authorizationRules array = [ } ] -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -100,20 +95,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -121,10 +108,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var enableReferencedModulesTelemetry = false diff --git a/modules/relay/namespace/main.json b/modules/relay/namespace/main.json index fa65249449..fe98978996 100644 --- a/modules/relay/namespace/main.json +++ b/modules/relay/namespace/main.json @@ -4,15 +4,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18363231390750334097" - } + "version": "0.20.4.51522", + "templateHash": "1044636100638824265" + }, + "name": "Relay Namespaces", + "description": "This module deploys a Relay Namespace", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Required. Name of the Relay Namespace." } @@ -50,15 +53,6 @@ "description": "Optional. Authorization Rules for the Relay namespace." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -90,14 +84,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -191,11 +185,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -204,15 +194,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "enableReferencedModulesTelemetry": false }, "resources": [ @@ -304,15 +290,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9763854483927913724" - } + "version": "0.20.4.51522", + "templateHash": "2910468169645277295" + }, + "name": "Relay Namespace Authorization Rules", + "description": "This module deploys a Relay Namespace Authorization Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Conditional. The name of the parent Relay Namespace for the Relay Hybrid Connection. Required if the template is used in a standalone deployment." } @@ -423,15 +412,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2429764380806740500" - } + "version": "0.20.4.51522", + "templateHash": "319020533136370885" + }, + "name": "Relay Namespace Network Rules Sets", + "description": "This module deploys a Relay Namespace Network Rule Set.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Conditional. The name of the parent Relay Namespace for the Relay Network Rule Set. Required if the template is used in a standalone deployment." } @@ -439,24 +431,24 @@ "publicNetworkAccess": { "type": "string", "defaultValue": "Enabled", - "metadata": { - "description": "Optional. This determines if traffic is allowed over public network. Default is \"Enabled\". If set to \"Disabled\", traffic to this namespace will be restricted over Private Endpoints only and network rules will not be applied." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. This determines if traffic is allowed over public network. Default is \"Enabled\". If set to \"Disabled\", traffic to this namespace will be restricted over Private Endpoints only and network rules will not be applied." + } }, "defaultAction": { "type": "string", "defaultValue": "Allow", - "metadata": { - "description": "Optional. Default Action for Network Rule Set. Default is \"Allow\". It will not be set if publicNetworkAccess is \"Disabled\". Otherwise, it will be set to \"Deny\" if ipRules or virtualNetworkRules are being used." - }, "allowedValues": [ "Allow", "Deny" - ] + ], + "metadata": { + "description": "Optional. Default Action for Network Rule Set. Default is \"Allow\". It will not be set if publicNetworkAccess is \"Disabled\". Otherwise, it will be set to \"Deny\" if ipRules or virtualNetworkRules are being used." + } }, "ipRules": { "type": "array", @@ -563,23 +555,26 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7847404424450621571" - } + "version": "0.20.4.51522", + "templateHash": "5587843022604046042" + }, + "name": "Relay Namespace Hybrid Connections", + "description": "This module deploys a Relay Namespace Hybrid Connection.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Conditional. The name of the parent Relay Namespace for the Relay Hybrid Connection. Required if the template is used in a standalone deployment." } }, "name": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Required. The name of the hybrid connection." } @@ -628,14 +623,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -727,9 +722,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17231058756777007644" - } + "version": "0.20.4.51522", + "templateHash": "9718423441307347496" + }, + "name": "Hybrid Connection Authorization Rules", + "description": "This module deploys a Hybrid Connection Authorization Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -857,8 +855,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "232914041275606585" + "version": "0.20.4.51522", + "templateHash": "5814555714153100571" } }, "parameters": { @@ -1042,36 +1040,39 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1187887494213101123" - } + "version": "0.20.4.51522", + "templateHash": "18205555090536788516" + }, + "name": "Relay Namespace WCF Relays", + "description": "This module deploys a Relay Namespace WCF Relay.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Conditional. The name of the parent Relay Namespace for the WCF Relay. Required if the template is used in a standalone deployment." } }, "name": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Required. Name of the WCF Relay." } }, "relayType": { "type": "string", - "metadata": { - "description": "Required. Type of WCF Relay." - }, "allowedValues": [ "Http", "NetTcp" - ] + ], + "metadata": { + "description": "Required. Type of WCF Relay." + } }, "requiresClientAuthorization": { "type": "bool", @@ -1125,14 +1126,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -1226,9 +1227,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2947511199808673632" - } + "version": "0.20.4.51522", + "templateHash": "13141425566828642958" + }, + "name": "WCF Relay Authorization Rules", + "description": "This module deploys a WCF Relay Authorization Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1356,8 +1360,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18065734222254333164" + "version": "0.20.4.51522", + "templateHash": "8507868775083821058" } }, "parameters": { @@ -1552,9 +1556,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1619,14 +1626,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -1684,7 +1691,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -1749,9 +1756,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -1762,8 +1772,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -1814,7 +1824,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -1884,8 +1894,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -2055,7 +2065,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -2098,8 +2108,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15987440490735040087" + "version": "0.20.4.51522", + "templateHash": "14855341178043805106" } }, "parameters": { diff --git a/modules/relay/namespace/network-rule-set/main.json b/modules/relay/namespace/network-rule-set/main.json index e8101f206e..0a2577851e 100644 --- a/modules/relay/namespace/network-rule-set/main.json +++ b/modules/relay/namespace/network-rule-set/main.json @@ -4,15 +4,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2429764380806740500" - } + "version": "0.20.4.51522", + "templateHash": "319020533136370885" + }, + "name": "Relay Namespace Network Rules Sets", + "description": "This module deploys a Relay Namespace Network Rule Set.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Conditional. The name of the parent Relay Namespace for the Relay Network Rule Set. Required if the template is used in a standalone deployment." } @@ -20,24 +23,24 @@ "publicNetworkAccess": { "type": "string", "defaultValue": "Enabled", - "metadata": { - "description": "Optional. This determines if traffic is allowed over public network. Default is \"Enabled\". If set to \"Disabled\", traffic to this namespace will be restricted over Private Endpoints only and network rules will not be applied." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. This determines if traffic is allowed over public network. Default is \"Enabled\". If set to \"Disabled\", traffic to this namespace will be restricted over Private Endpoints only and network rules will not be applied." + } }, "defaultAction": { "type": "string", "defaultValue": "Allow", - "metadata": { - "description": "Optional. Default Action for Network Rule Set. Default is \"Allow\". It will not be set if publicNetworkAccess is \"Disabled\". Otherwise, it will be set to \"Deny\" if ipRules or virtualNetworkRules are being used." - }, "allowedValues": [ "Allow", "Deny" - ] + ], + "metadata": { + "description": "Optional. Default Action for Network Rule Set. Default is \"Allow\". It will not be set if publicNetworkAccess is \"Disabled\". Otherwise, it will be set to \"Deny\" if ipRules or virtualNetworkRules are being used." + } }, "ipRules": { "type": "array", diff --git a/modules/relay/namespace/wcf-relay/authorization-rule/main.json b/modules/relay/namespace/wcf-relay/authorization-rule/main.json index d483452ce3..17285b2410 100644 --- a/modules/relay/namespace/wcf-relay/authorization-rule/main.json +++ b/modules/relay/namespace/wcf-relay/authorization-rule/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2947511199808673632" - } + "version": "0.20.4.51522", + "templateHash": "13141425566828642958" + }, + "name": "WCF Relay Authorization Rules", + "description": "This module deploys a WCF Relay Authorization Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/relay/namespace/wcf-relay/main.json b/modules/relay/namespace/wcf-relay/main.json index 4b48388da4..309e400e0b 100644 --- a/modules/relay/namespace/wcf-relay/main.json +++ b/modules/relay/namespace/wcf-relay/main.json @@ -4,36 +4,39 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1187887494213101123" - } + "version": "0.20.4.51522", + "templateHash": "18205555090536788516" + }, + "name": "Relay Namespace WCF Relays", + "description": "This module deploys a Relay Namespace WCF Relay.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Conditional. The name of the parent Relay Namespace for the WCF Relay. Required if the template is used in a standalone deployment." } }, "name": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Required. Name of the WCF Relay." } }, "relayType": { "type": "string", - "metadata": { - "description": "Required. Type of WCF Relay." - }, "allowedValues": [ "Http", "NetTcp" - ] + ], + "metadata": { + "description": "Required. Type of WCF Relay." + } }, "requiresClientAuthorization": { "type": "bool", @@ -87,14 +90,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -188,9 +191,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2947511199808673632" - } + "version": "0.20.4.51522", + "templateHash": "13141425566828642958" + }, + "name": "WCF Relay Authorization Rules", + "description": "This module deploys a WCF Relay Authorization Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -318,8 +324,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18065734222254333164" + "version": "0.20.4.51522", + "templateHash": "8507868775083821058" } }, "parameters": { diff --git a/modules/resources/deployment-script/main.json b/modules/resources/deployment-script/main.json index cd772213c8..edd5f3d8de 100644 --- a/modules/resources/deployment-script/main.json +++ b/modules/resources/deployment-script/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5116894317712992016" - } + "version": "0.20.4.51522", + "templateHash": "18406669488132418296" + }, + "name": "Deployment Scripts", + "description": "This module deploys a Deployment Script.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -146,14 +149,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "tags": { "type": "object", diff --git a/modules/resources/resource-group/main.json b/modules/resources/resource-group/main.json index aa80375d55..53c24ada4a 100644 --- a/modules/resources/resource-group/main.json +++ b/modules/resources/resource-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4868927926622801511" - } + "version": "0.20.4.51522", + "templateHash": "7084409585316897596" + }, + "name": "Resource Groups", + "description": "This module deploys a Resource Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -25,14 +28,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -113,9 +116,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9338790793667422174" - } + "version": "0.20.4.51522", + "templateHash": "7885747985110001606" + }, + "name": "Authorization Locks (Resource Group scope)", + "description": "This module deploys an Authorization Lock at a Resource Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -127,13 +133,13 @@ }, "level": { "type": "string", - "metadata": { - "description": "Required. Set lock level." - }, "allowedValues": [ "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Required. Set lock level." + } }, "notes": { "type": "string", @@ -243,8 +249,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12586841471874813417" + "version": "0.20.4.51522", + "templateHash": "13758321727740315260" } }, "parameters": { diff --git a/modules/resources/tags/main.json b/modules/resources/tags/main.json index 8898c97a6d..89c1bbac3a 100644 --- a/modules/resources/tags/main.json +++ b/modules/resources/tags/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "791054837987751566" - } + "version": "0.20.4.51522", + "templateHash": "15599858722775223607" + }, + "name": "Resources Tags", + "description": "This module deploys a Resource Tag at a Subscription or Resource Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "tags": { @@ -102,9 +105,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17191629021100561556" - } + "version": "0.20.4.51522", + "templateHash": "17445460813956994133" + }, + "name": "Resources Tags Subscription Scope", + "description": "This module deploys a Resource Tag on a Subscription scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "tags": { @@ -180,8 +186,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9346428889993702152" + "version": "0.20.4.51522", + "templateHash": "373680921396677494" } }, "parameters": { @@ -261,9 +267,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15588952701466266078" - } + "version": "0.20.4.51522", + "templateHash": "4275347865908810280" + }, + "name": "Resources Tags Resource Group", + "description": "This module deploys a Resource Tag on a Resource Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "tags": { @@ -330,8 +339,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8684872468020728375" + "version": "0.20.4.51522", + "templateHash": "5447313974004996573" } }, "parameters": { diff --git a/modules/resources/tags/resource-group/main.json b/modules/resources/tags/resource-group/main.json index 261dd3b589..fabaa09756 100644 --- a/modules/resources/tags/resource-group/main.json +++ b/modules/resources/tags/resource-group/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15588952701466266078" - } + "version": "0.20.4.51522", + "templateHash": "4275347865908810280" + }, + "name": "Resources Tags Resource Group", + "description": "This module deploys a Resource Tag on a Resource Group scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "tags": { @@ -73,8 +76,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8684872468020728375" + "version": "0.20.4.51522", + "templateHash": "5447313974004996573" } }, "parameters": { diff --git a/modules/resources/tags/subscription/main.json b/modules/resources/tags/subscription/main.json index 4b1bf74e4a..615fd9ce66 100644 --- a/modules/resources/tags/subscription/main.json +++ b/modules/resources/tags/subscription/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17191629021100561556" - } + "version": "0.20.4.51522", + "templateHash": "17445460813956994133" + }, + "name": "Resources Tags Subscription Scope", + "description": "This module deploys a Resource Tag on a Subscription scope.", + "owner": "Azure/module-maintainers" }, "parameters": { "tags": { @@ -82,8 +85,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9346428889993702152" + "version": "0.20.4.51522", + "templateHash": "373680921396677494" } }, "parameters": { diff --git a/modules/security/azure-security-center/main.json b/modules/security/azure-security-center/main.json index a4b0b9ca74..1eb0d8308e 100644 --- a/modules/security/azure-security-center/main.json +++ b/modules/security/azure-security-center/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6154301904044206249" - } + "version": "0.20.4.51522", + "templateHash": "11773698987297329299" + }, + "name": "Azure Security Center (Defender for Cloud)", + "description": "This module deploys an Azure Security Center (Defender for Cloud) Configuration.", + "owner": "Azure/module-maintainers" }, "parameters": { "workspaceId": { @@ -361,8 +364,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12093553705747671165" + "version": "0.20.4.51522", + "templateHash": "1815401284560397161" } }, "parameters": { diff --git a/modules/service-bus/namespace/.test/common/dependencies.bicep b/modules/service-bus/namespace/.test/common/dependencies.bicep index e551480248..d657d2a1f0 100644 --- a/modules/service-bus/namespace/.test/common/dependencies.bicep +++ b/modules/service-bus/namespace/.test/common/dependencies.bicep @@ -9,45 +9,45 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.servicebus.windows.net' - location: 'global' + name: 'privatelink.servicebus.windows.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/service-bus/namespace/.test/common/main.test.bicep b/modules/service-bus/namespace/.test/common/main.test.bicep index 556a132a75..dae378b8ce 100644 --- a/modules/service-bus/namespace/.test/common/main.test.bicep +++ b/modules/service-bus/namespace/.test/common/main.test.bicep @@ -178,7 +178,6 @@ module testDeployment '../../main.bicep' = { ] } ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/service-bus/namespace/.test/encr/dependencies.bicep b/modules/service-bus/namespace/.test/encr/dependencies.bicep index 598f2ef701..0c085b0637 100644 --- a/modules/service-bus/namespace/.test/encr/dependencies.bicep +++ b/modules/service-bus/namespace/.test/encr/dependencies.bicep @@ -13,65 +13,65 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource keyVault 'Microsoft.KeyVault/vaults@2022-07-01' = { - name: keyVaultName - location: location - properties: { - sku: { - family: 'A' - name: 'standard' - } - tenantId: tenant().tenantId - enablePurgeProtection: true // Required by service bus namespace - softDeleteRetentionInDays: 7 - enabledForTemplateDeployment: true - enabledForDiskEncryption: true - enabledForDeployment: true - enableRbacAuthorization: true - accessPolicies: [] + name: keyVaultName + location: location + properties: { + sku: { + family: 'A' + name: 'standard' } + tenantId: tenant().tenantId + enablePurgeProtection: true // Required by service bus namespace + softDeleteRetentionInDays: 7 + enabledForTemplateDeployment: true + enabledForDiskEncryption: true + enabledForDeployment: true + enableRbacAuthorization: true + accessPolicies: [] + } - resource key 'keys@2022-07-01' = { - name: 'keyEncryptionKey' - properties: { - kty: 'RSA' - } + resource key 'keys@2022-07-01' = { + name: 'keyEncryptionKey' + properties: { + kty: 'RSA' } + } } resource keyPermissions 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid('msi-${keyVault::key.id}-${location}-${managedIdentity.id}-Key-Reader-RoleAssignment') - scope: keyVault::key - properties: { - principalId: managedIdentity.properties.principalId - // Key Vault Crypto User - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '12338af0-0e69-4776-bea7-57ae8d297424') - principalType: 'ServicePrincipal' - } + name: guid('msi-${keyVault::key.id}-${location}-${managedIdentity.id}-Key-Reader-RoleAssignment') + scope: keyVault::key + properties: { + principalId: managedIdentity.properties.principalId + // Key Vault Crypto User + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '12338af0-0e69-4776-bea7-57ae8d297424') + principalType: 'ServicePrincipal' + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/service-bus/namespace/.test/pe/dependencies.bicep b/modules/service-bus/namespace/.test/pe/dependencies.bicep index e84295c592..e78fb9a0d8 100644 --- a/modules/service-bus/namespace/.test/pe/dependencies.bicep +++ b/modules/service-bus/namespace/.test/pe/dependencies.bicep @@ -6,40 +6,40 @@ param virtualNetworkName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.servicebus.windows.net' - location: 'global' + name: 'privatelink.servicebus.windows.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/service-bus/namespace/README.md b/modules/service-bus/namespace/README.md index 2be3efbc55..dbecee6455 100644 --- a/modules/service-bus/namespace/README.md +++ b/modules/service-bus/namespace/README.md @@ -17,8 +17,8 @@ This module deploys a Service Bus Namespace. | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | | `Microsoft.ServiceBus/namespaces` | [2021-11-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.ServiceBus/2021-11-01/namespaces) | | `Microsoft.ServiceBus/namespaces/AuthorizationRules` | [2017-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.ServiceBus/2017-04-01/namespaces/AuthorizationRules) | | `Microsoft.ServiceBus/namespaces/disasterRecoveryConfigs` | [2017-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.ServiceBus/2017-04-01/namespaces/disasterRecoveryConfigs) | @@ -54,7 +54,6 @@ This module deploys a Service Bus Namespace. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, OperationalLogs]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -403,7 +402,6 @@ module namespace './service-bus/namespace/main.bicep' = { ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -569,9 +567,6 @@ module namespace './service-bus/namespace/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/service-bus/namespace/authorization-rule/main.json b/modules/service-bus/namespace/authorization-rule/main.json index 6a028647de..dbc2c2b79c 100644 --- a/modules/service-bus/namespace/authorization-rule/main.json +++ b/modules/service-bus/namespace/authorization-rule/main.json @@ -4,15 +4,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3980247914866382538" - } + "version": "0.20.4.51522", + "templateHash": "15235435585316551051" + }, + "name": "Service Bus Namespace Authorization Rules", + "description": "This module deploys a Service Bus Namespace Authorization Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Conditional. The name of the parent Service Bus Namespace for the Service Bus Queue. Required if the template is used in a standalone deployment." } diff --git a/modules/service-bus/namespace/disaster-recovery-config/main.json b/modules/service-bus/namespace/disaster-recovery-config/main.json index 799a34fbb8..7dc2c03b14 100644 --- a/modules/service-bus/namespace/disaster-recovery-config/main.json +++ b/modules/service-bus/namespace/disaster-recovery-config/main.json @@ -4,15 +4,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10239561254903489880" - } + "version": "0.20.4.51522", + "templateHash": "13563716064472285794" + }, + "name": "Service Bus Namespace Disaster Recovery Configs", + "description": "This module deploys a Service Bus Namespace Disaster Recovery Config", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Conditional. The name of the parent Service Bus Namespace for the Service Bus Queue. Required if the template is used in a standalone deployment." } diff --git a/modules/service-bus/namespace/main.bicep b/modules/service-bus/namespace/main.bicep index 0745ab81fc..ec21ab1119 100644 --- a/modules/service-bus/namespace/main.bicep +++ b/modules/service-bus/namespace/main.bicep @@ -38,11 +38,6 @@ param migrationConfigurations object = {} @description('Optional. The disaster recovery configuration.') param disasterRecoveryConfigs object = {} -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -129,20 +124,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -150,10 +137,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var identityType = systemAssignedIdentity ? (!empty(userAssignedIdentities) ? 'SystemAssigned,UserAssigned' : 'SystemAssigned') : (!empty(userAssignedIdentities) ? 'UserAssigned' : 'None') diff --git a/modules/service-bus/namespace/main.json b/modules/service-bus/namespace/main.json index 07b5120380..d85f7b04b9 100644 --- a/modules/service-bus/namespace/main.json +++ b/modules/service-bus/namespace/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17158630928383768350" - } + "version": "0.20.4.51522", + "templateHash": "14431444875905250098" + }, + "name": "Service Bus Namespaces", + "description": "This module deploys a Service Bus Namespace.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -72,15 +75,6 @@ "description": "Optional. The disaster recovery configuration." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -112,14 +106,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "systemAssignedIdentity": { "type": "bool", @@ -260,11 +254,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -273,15 +263,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "identityType": "[if(parameters('systemAssignedIdentity'), if(not(empty(parameters('userAssignedIdentities'))), 'SystemAssigned,UserAssigned', 'SystemAssigned'), if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None'))]", "identity": "[if(not(equals(variables('identityType'), 'None')), createObject('type', variables('identityType'), 'userAssignedIdentities', if(not(empty(parameters('userAssignedIdentities'))), parameters('userAssignedIdentities'), null())), null())]", "enableReferencedModulesTelemetry": false @@ -379,15 +365,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3980247914866382538" - } + "version": "0.20.4.51522", + "templateHash": "15235435585316551051" + }, + "name": "Service Bus Namespace Authorization Rules", + "description": "This module deploys a Service Bus Namespace Authorization Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Conditional. The name of the parent Service Bus Namespace for the Service Bus Queue. Required if the template is used in a standalone deployment." } @@ -498,15 +487,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10239561254903489880" - } + "version": "0.20.4.51522", + "templateHash": "13563716064472285794" + }, + "name": "Service Bus Namespace Disaster Recovery Configs", + "description": "This module deploys a Service Bus Namespace Disaster Recovery Config", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Conditional. The name of the parent Service Bus Namespace for the Service Bus Queue. Required if the template is used in a standalone deployment." } @@ -624,15 +616,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9634923970896018925" - } + "version": "0.20.4.51522", + "templateHash": "15978046556546709106" + }, + "name": "Service Bus Namespace Migration Configuration", + "description": "This module deploys a Service Bus Namespace Migration Configuration.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Conditional. The name of the parent Service Bus Namespace for the Service Bus Queue. Required if the template is used in a standalone deployment." } @@ -740,15 +735,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11341933962050615676" - } + "version": "0.20.4.51522", + "templateHash": "16662631854898993961" + }, + "name": "Service Bus Namespace Network Rule Sets", + "description": "This module deploys a ServiceBus Namespace Network Rule Set.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Conditional. The name of the parent Service Bus Namespace for the Service Bus Network Rule Set. Required if the template is used in a standalone deployment." } @@ -756,24 +754,24 @@ "publicNetworkAccess": { "type": "string", "defaultValue": "Enabled", - "metadata": { - "description": "Optional. This determines if traffic is allowed over public network. Default is \"Enabled\". If set to \"Disabled\", traffic to this namespace will be restricted over Private Endpoints only and network rules will not be applied." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. This determines if traffic is allowed over public network. Default is \"Enabled\". If set to \"Disabled\", traffic to this namespace will be restricted over Private Endpoints only and network rules will not be applied." + } }, "defaultAction": { "type": "string", "defaultValue": "Allow", - "metadata": { - "description": "Optional. Default Action for Network Rule Set. Default is \"Allow\". It will not be set if publicNetworkAccess is \"Disabled\". Otherwise, it will be set to \"Deny\" if ipRules or virtualNetworkRules are being used." - }, "allowedValues": [ "Allow", "Deny" - ] + ], + "metadata": { + "description": "Optional. Default Action for Network Rule Set. Default is \"Allow\". It will not be set if publicNetworkAccess is \"Disabled\". Otherwise, it will be set to \"Deny\" if ipRules or virtualNetworkRules are being used." + } }, "trustedServiceAccessEnabled": { "type": "bool", @@ -918,23 +916,26 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17555846329866342390" - } + "version": "0.20.4.51522", + "templateHash": "12881561992595458775" + }, + "name": "Service Bus Namespace Queue", + "description": "This module deploys a Service Bus Namespace Queue.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Conditional. The name of the parent Service Bus Namespace for the Service Bus Queue. Required if the template is used in a standalone deployment." } }, "name": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Required. Name of the Service Bus Queue." } @@ -1055,14 +1056,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -1164,9 +1165,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3929679930039405498" - } + "version": "0.20.4.51522", + "templateHash": "18039866213861972678" + }, + "name": "Service Bus Namespace Queue Authorization Rules", + "description": "This module deploys a Service Bus Namespace Queue Authorization Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1294,8 +1298,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7877329706197358997" + "version": "0.20.4.51522", + "templateHash": "18045820924353327609" } }, "parameters": { @@ -1485,23 +1489,26 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4304998500028939273" - } + "version": "0.20.4.51522", + "templateHash": "921300981514456809" + }, + "name": "Service Bus Namespace Topic", + "description": "This module deploys a Service Bus Namespace Topic.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Conditional. The name of the parent Service Bus Namespace for the Service Bus Topic. Required if the template is used in a standalone deployment." } }, "name": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Required. Name of the Service Bus Topic." } @@ -1615,14 +1622,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -1723,9 +1730,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12238459450385505191" - } + "version": "0.20.4.51522", + "templateHash": "12912382339345981506" + }, + "name": "Service Bus Namespace Topic Authorization Rules", + "description": "This module deploys a Service Bus Namespace Topic Authorization Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1853,8 +1863,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18279135895049473482" + "version": "0.20.4.51522", + "templateHash": "11124682842627815351" } }, "parameters": { @@ -2048,9 +2058,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -2115,14 +2128,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -2180,7 +2193,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -2245,9 +2258,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -2258,8 +2274,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -2310,7 +2326,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -2380,8 +2396,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -2551,7 +2567,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -2594,8 +2610,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15951430180432079946" + "version": "0.20.4.51522", + "templateHash": "8786741997339859255" } }, "parameters": { diff --git a/modules/service-bus/namespace/migration-configuration/main.json b/modules/service-bus/namespace/migration-configuration/main.json index d554545e11..7227e9c794 100644 --- a/modules/service-bus/namespace/migration-configuration/main.json +++ b/modules/service-bus/namespace/migration-configuration/main.json @@ -4,15 +4,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9634923970896018925" - } + "version": "0.20.4.51522", + "templateHash": "15978046556546709106" + }, + "name": "Service Bus Namespace Migration Configuration", + "description": "This module deploys a Service Bus Namespace Migration Configuration.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Conditional. The name of the parent Service Bus Namespace for the Service Bus Queue. Required if the template is used in a standalone deployment." } diff --git a/modules/service-bus/namespace/network-rule-set/main.json b/modules/service-bus/namespace/network-rule-set/main.json index bf572d1525..c998091cf1 100644 --- a/modules/service-bus/namespace/network-rule-set/main.json +++ b/modules/service-bus/namespace/network-rule-set/main.json @@ -4,15 +4,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11341933962050615676" - } + "version": "0.20.4.51522", + "templateHash": "16662631854898993961" + }, + "name": "Service Bus Namespace Network Rule Sets", + "description": "This module deploys a ServiceBus Namespace Network Rule Set.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Conditional. The name of the parent Service Bus Namespace for the Service Bus Network Rule Set. Required if the template is used in a standalone deployment." } @@ -20,24 +23,24 @@ "publicNetworkAccess": { "type": "string", "defaultValue": "Enabled", - "metadata": { - "description": "Optional. This determines if traffic is allowed over public network. Default is \"Enabled\". If set to \"Disabled\", traffic to this namespace will be restricted over Private Endpoints only and network rules will not be applied." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. This determines if traffic is allowed over public network. Default is \"Enabled\". If set to \"Disabled\", traffic to this namespace will be restricted over Private Endpoints only and network rules will not be applied." + } }, "defaultAction": { "type": "string", "defaultValue": "Allow", - "metadata": { - "description": "Optional. Default Action for Network Rule Set. Default is \"Allow\". It will not be set if publicNetworkAccess is \"Disabled\". Otherwise, it will be set to \"Deny\" if ipRules or virtualNetworkRules are being used." - }, "allowedValues": [ "Allow", "Deny" - ] + ], + "metadata": { + "description": "Optional. Default Action for Network Rule Set. Default is \"Allow\". It will not be set if publicNetworkAccess is \"Disabled\". Otherwise, it will be set to \"Deny\" if ipRules or virtualNetworkRules are being used." + } }, "trustedServiceAccessEnabled": { "type": "bool", diff --git a/modules/service-bus/namespace/queue/authorization-rule/main.json b/modules/service-bus/namespace/queue/authorization-rule/main.json index 57419438f1..02d33f18fd 100644 --- a/modules/service-bus/namespace/queue/authorization-rule/main.json +++ b/modules/service-bus/namespace/queue/authorization-rule/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3929679930039405498" - } + "version": "0.20.4.51522", + "templateHash": "18039866213861972678" + }, + "name": "Service Bus Namespace Queue Authorization Rules", + "description": "This module deploys a Service Bus Namespace Queue Authorization Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/service-bus/namespace/queue/main.json b/modules/service-bus/namespace/queue/main.json index 54bc04f2db..a2d25f0d38 100644 --- a/modules/service-bus/namespace/queue/main.json +++ b/modules/service-bus/namespace/queue/main.json @@ -4,23 +4,26 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17555846329866342390" - } + "version": "0.20.4.51522", + "templateHash": "12881561992595458775" + }, + "name": "Service Bus Namespace Queue", + "description": "This module deploys a Service Bus Namespace Queue.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Conditional. The name of the parent Service Bus Namespace for the Service Bus Queue. Required if the template is used in a standalone deployment." } }, "name": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Required. Name of the Service Bus Queue." } @@ -141,14 +144,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -250,9 +253,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3929679930039405498" - } + "version": "0.20.4.51522", + "templateHash": "18039866213861972678" + }, + "name": "Service Bus Namespace Queue Authorization Rules", + "description": "This module deploys a Service Bus Namespace Queue Authorization Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -380,8 +386,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "7877329706197358997" + "version": "0.20.4.51522", + "templateHash": "18045820924353327609" } }, "parameters": { diff --git a/modules/service-bus/namespace/topic/authorization-rule/main.json b/modules/service-bus/namespace/topic/authorization-rule/main.json index a48dc8cf28..7d2537e9c0 100644 --- a/modules/service-bus/namespace/topic/authorization-rule/main.json +++ b/modules/service-bus/namespace/topic/authorization-rule/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12238459450385505191" - } + "version": "0.20.4.51522", + "templateHash": "12912382339345981506" + }, + "name": "Service Bus Namespace Topic Authorization Rules", + "description": "This module deploys a Service Bus Namespace Topic Authorization Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/service-bus/namespace/topic/main.json b/modules/service-bus/namespace/topic/main.json index db6aecbb09..e5786cdfc5 100644 --- a/modules/service-bus/namespace/topic/main.json +++ b/modules/service-bus/namespace/topic/main.json @@ -4,23 +4,26 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4304998500028939273" - } + "version": "0.20.4.51522", + "templateHash": "921300981514456809" + }, + "name": "Service Bus Namespace Topic", + "description": "This module deploys a Service Bus Namespace Topic.", + "owner": "Azure/module-maintainers" }, "parameters": { "namespaceName": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Conditional. The name of the parent Service Bus Namespace for the Service Bus Topic. Required if the template is used in a standalone deployment." } }, "name": { "type": "string", - "maxLength": 50, "minLength": 6, + "maxLength": 50, "metadata": { "description": "Required. Name of the Service Bus Topic." } @@ -134,14 +137,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -242,9 +245,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12238459450385505191" - } + "version": "0.20.4.51522", + "templateHash": "12912382339345981506" + }, + "name": "Service Bus Namespace Topic Authorization Rules", + "description": "This module deploys a Service Bus Namespace Topic Authorization Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -372,8 +378,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18279135895049473482" + "version": "0.20.4.51522", + "templateHash": "11124682842627815351" } }, "parameters": { diff --git a/modules/service-fabric/cluster/application-type/main.json b/modules/service-fabric/cluster/application-type/main.json index 693784258f..4b21e5e00d 100644 --- a/modules/service-fabric/cluster/application-type/main.json +++ b/modules/service-fabric/cluster/application-type/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17377551140352908746" - } + "version": "0.20.4.51522", + "templateHash": "18125415207616023954" + }, + "name": "Service Fabric Cluster Application Types", + "description": "This module deploys a Service Fabric Cluster Application Type.", + "owner": "Azure/module-maintainers" }, "parameters": { "serviceFabricClusterName": { diff --git a/modules/service-fabric/cluster/main.json b/modules/service-fabric/cluster/main.json index 9b54db2feb..02d8422f70 100644 --- a/modules/service-fabric/cluster/main.json +++ b/modules/service-fabric/cluster/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4053406486831855406" - } + "version": "0.20.4.51522", + "templateHash": "15411420479083132968" + }, + "name": "Service Fabric Clusters", + "description": "This module deploys a Service Fabric Cluster.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -32,14 +35,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "enableDefaultTelemetry": { "type": "bool", @@ -51,15 +54,15 @@ "addOnFeatures": { "type": "array", "defaultValue": [], - "metadata": { - "description": "Optional. The list of add-on features to enable in the cluster." - }, "allowedValues": [ "BackupRestoreService", "DnsService", "RepairManager", "ResourceMonitorService" - ] + ], + "metadata": { + "description": "Optional. The list of add-on features to enable in the cluster." + } }, "maxUnusedVersionsToKeep": { "type": "int", @@ -159,16 +162,16 @@ }, "reliabilityLevel": { "type": "string", - "metadata": { - "description": "Required. The reliability level sets the replica set size of system services. Learn about ReliabilityLevel (https://learn.microsoft.com/en-us/azure/service-fabric/service-fabric-cluster-capacity). - None - Run the System services with a target replica set count of 1. This should only be used for test clusters. - Bronze - Run the System services with a target replica set count of 3. This should only be used for test clusters. - Silver - Run the System services with a target replica set count of 5. - Gold - Run the System services with a target replica set count of 7. - Platinum - Run the System services with a target replica set count of 9." - }, "allowedValues": [ "Bronze", "Gold", "None", "Platinum", "Silver" - ] + ], + "metadata": { + "description": "Required. The reliability level sets the replica set size of system services. Learn about ReliabilityLevel (https://learn.microsoft.com/en-us/azure/service-fabric/service-fabric-cluster-capacity). - None - Run the System services with a target replica set count of 1. This should only be used for test clusters. - Bronze - Run the System services with a target replica set count of 3. This should only be used for test clusters. - Silver - Run the System services with a target replica set count of 5. - Gold - Run the System services with a target replica set count of 7. - Platinum - Run the System services with a target replica set count of 9." + } }, "reverseProxyCertificate": { "type": "object", @@ -187,13 +190,13 @@ "sfZonalUpgradeMode": { "type": "string", "defaultValue": "Hierarchical", - "metadata": { - "description": "Optional. This property controls the logical grouping of VMs in upgrade domains (UDs). This property cannot be modified if a node type with multiple Availability Zones is already present in the cluster." - }, "allowedValues": [ "Hierarchical", "Parallel" - ] + ], + "metadata": { + "description": "Optional. This property controls the logical grouping of VMs in upgrade domains (UDs). This property cannot be modified if a node type with multiple Availability Zones is already present in the cluster." + } }, "upgradeDescription": { "type": "object", @@ -205,13 +208,13 @@ "upgradeMode": { "type": "string", "defaultValue": "Automatic", - "metadata": { - "description": "Optional. The upgrade mode of the cluster when new Service Fabric runtime version is available." - }, "allowedValues": [ "Automatic", "Manual" - ] + ], + "metadata": { + "description": "Optional. The upgrade mode of the cluster when new Service Fabric runtime version is available." + } }, "upgradePauseEndTimestampUtc": { "type": "string", @@ -230,14 +233,14 @@ "upgradeWave": { "type": "string", "defaultValue": "Wave0", - "metadata": { - "description": "Optional. Indicates when new cluster runtime version upgrades will be applied after they are released. By default is Wave0." - }, "allowedValues": [ "Wave0", "Wave1", "Wave2" - ] + ], + "metadata": { + "description": "Optional. Indicates when new cluster runtime version upgrades will be applied after they are released. By default is Wave0." + } }, "vmImage": { "type": "string", @@ -249,13 +252,13 @@ "vmssZonalUpgradeMode": { "type": "string", "defaultValue": "Hierarchical", - "metadata": { - "description": "Optional. This property defines the upgrade mode for the virtual machine scale set, it is mandatory if a node type with multiple Availability Zones is added." - }, "allowedValues": [ "Hierarchical", "Parallel" - ] + ], + "metadata": { + "description": "Optional. This property defines the upgrade mode for the virtual machine scale set, it is mandatory if a node type with multiple Availability Zones is added." + } }, "waveUpgradePaused": { "type": "bool", @@ -440,8 +443,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6315999366543720217" + "version": "0.20.4.51522", + "templateHash": "10133043076978827187" } }, "parameters": { @@ -585,9 +588,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "17377551140352908746" - } + "version": "0.20.4.51522", + "templateHash": "18125415207616023954" + }, + "name": "Service Fabric Cluster Application Types", + "description": "This module deploys a Service Fabric Cluster Application Type.", + "owner": "Azure/module-maintainers" }, "parameters": { "serviceFabricClusterName": { diff --git a/modules/signal-r-service/signal-r/.test/common/dependencies.bicep b/modules/signal-r-service/signal-r/.test/common/dependencies.bicep index 0513f6bca1..5cf708bce8 100644 --- a/modules/signal-r-service/signal-r/.test/common/dependencies.bicep +++ b/modules/signal-r-service/signal-r/.test/common/dependencies.bicep @@ -9,47 +9,47 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - privateEndpointNetworkPolicies: 'Disabled' - privateLinkServiceNetworkPolicies: 'Enabled' - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + privateEndpointNetworkPolicies: 'Disabled' + privateLinkServiceNetworkPolicies: 'Enabled' + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.service.signalr.net' - location: 'global' + name: 'privatelink.service.signalr.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/signal-r-service/signal-r/README.md b/modules/signal-r-service/signal-r/README.md index 48e46391ea..785260b5d4 100644 --- a/modules/signal-r-service/signal-r/README.md +++ b/modules/signal-r-service/signal-r/README.md @@ -16,8 +16,8 @@ This module deploys a SignalR Service SignalR. | :-- | :-- | | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | | `Microsoft.SignalRService/signalR` | [2022-02-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.SignalRService/2022-02-01/signalR) | ## Parameters diff --git a/modules/signal-r-service/signal-r/main.json b/modules/signal-r-service/signal-r/main.json index bd6d8ff40d..aba5584da3 100644 --- a/modules/signal-r-service/signal-r/main.json +++ b/modules/signal-r-service/signal-r/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15208270281641036717" - } + "version": "0.20.4.51522", + "templateHash": "15200712357875429742" + }, + "name": "SignalR Service SignalR", + "description": "This module deploys a SignalR Service SignalR.", + "owner": "Azure/module-maintainers" }, "parameters": { "location": { @@ -123,13 +126,13 @@ "ConnectivityLogs", "MessagingLogs" ], - "metadata": { - "description": "Optional. Control permission for data plane traffic coming from public networks while private endpoint is enabled." - }, "allowedValues": [ "ConnectivityLogs", "MessagingLogs" - ] + ], + "metadata": { + "description": "Optional. Control permission for data plane traffic coming from public networks while private endpoint is enabled." + } }, "resourceLogConfigurationsToEnable": { "type": "array", @@ -137,13 +140,13 @@ "ConnectivityLogs", "MessagingLogs" ], - "metadata": { - "description": "Optional. Control permission for data plane traffic coming from public networks while private endpoint is enabled." - }, "allowedValues": [ "ConnectivityLogs", "MessagingLogs" - ] + ], + "metadata": { + "description": "Optional. Control permission for data plane traffic coming from public networks while private endpoint is enabled." + } }, "clientCertEnabled": { "type": "bool", @@ -169,14 +172,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -318,9 +321,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -385,14 +391,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -450,7 +456,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -515,9 +521,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -528,8 +537,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -580,7 +589,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -650,8 +659,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -821,7 +830,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -864,8 +873,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11712391797872657680" + "version": "0.20.4.51522", + "templateHash": "9407968548081163481" } }, "parameters": { diff --git a/modules/signal-r-service/web-pub-sub/.test/common/dependencies.bicep b/modules/signal-r-service/web-pub-sub/.test/common/dependencies.bicep index 6364d0949a..d40d2ad8a9 100644 --- a/modules/signal-r-service/web-pub-sub/.test/common/dependencies.bicep +++ b/modules/signal-r-service/web-pub-sub/.test/common/dependencies.bicep @@ -9,47 +9,47 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - privateEndpointNetworkPolicies: 'Disabled' - privateLinkServiceNetworkPolicies: 'Enabled' - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + privateEndpointNetworkPolicies: 'Disabled' + privateLinkServiceNetworkPolicies: 'Enabled' + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.webpubsub.azure.com' - location: 'global' + name: 'privatelink.webpubsub.azure.com' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/signal-r-service/web-pub-sub/.test/pe/dependencies.bicep b/modules/signal-r-service/web-pub-sub/.test/pe/dependencies.bicep index 29920a4872..55a65a2d13 100644 --- a/modules/signal-r-service/web-pub-sub/.test/pe/dependencies.bicep +++ b/modules/signal-r-service/web-pub-sub/.test/pe/dependencies.bicep @@ -6,42 +6,42 @@ param virtualNetworkName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - privateEndpointNetworkPolicies: 'Disabled' - privateLinkServiceNetworkPolicies: 'Enabled' - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + privateEndpointNetworkPolicies: 'Disabled' + privateLinkServiceNetworkPolicies: 'Enabled' + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.webpubsub.azure.com' - location: 'global' + name: 'privatelink.webpubsub.azure.com' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/signal-r-service/web-pub-sub/README.md b/modules/signal-r-service/web-pub-sub/README.md index 115c84bf4a..6c51fca0fa 100644 --- a/modules/signal-r-service/web-pub-sub/README.md +++ b/modules/signal-r-service/web-pub-sub/README.md @@ -16,8 +16,8 @@ This module deploys a SignalR Web PubSub Service. | :-- | :-- | | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | | `Microsoft.SignalRService/webPubSub` | [2021-10-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.SignalRService/2021-10-01/webPubSub) | ## Parameters diff --git a/modules/signal-r-service/web-pub-sub/main.json b/modules/signal-r-service/web-pub-sub/main.json index 431f04c430..84bdca8575 100644 --- a/modules/signal-r-service/web-pub-sub/main.json +++ b/modules/signal-r-service/web-pub-sub/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6388256096661418872" - } + "version": "0.20.4.51522", + "templateHash": "1775613253607732073" + }, + "name": "SignalR Web PubSub Services", + "description": "This module deploys a SignalR Web PubSub Service.", + "owner": "Azure/module-maintainers" }, "parameters": { "location": { @@ -32,14 +35,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -65,13 +68,13 @@ "sku": { "type": "string", "defaultValue": "Standard_S1", - "metadata": { - "description": "Optional. Pricing tier of the resource." - }, "allowedValues": [ "Free_F1", "Standard_S1" - ] + ], + "metadata": { + "description": "Optional. Pricing tier of the resource." + } }, "systemAssignedIdentity": { "type": "bool", @@ -119,13 +122,13 @@ "ConnectivityLogs", "MessagingLogs" ], - "metadata": { - "description": "Optional. Control permission for data plane traffic coming from public networks while private endpoint is enabled." - }, "allowedValues": [ "ConnectivityLogs", "MessagingLogs" - ] + ], + "metadata": { + "description": "Optional. Control permission for data plane traffic coming from public networks while private endpoint is enabled." + } }, "clientCertEnabled": { "type": "bool", @@ -265,9 +268,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -332,14 +338,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -397,7 +403,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -462,9 +468,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -475,8 +484,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -527,7 +536,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -597,8 +606,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -768,7 +777,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -811,8 +820,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6961205066418197558" + "version": "0.20.4.51522", + "templateHash": "8465242993559126363" } }, "parameters": { diff --git a/modules/sql/managed-instance/.test/common/dependencies.bicep b/modules/sql/managed-instance/.test/common/dependencies.bicep index a128455cd5..57548e9739 100644 --- a/modules/sql/managed-instance/.test/common/dependencies.bicep +++ b/modules/sql/managed-instance/.test/common/dependencies.bicep @@ -19,7 +19,7 @@ param location string = resourceGroup().location var addressPrefix = '10.0.0.0/16' var addressPrefixString = replace(replace(addressPrefix, '.', '-'), '/', '-') -resource networkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2021-08-01' = { +resource networkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2023-04-01' = { name: networkSecurityGroupName location: location properties: { @@ -142,7 +142,7 @@ resource networkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2021-08-0 } } -resource routeTable 'Microsoft.Network/routeTables@2021-08-01' = { +resource routeTable 'Microsoft.Network/routeTables@2023-04-01' = { name: routeTableName location: location properties: { @@ -256,7 +256,7 @@ resource routeTable 'Microsoft.Network/routeTables@2021-08-01' = { } } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkName location: location properties: { diff --git a/modules/sql/managed-instance/.test/common/main.test.bicep b/modules/sql/managed-instance/.test/common/main.test.bicep index 7092da7e05..a57a422cc5 100644 --- a/modules/sql/managed-instance/.test/common/main.test.bicep +++ b/modules/sql/managed-instance/.test/common/main.test.bicep @@ -91,7 +91,6 @@ module testDeployment '../../main.bicep' = { name: '${namePrefix}-${serviceShort}-db-001' } ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/sql/managed-instance/.test/min/dependencies.bicep b/modules/sql/managed-instance/.test/min/dependencies.bicep index 0f5dc286b8..654889b0e9 100644 --- a/modules/sql/managed-instance/.test/min/dependencies.bicep +++ b/modules/sql/managed-instance/.test/min/dependencies.bicep @@ -13,7 +13,7 @@ param location string = resourceGroup().location var addressPrefix = '10.0.0.0/16' var addressPrefixString = replace(replace(addressPrefix, '.', '-'), '/', '-') -resource networkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2021-08-01' = { +resource networkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2023-04-01' = { name: networkSecurityGroupName location: location properties: { @@ -136,7 +136,7 @@ resource networkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2021-08-0 } } -resource routeTable 'Microsoft.Network/routeTables@2021-08-01' = { +resource routeTable 'Microsoft.Network/routeTables@2023-04-01' = { name: routeTableName location: location properties: { @@ -250,7 +250,7 @@ resource routeTable 'Microsoft.Network/routeTables@2021-08-01' = { } } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkName location: location properties: { diff --git a/modules/sql/managed-instance/README.md b/modules/sql/managed-instance/README.md index 8c731ac3e0..3404c33082 100644 --- a/modules/sql/managed-instance/README.md +++ b/modules/sql/managed-instance/README.md @@ -66,7 +66,6 @@ SQL MI allows for Azure AD Authentication via an [Azure AD Admin](https://learn. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, ResourceUsageStats, SQLSecurityAuditEvents]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -316,7 +315,6 @@ module managedInstance './sql/managed-instance/main.bicep' = { ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' dnsZonePartner: '' @@ -425,9 +423,6 @@ module managedInstance './sql/managed-instance/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/sql/managed-instance/administrator/main.json b/modules/sql/managed-instance/administrator/main.json index cc8441aaad..14523f5dc5 100644 --- a/modules/sql/managed-instance/administrator/main.json +++ b/modules/sql/managed-instance/administrator/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9014901880446223924" - } + "version": "0.20.4.51522", + "templateHash": "94742246961044490" + }, + "name": "SQL Managed Instances Administrator", + "description": "This module deploys a SQL Managed Instance Administrator.", + "owner": "Azure/module-maintainers" }, "parameters": { "managedInstanceName": { diff --git a/modules/sql/managed-instance/database/README.md b/modules/sql/managed-instance/database/README.md index f8928e44cb..b347af31a0 100644 --- a/modules/sql/managed-instance/database/README.md +++ b/modules/sql/managed-instance/database/README.md @@ -55,7 +55,6 @@ The SQL Managed Instance Database is deployed on a SQL Managed Instance. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, Errors, QueryStoreRuntimeStatistics, QueryStoreWaitStatistics, SQLInsights]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | | `diagnosticWorkspaceId` | string | `''` | | Resource ID of the diagnostic log analytics workspace. | diff --git a/modules/sql/managed-instance/database/backup-long-term-retention-policy/main.json b/modules/sql/managed-instance/database/backup-long-term-retention-policy/main.json index f2c932517d..46881cf93b 100644 --- a/modules/sql/managed-instance/database/backup-long-term-retention-policy/main.json +++ b/modules/sql/managed-instance/database/backup-long-term-retention-policy/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1033992501650214243" - } + "version": "0.20.4.51522", + "templateHash": "18038719600656297152" + }, + "name": "SQL Managed Instance Database Backup Long-Term Retention Policies", + "description": "This module deploys a SQL Managed Instance Database Backup Long-Term Retention Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/sql/managed-instance/database/backup-short-term-retention-policy/main.json b/modules/sql/managed-instance/database/backup-short-term-retention-policy/main.json index f205f95229..34f3bffae7 100644 --- a/modules/sql/managed-instance/database/backup-short-term-retention-policy/main.json +++ b/modules/sql/managed-instance/database/backup-short-term-retention-policy/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "339225421683905916" - } + "version": "0.20.4.51522", + "templateHash": "6931213919610871740" + }, + "name": "SQL Managed Instance Database Backup Short-Term Retention Policies", + "description": "This module deploys a SQL Managed Instance Database Backup Short-Term Retention Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/sql/managed-instance/database/main.bicep b/modules/sql/managed-instance/database/main.bicep index 0d7e0385f4..dd6a4914f3 100644 --- a/modules/sql/managed-instance/database/main.bicep +++ b/modules/sql/managed-instance/database/main.bicep @@ -48,11 +48,6 @@ param recoverableDatabaseId string = '' @description('Conditional. The resource ID of the Long Term Retention backup to be used for restore of this managed database. Required if createMode is RestoreLongTermRetentionBackup.') param longTermRetentionBackupResourceId string = '' -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -104,20 +99,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified diff --git a/modules/sql/managed-instance/database/main.json b/modules/sql/managed-instance/database/main.json index 0fda1cfbb5..03c72318d8 100644 --- a/modules/sql/managed-instance/database/main.json +++ b/modules/sql/managed-instance/database/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2497751269793012554" - } + "version": "0.20.4.51522", + "templateHash": "7819487658736647657" + }, + "name": "SQL Managed Instance Databases", + "description": "This module deploys a SQL Managed Instance Database.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -105,15 +108,6 @@ "description": "Conditional. The resource ID of the Long Term Retention backup to be used for restore of this managed database. Required if createMode is RestoreLongTermRetentionBackup." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -145,14 +139,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "backupShortTermRetentionPoliciesObj": { "type": "object", @@ -214,15 +208,11 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "enableReferencedModulesTelemetry": false }, "resources": [ @@ -321,9 +311,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "339225421683905916" - } + "version": "0.20.4.51522", + "templateHash": "6931213919610871740" + }, + "name": "SQL Managed Instance Database Backup Short-Term Retention Policies", + "description": "This module deploys a SQL Managed Instance Database Backup Short-Term Retention Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -446,9 +439,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1033992501650214243" - } + "version": "0.20.4.51522", + "templateHash": "18038719600656297152" + }, + "name": "SQL Managed Instance Database Backup Long-Term Retention Policies", + "description": "This module deploys a SQL Managed Instance Database Backup Long-Term Retention Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/sql/managed-instance/encryption-protector/main.json b/modules/sql/managed-instance/encryption-protector/main.json index d7d8868bcb..cc7d2dae7a 100644 --- a/modules/sql/managed-instance/encryption-protector/main.json +++ b/modules/sql/managed-instance/encryption-protector/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4491359307411111036" - } + "version": "0.20.4.51522", + "templateHash": "3596420230929102349" + }, + "name": "SQL Managed Instance Encryption Protector", + "description": "This module deploys a SQL Managed Instance Encryption Protector.", + "owner": "Azure/module-maintainers" }, "parameters": { "managedInstanceName": { diff --git a/modules/sql/managed-instance/key/main.json b/modules/sql/managed-instance/key/main.json index 2cebe28054..2a36cecd48 100644 --- a/modules/sql/managed-instance/key/main.json +++ b/modules/sql/managed-instance/key/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18086076605425313761" - } + "version": "0.20.4.51522", + "templateHash": "12303930012308222652" + }, + "name": "SQL Managed Instance Keys", + "description": "This module deploys a SQL Managed Instance Key.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/sql/managed-instance/main.bicep b/modules/sql/managed-instance/main.bicep index 8c6cde5714..4a134086db 100644 --- a/modules/sql/managed-instance/main.bicep +++ b/modules/sql/managed-instance/main.bicep @@ -86,11 +86,6 @@ param restorePointInTime string = '' @description('Optional. The resource identifier of the source managed instance associated with create operation of this instance.') param sourceManagedInstanceId string = '' -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -190,20 +185,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -211,10 +198,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var identityType = systemAssignedIdentity ? (!empty(userAssignedIdentities) ? 'SystemAssigned,UserAssigned' : 'SystemAssigned') : (!empty(userAssignedIdentities) ? 'UserAssigned' : 'None') @@ -317,7 +300,6 @@ module managedInstance_databases 'database/main.bicep' = [for (database, index) catalogCollation: contains(database, 'catalogCollation') ? database.catalogCollation : 'SQL_Latin1_General_CP1_CI_AS' collation: contains(database, 'collation') ? database.collation : 'SQL_Latin1_General_CP1_CI_AS' createMode: contains(database, 'createMode') ? database.createMode : 'Default' - diagnosticLogsRetentionInDays: contains(database, 'diagnosticLogsRetentionInDays') ? database.diagnosticLogsRetentionInDays : 365 diagnosticStorageAccountId: contains(database, 'diagnosticStorageAccountId') ? database.diagnosticStorageAccountId : '' diagnosticEventHubAuthorizationRuleId: contains(database, 'diagnosticEventHubAuthorizationRuleId') ? database.diagnosticEventHubAuthorizationRuleId : '' diagnosticEventHubName: contains(database, 'diagnosticEventHubName') ? database.diagnosticEventHubName : '' diff --git a/modules/sql/managed-instance/main.json b/modules/sql/managed-instance/main.json index 0ae2a77393..b9aba00b6b 100644 --- a/modules/sql/managed-instance/main.json +++ b/modules/sql/managed-instance/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9406931406845149664" - } + "version": "0.20.4.51522", + "templateHash": "225988996484492227" + }, + "name": "SQL Managed Instances", + "description": "This module deploys a SQL Managed Instance.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -176,15 +179,6 @@ "description": "Optional. The resource identifier of the source managed instance associated with create operation of this instance." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -216,14 +210,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -312,15 +306,15 @@ "minimalTlsVersion": { "type": "string", "defaultValue": "1.2", - "metadata": { - "description": "Optional. Minimal TLS version allowed." - }, "allowedValues": [ "None", "1.0", "1.1", "1.2" - ] + ], + "metadata": { + "description": "Optional. Minimal TLS version allowed." + } }, "requestedBackupStorageRedundancy": { "type": "string", @@ -377,11 +371,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -390,15 +380,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "identityType": "[if(parameters('systemAssignedIdentity'), if(not(empty(parameters('userAssignedIdentities'))), 'SystemAssigned,UserAssigned', 'SystemAssigned'), if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None'))]", "identity": "[if(not(equals(variables('identityType'), 'None')), createObject('type', variables('identityType'), 'userAssignedIdentities', if(not(empty(parameters('userAssignedIdentities'))), parameters('userAssignedIdentities'), null())), null())]", "enableReferencedModulesTelemetry": false @@ -521,8 +507,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2561429110475874953" + "version": "0.20.4.51522", + "templateHash": "10149117624574107754" } }, "parameters": { @@ -665,7 +651,6 @@ "catalogCollation": "[if(contains(parameters('databases')[copyIndex()], 'catalogCollation'), createObject('value', parameters('databases')[copyIndex()].catalogCollation), createObject('value', 'SQL_Latin1_General_CP1_CI_AS'))]", "collation": "[if(contains(parameters('databases')[copyIndex()], 'collation'), createObject('value', parameters('databases')[copyIndex()].collation), createObject('value', 'SQL_Latin1_General_CP1_CI_AS'))]", "createMode": "[if(contains(parameters('databases')[copyIndex()], 'createMode'), createObject('value', parameters('databases')[copyIndex()].createMode), createObject('value', 'Default'))]", - "diagnosticLogsRetentionInDays": "[if(contains(parameters('databases')[copyIndex()], 'diagnosticLogsRetentionInDays'), createObject('value', parameters('databases')[copyIndex()].diagnosticLogsRetentionInDays), createObject('value', 365))]", "diagnosticStorageAccountId": "[if(contains(parameters('databases')[copyIndex()], 'diagnosticStorageAccountId'), createObject('value', parameters('databases')[copyIndex()].diagnosticStorageAccountId), createObject('value', ''))]", "diagnosticEventHubAuthorizationRuleId": "[if(contains(parameters('databases')[copyIndex()], 'diagnosticEventHubAuthorizationRuleId'), createObject('value', parameters('databases')[copyIndex()].diagnosticEventHubAuthorizationRuleId), createObject('value', ''))]", "diagnosticEventHubName": "[if(contains(parameters('databases')[copyIndex()], 'diagnosticEventHubName'), createObject('value', parameters('databases')[copyIndex()].diagnosticEventHubName), createObject('value', ''))]", @@ -692,9 +677,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2497751269793012554" - } + "version": "0.20.4.51522", + "templateHash": "7819487658736647657" + }, + "name": "SQL Managed Instance Databases", + "description": "This module deploys a SQL Managed Instance Database.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -793,15 +781,6 @@ "description": "Conditional. The resource ID of the Long Term Retention backup to be used for restore of this managed database. Required if createMode is RestoreLongTermRetentionBackup." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -833,14 +812,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "backupShortTermRetentionPoliciesObj": { "type": "object", @@ -902,15 +881,11 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "enableReferencedModulesTelemetry": false }, "resources": [ @@ -1009,9 +984,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "339225421683905916" - } + "version": "0.20.4.51522", + "templateHash": "6931213919610871740" + }, + "name": "SQL Managed Instance Database Backup Short-Term Retention Policies", + "description": "This module deploys a SQL Managed Instance Database Backup Short-Term Retention Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1134,9 +1112,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1033992501650214243" - } + "version": "0.20.4.51522", + "templateHash": "18038719600656297152" + }, + "name": "SQL Managed Instance Database Backup Long-Term Retention Policies", + "description": "This module deploys a SQL Managed Instance Database Backup Long-Term Retention Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1315,9 +1296,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15446099956468179466" - } + "version": "0.20.4.51522", + "templateHash": "15021129035939475675" + }, + "name": "SQL Managed Instance Security Alert Policies", + "description": "This module deploys a SQL Managed Instance Security Alert Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1443,9 +1427,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15588092439096999066" - } + "version": "0.20.4.51522", + "templateHash": "6142359620217113835" + }, + "name": "SQL Managed Instance Vulnerability Assessments", + "description": "This module deploys a SQL Managed Instance Vulnerability Assessment.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1588,9 +1575,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18086076605425313761" - } + "version": "0.20.4.51522", + "templateHash": "12303930012308222652" + }, + "name": "SQL Managed Instance Keys", + "description": "This module deploys a SQL Managed Instance Key.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1718,9 +1708,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4491359307411111036" - } + "version": "0.20.4.51522", + "templateHash": "3596420230929102349" + }, + "name": "SQL Managed Instance Encryption Protector", + "description": "This module deploys a SQL Managed Instance Encryption Protector.", + "owner": "Azure/module-maintainers" }, "parameters": { "managedInstanceName": { @@ -1848,9 +1841,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9014901880446223924" - } + "version": "0.20.4.51522", + "templateHash": "94742246961044490" + }, + "name": "SQL Managed Instances Administrator", + "description": "This module deploys a SQL Managed Instance Administrator.", + "owner": "Azure/module-maintainers" }, "parameters": { "managedInstanceName": { diff --git a/modules/sql/managed-instance/security-alert-policy/main.json b/modules/sql/managed-instance/security-alert-policy/main.json index 801fb9b22b..04709674d0 100644 --- a/modules/sql/managed-instance/security-alert-policy/main.json +++ b/modules/sql/managed-instance/security-alert-policy/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15446099956468179466" - } + "version": "0.20.4.51522", + "templateHash": "15021129035939475675" + }, + "name": "SQL Managed Instance Security Alert Policies", + "description": "This module deploys a SQL Managed Instance Security Alert Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/sql/managed-instance/vulnerability-assessment/main.json b/modules/sql/managed-instance/vulnerability-assessment/main.json index 42eadb4b39..8ee0066897 100644 --- a/modules/sql/managed-instance/vulnerability-assessment/main.json +++ b/modules/sql/managed-instance/vulnerability-assessment/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15588092439096999066" - } + "version": "0.20.4.51522", + "templateHash": "6142359620217113835" + }, + "name": "SQL Managed Instance Vulnerability Assessments", + "description": "This module deploys a SQL Managed Instance Vulnerability Assessment.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/sql/server/.test/common/dependencies.bicep b/modules/sql/server/.test/common/dependencies.bicep index da6583678c..1b43ec16f9 100644 --- a/modules/sql/server/.test/common/dependencies.bicep +++ b/modules/sql/server/.test/common/dependencies.bicep @@ -15,7 +15,7 @@ resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018- location: location } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkName location: location properties: { diff --git a/modules/sql/server/.test/common/main.test.bicep b/modules/sql/server/.test/common/main.test.bicep index 3bf5dd351a..c2f61de647 100644 --- a/modules/sql/server/.test/common/main.test.bicep +++ b/modules/sql/server/.test/common/main.test.bicep @@ -113,7 +113,6 @@ module testDeployment '../../main.bicep' = { capacity: 0 maxSizeBytes: 34359738368 licenseType: 'LicenseIncluded' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/sql/server/.test/pe/dependencies.bicep b/modules/sql/server/.test/pe/dependencies.bicep index 03ec3c24c9..a4de98fde3 100644 --- a/modules/sql/server/.test/pe/dependencies.bicep +++ b/modules/sql/server/.test/pe/dependencies.bicep @@ -6,7 +6,7 @@ param location string = resourceGroup().location var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkName location: location properties: { diff --git a/modules/sql/server/README.md b/modules/sql/server/README.md index 9bfc041983..c9ab033556 100644 --- a/modules/sql/server/README.md +++ b/modules/sql/server/README.md @@ -17,8 +17,8 @@ This module deploys an Azure SQL Server. | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | | `Microsoft.Sql/servers` | [2022-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Sql/2022-05-01-preview/servers) | | `Microsoft.Sql/servers/databases` | [2021-11-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Sql/2021-11-01/servers/databases) | | `Microsoft.Sql/servers/databases/backupLongTermRetentionPolicies` | [2022-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Sql/2022-05-01-preview/servers/databases/backupLongTermRetentionPolicies) | @@ -457,7 +457,6 @@ module server './sql/server/main.bicep' = { collation: 'SQL_Latin1_General_CP1_CI_AS' diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' elasticPoolId: '' @@ -594,7 +593,6 @@ module server './sql/server/main.bicep' = { "collation": "SQL_Latin1_General_CP1_CI_AS", "diagnosticEventHubAuthorizationRuleId": "", "diagnosticEventHubName": "", - "diagnosticLogsRetentionInDays": 7, "diagnosticStorageAccountId": "", "diagnosticWorkspaceId": "", "elasticPoolId": "", diff --git a/modules/sql/server/database/README.md b/modules/sql/server/database/README.md index 27851faa12..6a7202d179 100644 --- a/modules/sql/server/database/README.md +++ b/modules/sql/server/database/README.md @@ -44,7 +44,6 @@ This module deploys an Azure SQL Server Database. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, AutomaticTuning, Blocks, DatabaseWaitStatistics, Deadlocks, DevOpsOperationsAudit, Errors, QueryStoreRuntimeStatistics, QueryStoreWaitStatistics, SQLInsights, SQLSecurityAuditEvents, Timeouts]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[Basic, InstanceAndAppAdvanced, WorkloadManagement]` | `[Basic, InstanceAndAppAdvanced, WorkloadManagement]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | diff --git a/modules/sql/server/database/backup-long-term-retention-policy/main.json b/modules/sql/server/database/backup-long-term-retention-policy/main.json index 870a7044d2..0519d9c583 100644 --- a/modules/sql/server/database/backup-long-term-retention-policy/main.json +++ b/modules/sql/server/database/backup-long-term-retention-policy/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "576440200700805719" - } + "version": "0.20.4.51522", + "templateHash": "9219416659486760074" + }, + "name": "SQL Server Database Long Term Backup Retention Policies", + "description": "This module deploys an Azure SQL Server Database Long-Term Backup Retention Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "serverName": { diff --git a/modules/sql/server/database/backup-short-term-retention-policy/main.json b/modules/sql/server/database/backup-short-term-retention-policy/main.json index 00ee1578fd..50bb545bd8 100644 --- a/modules/sql/server/database/backup-short-term-retention-policy/main.json +++ b/modules/sql/server/database/backup-short-term-retention-policy/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1755178001864653280" - } + "version": "0.20.4.51522", + "templateHash": "2184125360304496486" + }, + "name": "Azure SQL Server Database Short Term Backup Retention Policies", + "description": "This module deploys an Azure SQL Server Database Short-Term Backup Retention Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "serverName": { diff --git a/modules/sql/server/database/main.bicep b/modules/sql/server/database/main.bicep index 1a5c603171..d41562b0be 100644 --- a/modules/sql/server/database/main.bicep +++ b/modules/sql/server/database/main.bicep @@ -66,11 +66,6 @@ param location string = resourceGroup().location @description('Optional. Enable telemetry via a Globally Unique Identifier (GUID).') param enableDefaultTelemetry bool = true -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -146,20 +141,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -167,10 +154,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] @description('Optional. The storage account type to be used to store backups for this database.') diff --git a/modules/sql/server/database/main.json b/modules/sql/server/database/main.json index 6c171f0d59..d1f5ef5b28 100644 --- a/modules/sql/server/database/main.json +++ b/modules/sql/server/database/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "2441534246604708690" - } + "version": "0.20.4.51522", + "templateHash": "641387093656497816" + }, + "name": "SQL Server Database", + "description": "This module deploys an Azure SQL Server Database.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -151,15 +154,6 @@ "description": "Optional. Enable telemetry via a Globally Unique Identifier (GUID)." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -329,11 +323,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -342,15 +332,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "skuVar": "[union(createObject('name', parameters('skuName'), 'tier', parameters('skuTier')), if(not(equals(parameters('skuCapacity'), -1)), createObject('capacity', parameters('skuCapacity')), if(not(empty(parameters('skuFamily'))), createObject('family', parameters('skuFamily')), if(not(empty(parameters('skuSize'))), createObject('size', parameters('skuSize')), createObject()))))]" }, "resources": [ @@ -439,9 +425,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1755178001864653280" - } + "version": "0.20.4.51522", + "templateHash": "2184125360304496486" + }, + "name": "Azure SQL Server Database Short Term Backup Retention Policies", + "description": "This module deploys an Azure SQL Server Database Short-Term Backup Retention Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "serverName": { @@ -559,9 +548,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "576440200700805719" - } + "version": "0.20.4.51522", + "templateHash": "9219416659486760074" + }, + "name": "SQL Server Database Long Term Backup Retention Policies", + "description": "This module deploys an Azure SQL Server Database Long-Term Backup Retention Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "serverName": { diff --git a/modules/sql/server/elastic-pool/main.json b/modules/sql/server/elastic-pool/main.json index e04bf05847..4eca83e47a 100644 --- a/modules/sql/server/elastic-pool/main.json +++ b/modules/sql/server/elastic-pool/main.json @@ -4,8 +4,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14041762700980122813" + "version": "0.20.4.51522", + "templateHash": "7347226856045672059" }, "name": "SQL Server Elastic Pool", "description": "This module deploys an Azure SQL Server Elastic Pool.", diff --git a/modules/sql/server/encryption-protector/main.json b/modules/sql/server/encryption-protector/main.json index 2ab88ea704..17c94ae4d0 100644 --- a/modules/sql/server/encryption-protector/main.json +++ b/modules/sql/server/encryption-protector/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9944810154683397466" - } + "version": "0.20.4.51522", + "templateHash": "14781745235892971560" + }, + "name": "Azure SQL Server Encryption Protector", + "description": "This module deploys an Azure SQL Server Encryption Protector.", + "owner": "Azure/module-maintainers" }, "parameters": { "sqlServerName": { diff --git a/modules/sql/server/firewall-rule/main.json b/modules/sql/server/firewall-rule/main.json index 866611a909..352001c934 100644 --- a/modules/sql/server/firewall-rule/main.json +++ b/modules/sql/server/firewall-rule/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8148253719195728510" - } + "version": "0.20.4.51522", + "templateHash": "3172947896499441492" + }, + "name": "Azure SQL Server Firewall Rule", + "description": "This module deploys an Azure SQL Server Firewall Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/sql/server/key/main.json b/modules/sql/server/key/main.json index 3fbf3e9b5c..6f88f16d58 100644 --- a/modules/sql/server/key/main.json +++ b/modules/sql/server/key/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4660497923219314534" - } + "version": "0.20.4.51522", + "templateHash": "17103037079550179702" + }, + "name": "Azure SQL Server Keys", + "description": "This module deploys an Azure SQL Server Key.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/sql/server/main.bicep b/modules/sql/server/main.bicep index 1ca0ad825f..8040667bb8 100644 --- a/modules/sql/server/main.bicep +++ b/modules/sql/server/main.bicep @@ -175,7 +175,6 @@ module server_databases 'database/main.bicep' = [for (database, index) in databa collation: contains(database, 'collation') ? database.collation : 'SQL_Latin1_General_CP1_CI_AS' maxSizeBytes: contains(database, 'maxSizeBytes') ? database.maxSizeBytes : 34359738368 autoPauseDelay: contains(database, 'autoPauseDelay') ? database.autoPauseDelay : 0 - diagnosticLogsRetentionInDays: contains(database, 'diagnosticLogsRetentionInDays') ? database.diagnosticLogsRetentionInDays : 365 diagnosticStorageAccountId: contains(database, 'diagnosticStorageAccountId') ? database.diagnosticStorageAccountId : '' diagnosticEventHubAuthorizationRuleId: contains(database, 'diagnosticEventHubAuthorizationRuleId') ? database.diagnosticEventHubAuthorizationRuleId : '' diagnosticEventHubName: contains(database, 'diagnosticEventHubName') ? database.diagnosticEventHubName : '' diff --git a/modules/sql/server/main.json b/modules/sql/server/main.json index 6a2591816a..e7b17b1d74 100644 --- a/modules/sql/server/main.json +++ b/modules/sql/server/main.json @@ -4,8 +4,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5853874786863085184" + "version": "0.20.4.51522", + "templateHash": "8349737255843318984" }, "name": "Azure SQL Servers", "description": "This module deploys an Azure SQL Server.", @@ -63,14 +63,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -145,14 +145,14 @@ "minimalTlsVersion": { "type": "string", "defaultValue": "1.2", - "metadata": { - "description": "Optional. Minimal TLS version allowed." - }, "allowedValues": [ "1.0", "1.1", "1.2" - ] + ], + "metadata": { + "description": "Optional. Minimal TLS version allowed." + } }, "privateEndpoints": { "type": "array", @@ -286,8 +286,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11734881635068469130" + "version": "0.20.4.51522", + "templateHash": "1461341384275935998" } }, "parameters": { @@ -435,7 +435,6 @@ "collation": "[if(contains(parameters('databases')[copyIndex()], 'collation'), createObject('value', parameters('databases')[copyIndex()].collation), createObject('value', 'SQL_Latin1_General_CP1_CI_AS'))]", "maxSizeBytes": "[if(contains(parameters('databases')[copyIndex()], 'maxSizeBytes'), createObject('value', parameters('databases')[copyIndex()].maxSizeBytes), createObject('value', json('34359738368')))]", "autoPauseDelay": "[if(contains(parameters('databases')[copyIndex()], 'autoPauseDelay'), createObject('value', parameters('databases')[copyIndex()].autoPauseDelay), createObject('value', 0))]", - "diagnosticLogsRetentionInDays": "[if(contains(parameters('databases')[copyIndex()], 'diagnosticLogsRetentionInDays'), createObject('value', parameters('databases')[copyIndex()].diagnosticLogsRetentionInDays), createObject('value', 365))]", "diagnosticStorageAccountId": "[if(contains(parameters('databases')[copyIndex()], 'diagnosticStorageAccountId'), createObject('value', parameters('databases')[copyIndex()].diagnosticStorageAccountId), createObject('value', ''))]", "diagnosticEventHubAuthorizationRuleId": "[if(contains(parameters('databases')[copyIndex()], 'diagnosticEventHubAuthorizationRuleId'), createObject('value', parameters('databases')[copyIndex()].diagnosticEventHubAuthorizationRuleId), createObject('value', ''))]", "diagnosticEventHubName": "[if(contains(parameters('databases')[copyIndex()], 'diagnosticEventHubName'), createObject('value', parameters('databases')[copyIndex()].diagnosticEventHubName), createObject('value', ''))]", @@ -474,8 +473,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3305351665095569664" + "version": "0.20.4.51522", + "templateHash": "641387093656497816" }, "name": "SQL Server Database", "description": "This module deploys an Azure SQL Server Database.", @@ -624,15 +623,6 @@ "description": "Optional. Enable telemetry via a Globally Unique Identifier (GUID)." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -802,11 +792,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -815,15 +801,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "skuVar": "[union(createObject('name', parameters('skuName'), 'tier', parameters('skuTier')), if(not(equals(parameters('skuCapacity'), -1)), createObject('capacity', parameters('skuCapacity')), if(not(empty(parameters('skuFamily'))), createObject('family', parameters('skuFamily')), if(not(empty(parameters('skuSize'))), createObject('size', parameters('skuSize')), createObject()))))]" }, "resources": [ @@ -912,8 +894,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5781184315991648600" + "version": "0.20.4.51522", + "templateHash": "2184125360304496486" }, "name": "Azure SQL Server Database Short Term Backup Retention Policies", "description": "This module deploys an Azure SQL Server Database Short-Term Backup Retention Policy.", @@ -1035,8 +1017,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9549304898342154380" + "version": "0.20.4.51522", + "templateHash": "9219416659486760074" }, "name": "SQL Server Database Long Term Backup Retention Policies", "description": "This module deploys an Azure SQL Server Database Long-Term Backup Retention Policy.", @@ -1230,8 +1212,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14041762700980122813" + "version": "0.20.4.51522", + "templateHash": "7347226856045672059" }, "name": "SQL Server Elastic Pool", "description": "This module deploys an Azure SQL Server Elastic Pool.", @@ -1477,8 +1459,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15343651026946310931" + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" }, "name": "Private Endpoints", "description": "This module deploys a Private Endpoint.", @@ -1547,14 +1529,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -1612,7 +1594,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -1677,8 +1659,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5406224106432076575" + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" }, "name": "Private Endpoint Private DNS Zone Groups", "description": "This module deploys a Private Endpoint Private DNS Zone Group.", @@ -1693,8 +1675,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -1745,7 +1727,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -1815,8 +1797,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -1986,7 +1968,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -2027,8 +2009,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13046035125440131345" + "version": "0.20.4.51522", + "templateHash": "3172947896499441492" }, "name": "Azure SQL Server Firewall Rule", "description": "This module deploys an Azure SQL Server Firewall Rule.", @@ -2157,8 +2139,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13392552360231460813" + "version": "0.20.4.51522", + "templateHash": "8465167845638762436" }, "name": "Azure SQL Server Virtual Network Rules", "description": "This module deploys an Azure SQL Server Virtual Network Rule.", @@ -2289,8 +2271,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9867242417767715059" + "version": "0.20.4.51522", + "templateHash": "15954751031444198635" }, "name": "Azure SQL Server Security Alert Policies", "description": "This module deploys an Azure SQL Server Security Alert Policy.", @@ -2460,8 +2442,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "632874859253022186" + "version": "0.20.4.51522", + "templateHash": "13755079853951277921" }, "name": "Azure SQL Server Vulnerability Assessments", "description": "This module deploys an Azure SQL Server Vulnerability Assessment.", @@ -2608,8 +2590,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10441220163352980152" + "version": "0.20.4.51522", + "templateHash": "17103037079550179702" }, "name": "Azure SQL Server Keys", "description": "This module deploys an Azure SQL Server Key.", @@ -2741,8 +2723,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4641134195716494602" + "version": "0.20.4.51522", + "templateHash": "14781745235892971560" }, "name": "Azure SQL Server Encryption Protector", "description": "This module deploys an Azure SQL Server Encryption Protector.", diff --git a/modules/sql/server/security-alert-policy/main.json b/modules/sql/server/security-alert-policy/main.json index 0194726292..6855d265d5 100644 --- a/modules/sql/server/security-alert-policy/main.json +++ b/modules/sql/server/security-alert-policy/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6023076096170709835" - } + "version": "0.20.4.51522", + "templateHash": "15954751031444198635" + }, + "name": "Azure SQL Server Security Alert Policies", + "description": "This module deploys an Azure SQL Server Security Alert Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/sql/server/virtual-network-rule/main.json b/modules/sql/server/virtual-network-rule/main.json index fc98a9e083..e2db4b658a 100644 --- a/modules/sql/server/virtual-network-rule/main.json +++ b/modules/sql/server/virtual-network-rule/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4935102343270424456" - } + "version": "0.20.4.51522", + "templateHash": "8465167845638762436" + }, + "name": "Azure SQL Server Virtual Network Rules", + "description": "This module deploys an Azure SQL Server Virtual Network Rule.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/sql/server/vulnerability-assessment/main.json b/modules/sql/server/vulnerability-assessment/main.json index 987803b62e..200a3baedf 100644 --- a/modules/sql/server/vulnerability-assessment/main.json +++ b/modules/sql/server/vulnerability-assessment/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10304286846050150356" - } + "version": "0.20.4.51522", + "templateHash": "13755079853951277921" + }, + "name": "Azure SQL Server Vulnerability Assessments", + "description": "This module deploys an Azure SQL Server Vulnerability Assessment.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/storage/storage-account/.test/common/dependencies.bicep b/modules/storage/storage-account/.test/common/dependencies.bicep index d130bdb97d..01486110b4 100644 --- a/modules/storage/storage-account/.test/common/dependencies.bicep +++ b/modules/storage/storage-account/.test/common/dependencies.bicep @@ -9,50 +9,50 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] + } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + serviceEndpoints: [ { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - serviceEndpoints: [ - { - service: 'Microsoft.Storage' - } - ] - } + service: 'Microsoft.Storage' } - ] - } + ] + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.blob.${environment().suffixes.storage}' - location: 'global' + name: 'privatelink.blob.${environment().suffixes.storage}' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/storage/storage-account/.test/common/main.test.bicep b/modules/storage/storage-account/.test/common/main.test.bicep index f8d5c0bc59..7368878fdc 100644 --- a/modules/storage/storage-account/.test/common/main.test.bicep +++ b/modules/storage/storage-account/.test/common/main.test.bicep @@ -121,7 +121,7 @@ module testDeployment '../../main.bicep' = { } ] blobServices: { - diagnosticLogsRetentionInDays: 7 + lastAccessTimeTrackingPolicyEnabled: true diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId @@ -160,7 +160,6 @@ module testDeployment '../../main.bicep' = { deleteRetentionPolicyDays: 9 } fileServices: { - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId @@ -187,7 +186,6 @@ module testDeployment '../../main.bicep' = { ] } tableServices: { - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId @@ -198,7 +196,6 @@ module testDeployment '../../main.bicep' = { ] } queueServices: { - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId @@ -240,11 +237,44 @@ module testDeployment '../../main.bicep' = { principalType: 'ServicePrincipal' } ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diagnosticEventHubName: diagnosticDependencies.outputs.eventHubNamespaceEventHubName + managementPolicyRules: [ + { + enabled: true + name: 'FirstRule' + type: 'Lifecycle' + definition: { + actions: { + baseBlob: { + delete: { + daysAfterModificationGreaterThan: 30 + } + tierToCool: { + daysAfterLastAccessTimeGreaterThan: 5 + } + } + } + filters: { + blobIndexMatch: [ + { + name: 'BlobIndex' + op: '==' + value: '1' + } + ] + blobTypes: [ + 'blockBlob' + ] + prefixMatch: [ + 'sample-container/log' + ] + } + } + } + ] tags: { Environment: 'Non-Prod' Role: 'DeploymentValidation' diff --git a/modules/storage/storage-account/.test/encr/dependencies.bicep b/modules/storage/storage-account/.test/encr/dependencies.bicep index 6dc0c63aaf..55eb94649e 100644 --- a/modules/storage/storage-account/.test/encr/dependencies.bicep +++ b/modules/storage/storage-account/.test/encr/dependencies.bicep @@ -13,85 +13,85 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' resource keyVault 'Microsoft.KeyVault/vaults@2022-07-01' = { - name: keyVaultName - location: location - properties: { - sku: { - family: 'A' - name: 'standard' - } - tenantId: tenant().tenantId - enablePurgeProtection: true - softDeleteRetentionInDays: 7 - enabledForTemplateDeployment: true - enabledForDiskEncryption: true - enabledForDeployment: true - enableRbacAuthorization: true - accessPolicies: [] + name: keyVaultName + location: location + properties: { + sku: { + family: 'A' + name: 'standard' } - - resource key 'keys@2022-07-01' = { - name: 'keyEncryptionKey' - properties: { - kty: 'RSA' - } + tenantId: tenant().tenantId + enablePurgeProtection: true + softDeleteRetentionInDays: 7 + enabledForTemplateDeployment: true + enabledForDiskEncryption: true + enabledForDeployment: true + enableRbacAuthorization: true + accessPolicies: [] + } + + resource key 'keys@2022-07-01' = { + name: 'keyEncryptionKey' + properties: { + kty: 'RSA' } + } } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] + } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + serviceEndpoints: [ { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - serviceEndpoints: [ - { - service: 'Microsoft.Storage' - } - ] - } + service: 'Microsoft.Storage' } - ] - } + ] + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.blob.${environment().suffixes.storage}' - location: 'global' + name: 'privatelink.blob.${environment().suffixes.storage}' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource keyPermissions 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid('msi-${keyVault::key.id}-${location}-${managedIdentity.id}-KeyVault-Reader-RoleAssignment.') - scope: keyVault::key - properties: { - principalId: managedIdentity.properties.principalId - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '12338af0-0e69-4776-bea7-57ae8d297424') // Key Vault Crypto User - principalType: 'ServicePrincipal' - } + name: guid('msi-${keyVault::key.id}-${location}-${managedIdentity.id}-KeyVault-Reader-RoleAssignment.') + scope: keyVault::key + properties: { + principalId: managedIdentity.properties.principalId + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '12338af0-0e69-4776-bea7-57ae8d297424') // Key Vault Crypto User + principalType: 'ServicePrincipal' + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/storage/storage-account/.test/nfs/main.test.bicep b/modules/storage/storage-account/.test/nfs/main.test.bicep index 57712eb4e4..aea547019d 100644 --- a/modules/storage/storage-account/.test/nfs/main.test.bicep +++ b/modules/storage/storage-account/.test/nfs/main.test.bicep @@ -89,7 +89,6 @@ module testDeployment '../../main.bicep' = { principalType: 'ServicePrincipal' } ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/storage/storage-account/README.md b/modules/storage/storage-account/README.md index bbd996d2fc..0ba330d1bd 100644 --- a/modules/storage/storage-account/README.md +++ b/modules/storage/storage-account/README.md @@ -18,8 +18,8 @@ This module deploys a Storage Account. | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | | `Microsoft.Storage/storageAccounts` | [2022-09-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Storage/2022-09-01/storageAccounts) | | `Microsoft.Storage/storageAccounts/blobServices` | [2022-09-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Storage/2022-09-01/storageAccounts/blobServices) | | `Microsoft.Storage/storageAccounts/blobServices/containers` | [2022-09-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Storage/2022-09-01/storageAccounts/blobServices/containers) | @@ -27,7 +27,7 @@ This module deploys a Storage Account. | `Microsoft.Storage/storageAccounts/fileServices` | [2021-09-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Storage/2021-09-01/storageAccounts/fileServices) | | `Microsoft.Storage/storageAccounts/fileServices/shares` | [2021-09-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Storage/2021-09-01/storageAccounts/fileServices/shares) | | `Microsoft.Storage/storageAccounts/localUsers` | [2022-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Storage/2022-05-01/storageAccounts/localUsers) | -| `Microsoft.Storage/storageAccounts/managementPolicies` | [2021-09-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Storage/2021-09-01/storageAccounts/managementPolicies) | +| `Microsoft.Storage/storageAccounts/managementPolicies` | [2023-01-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Storage/storageAccounts/managementPolicies) | | `Microsoft.Storage/storageAccounts/queueServices` | [2021-09-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Storage/2021-09-01/storageAccounts/queueServices) | | `Microsoft.Storage/storageAccounts/queueServices/queues` | [2021-09-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Storage/2021-09-01/storageAccounts/queueServices/queues) | | `Microsoft.Storage/storageAccounts/tableServices` | [2021-09-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Storage/2021-09-01/storageAccounts/tableServices) | @@ -67,7 +67,6 @@ This module deploys a Storage Account. | `defaultToOAuthAuthentication` | bool | `False` | | A boolean flag which indicates whether the default authentication is OAuth or not. | | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[Transaction]` | `[Transaction]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -468,13 +467,12 @@ module storageAccount './storage/storage-account/main.bicep' = { deleteRetentionPolicyEnabled: true diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' + lastAccessTimeTrackingPolicyEnabled: true } diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -484,7 +482,6 @@ module storageAccount './storage/storage-account/main.bicep' = { fileServices: { diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' shares: [ @@ -527,6 +524,40 @@ module storageAccount './storage/storage-account/main.bicep' = { } ] lock: 'CanNotDelete' + managementPolicyRules: [ + { + definition: { + actions: { + baseBlob: { + delete: { + daysAfterModificationGreaterThan: 30 + } + tierToCool: { + daysAfterLastAccessTimeGreaterThan: 5 + } + } + } + filters: { + blobIndexMatch: [ + { + name: 'BlobIndex' + op: '==' + value: '1' + } + ] + blobTypes: [ + 'blockBlob' + ] + prefixMatch: [ + 'sample-container/log' + ] + } + } + enabled: true + name: 'FirstRule' + type: 'Lifecycle' + } + ] networkAcls: { bypass: 'AzureServices' defaultAction: 'Deny' @@ -561,7 +592,6 @@ module storageAccount './storage/storage-account/main.bicep' = { queueServices: { diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' queues: [ @@ -603,7 +633,6 @@ module storageAccount './storage/storage-account/main.bicep' = { tableServices: { diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' tables: [ @@ -678,9 +707,9 @@ module storageAccount './storage/storage-account/main.bicep' = { "deleteRetentionPolicyEnabled": true, "diagnosticEventHubAuthorizationRuleId": "", "diagnosticEventHubName": "", - "diagnosticLogsRetentionInDays": 7, "diagnosticStorageAccountId": "", - "diagnosticWorkspaceId": "" + "diagnosticWorkspaceId": "", + "lastAccessTimeTrackingPolicyEnabled": true } }, "diagnosticEventHubAuthorizationRuleId": { @@ -689,9 +718,6 @@ module storageAccount './storage/storage-account/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, @@ -714,7 +740,6 @@ module storageAccount './storage/storage-account/main.bicep' = { "value": { "diagnosticEventHubAuthorizationRuleId": "", "diagnosticEventHubName": "", - "diagnosticLogsRetentionInDays": 7, "diagnosticStorageAccountId": "", "diagnosticWorkspaceId": "", "shares": [ @@ -764,6 +789,42 @@ module storageAccount './storage/storage-account/main.bicep' = { "lock": { "value": "CanNotDelete" }, + "managementPolicyRules": { + "value": [ + { + "definition": { + "actions": { + "baseBlob": { + "delete": { + "daysAfterModificationGreaterThan": 30 + }, + "tierToCool": { + "daysAfterLastAccessTimeGreaterThan": 5 + } + } + }, + "filters": { + "blobIndexMatch": [ + { + "name": "BlobIndex", + "op": "==", + "value": "1" + } + ], + "blobTypes": [ + "blockBlob" + ], + "prefixMatch": [ + "sample-container/log" + ] + } + }, + "enabled": true, + "name": "FirstRule", + "type": "Lifecycle" + } + ] + }, "networkAcls": { "value": { "bypass": "AzureServices", @@ -803,7 +864,6 @@ module storageAccount './storage/storage-account/main.bicep' = { "value": { "diagnosticEventHubAuthorizationRuleId": "", "diagnosticEventHubName": "", - "diagnosticLogsRetentionInDays": 7, "diagnosticStorageAccountId": "", "diagnosticWorkspaceId": "", "queues": [ @@ -857,7 +917,6 @@ module storageAccount './storage/storage-account/main.bicep' = { "value": { "diagnosticEventHubAuthorizationRuleId": "", "diagnosticEventHubName": "", - "diagnosticLogsRetentionInDays": 7, "diagnosticStorageAccountId": "", "diagnosticWorkspaceId": "", "tables": [ @@ -1116,7 +1175,6 @@ module storageAccount './storage/storage-account/main.bicep' = { allowBlobPublicAccess: false diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -1179,9 +1237,6 @@ module storageAccount './storage/storage-account/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/storage/storage-account/blob-service/README.md b/modules/storage/storage-account/blob-service/README.md index 4a2cd4ae63..b0c44ced78 100644 --- a/modules/storage/storage-account/blob-service/README.md +++ b/modules/storage/storage-account/blob-service/README.md @@ -46,14 +46,13 @@ This module deploys a Storage Account Blob Service. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, StorageDelete, StorageRead, StorageWrite]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[Transaction]` | `[Transaction]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | | `diagnosticWorkspaceId` | string | `''` | | Resource ID of a log analytics workspace. | | `enableDefaultTelemetry` | bool | `True` | | Enable telemetry via a Globally Unique Identifier (GUID). | | `isVersioningEnabled` | bool | `True` | | Use versioning to automatically maintain previous versions of your blobs. | -| `lastAccessTimeTrackingPolicyEnable` | bool | `False` | | The blob service property to configure last access time based tracking policy. When set to true last access time based tracking is enabled. | +| `lastAccessTimeTrackingPolicyEnabled` | bool | `False` | | The blob service property to configure last access time based tracking policy. When set to true last access time based tracking is enabled. | | `restorePolicyDays` | int | `6` | | how long this blob can be restored. It should be less than DeleteRetentionPolicy days. | | `restorePolicyEnabled` | bool | `True` | | The blob service properties for blob restore policy. If point-in-time restore is enabled, then versioning, change feed, and blob soft delete must also be enabled. | diff --git a/modules/storage/storage-account/blob-service/main.bicep b/modules/storage/storage-account/blob-service/main.bicep index 6498194fb8..aaca3f7025 100644 --- a/modules/storage/storage-account/blob-service/main.bicep +++ b/modules/storage/storage-account/blob-service/main.bicep @@ -49,7 +49,7 @@ param deleteRetentionPolicyAllowPermanentDelete bool = false param isVersioningEnabled bool = true @description('Optional. The blob service property to configure last access time based tracking policy. When set to true last access time based tracking is enabled.') -param lastAccessTimeTrackingPolicyEnable bool = false +param lastAccessTimeTrackingPolicyEnabled bool = false @description('Optional. The blob service properties for blob restore policy. If point-in-time restore is enabled, then versioning, change feed, and blob soft delete must also be enabled.') param restorePolicyEnabled bool = true @@ -61,11 +61,6 @@ param restorePolicyDays int = 6 @description('Optional. Blob containers to create.') param containers array = [] -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -110,20 +105,12 @@ var name = 'default' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -131,10 +118,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var enableReferencedModulesTelemetry = false @@ -180,9 +163,9 @@ resource blobServices 'Microsoft.Storage/storageAccounts/blobServices@2022-09-01 } isVersioningEnabled: isVersioningEnabled lastAccessTimeTrackingPolicy: { - enable: lastAccessTimeTrackingPolicyEnable - name: lastAccessTimeTrackingPolicyEnable == true ? 'AccessTimeTracking' : null - trackingGranularityInDays: lastAccessTimeTrackingPolicyEnable == true ? 1 : null + enable: lastAccessTimeTrackingPolicyEnabled + name: lastAccessTimeTrackingPolicyEnabled == true ? 'AccessTimeTracking' : null + trackingGranularityInDays: lastAccessTimeTrackingPolicyEnabled == true ? 1 : null } restorePolicy: { enabled: restorePolicyEnabled diff --git a/modules/storage/storage-account/blob-service/main.json b/modules/storage/storage-account/blob-service/main.json index 80c1930298..49c255f2fa 100644 --- a/modules/storage/storage-account/blob-service/main.json +++ b/modules/storage/storage-account/blob-service/main.json @@ -5,7 +5,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "1395192341429097070" + "templateHash": "16838270897726250953" }, "name": "Storage Account blob Services", "description": "This module deploys a Storage Account Blob Service.", @@ -109,7 +109,7 @@ "description": "Optional. Use versioning to automatically maintain previous versions of your blobs." } }, - "lastAccessTimeTrackingPolicyEnable": { + "lastAccessTimeTrackingPolicyEnabled": { "type": "bool", "defaultValue": false, "metadata": { @@ -138,15 +138,6 @@ "description": "Optional. Blob containers to create." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "minValue": 0, - "maxValue": 365, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -225,11 +216,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -238,16 +225,12 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], "name": "default", - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "enableReferencedModulesTelemetry": false }, "resources": [ @@ -291,9 +274,9 @@ }, "isVersioningEnabled": "[parameters('isVersioningEnabled')]", "lastAccessTimeTrackingPolicy": { - "enable": "[parameters('lastAccessTimeTrackingPolicyEnable')]", - "name": "[if(equals(parameters('lastAccessTimeTrackingPolicyEnable'), true()), 'AccessTimeTracking', null())]", - "trackingGranularityInDays": "[if(equals(parameters('lastAccessTimeTrackingPolicyEnable'), true()), 1, null())]" + "enable": "[parameters('lastAccessTimeTrackingPolicyEnabled')]", + "name": "[if(equals(parameters('lastAccessTimeTrackingPolicyEnabled'), true()), 'AccessTimeTracking', null())]", + "trackingGranularityInDays": "[if(equals(parameters('lastAccessTimeTrackingPolicyEnabled'), true()), 1, null())]" }, "restorePolicy": { "enabled": "[parameters('restorePolicyEnabled')]", diff --git a/modules/storage/storage-account/file-service/README.md b/modules/storage/storage-account/file-service/README.md index a85bba06bf..5ccef9ca69 100644 --- a/modules/storage/storage-account/file-service/README.md +++ b/modules/storage/storage-account/file-service/README.md @@ -33,7 +33,6 @@ This module deploys a Storage Account File Share Service. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, StorageDelete, StorageRead, StorageWrite]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[Transaction]` | `[Transaction]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | diff --git a/modules/storage/storage-account/file-service/main.bicep b/modules/storage/storage-account/file-service/main.bicep index e66a526b14..49d27c4715 100644 --- a/modules/storage/storage-account/file-service/main.bicep +++ b/modules/storage/storage-account/file-service/main.bicep @@ -18,11 +18,6 @@ param shareDeleteRetentionPolicy object = { days: 7 } -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -67,20 +62,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -88,10 +75,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var enableReferencedModulesTelemetry = false diff --git a/modules/storage/storage-account/file-service/main.json b/modules/storage/storage-account/file-service/main.json index 5dac172d60..f4601e248a 100644 --- a/modules/storage/storage-account/file-service/main.json +++ b/modules/storage/storage-account/file-service/main.json @@ -5,7 +5,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "1594285537604698727" + "templateHash": "17282775888269025572" }, "name": "Storage Account File Share Services", "description": "This module deploys a Storage Account File Share Service.", @@ -43,15 +43,6 @@ "description": "Optional. The service properties for soft delete." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "minValue": 0, - "maxValue": 365, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -137,11 +128,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -150,15 +137,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "enableReferencedModulesTelemetry": false }, "resources": [ diff --git a/modules/storage/storage-account/main.bicep b/modules/storage/storage-account/main.bicep index b3371af496..125e7548fc 100644 --- a/modules/storage/storage-account/main.bicep +++ b/modules/storage/storage-account/main.bicep @@ -132,11 +132,6 @@ param isLocalUserEnabled bool = false @description('Optional. If true, enables NFS 3.0 support for the storage account. Requires enableHierarchicalNamespace to be true.') param enableNfsV3 bool = false -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -212,10 +207,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var supportsBlobService = kind == 'BlockBlobStorage' || kind == 'BlobStorage' || kind == 'StorageV2' || kind == 'Storage' @@ -380,6 +371,9 @@ module storageAccount_managementPolicies 'management-policy/main.bicep' = if (!e rules: managementPolicyRules enableDefaultTelemetry: enableReferencedModulesTelemetry } + dependsOn: [ + storageAccount_blobServices // To ensure the lastAccessTimeTrackingPolicy is set first (if used in rule) + ] } // SFTP user settings @@ -416,10 +410,9 @@ module storageAccount_blobServices 'blob-service/main.bicep' = if (!empty(blobSe deleteRetentionPolicyEnabled: contains(blobServices, 'deleteRetentionPolicyEnabled') ? blobServices.deleteRetentionPolicyEnabled : false deleteRetentionPolicyDays: contains(blobServices, 'deleteRetentionPolicyDays') ? blobServices.deleteRetentionPolicyDays : 7 isVersioningEnabled: contains(blobServices, 'isVersioningEnabled') ? blobServices.isVersioningEnabled : false - lastAccessTimeTrackingPolicyEnable: contains(blobServices, 'lastAccessTimeTrackingPolicyEnable') ? blobServices.lastAccessTimeTrackingPolicyEnable : false + lastAccessTimeTrackingPolicyEnabled: contains(blobServices, 'lastAccessTimeTrackingPolicyEnabled') ? blobServices.lastAccessTimeTrackingPolicyEnabled : false restorePolicyEnabled: contains(blobServices, 'restorePolicyEnabled') ? blobServices.restorePolicyEnabled : false restorePolicyDays: contains(blobServices, 'restorePolicyDays') ? blobServices.restorePolicyDays : 6 - diagnosticLogsRetentionInDays: contains(blobServices, 'diagnosticLogsRetentionInDays') ? blobServices.diagnosticLogsRetentionInDays : 365 diagnosticStorageAccountId: contains(blobServices, 'diagnosticStorageAccountId') ? blobServices.diagnosticStorageAccountId : '' diagnosticEventHubAuthorizationRuleId: contains(blobServices, 'diagnosticEventHubAuthorizationRuleId') ? blobServices.diagnosticEventHubAuthorizationRuleId : '' diagnosticEventHubName: contains(blobServices, 'diagnosticEventHubName') ? blobServices.diagnosticEventHubName : '' @@ -435,7 +428,6 @@ module storageAccount_fileServices 'file-service/main.bicep' = if (!empty(fileSe name: '${uniqueString(deployment().name, location)}-Storage-FileServices' params: { storageAccountName: storageAccount.name - diagnosticLogsRetentionInDays: contains(fileServices, 'diagnosticLogsRetentionInDays') ? fileServices.diagnosticLogsRetentionInDays : 365 diagnosticStorageAccountId: contains(fileServices, 'diagnosticStorageAccountId') ? fileServices.diagnosticStorageAccountId : '' diagnosticEventHubAuthorizationRuleId: contains(fileServices, 'diagnosticEventHubAuthorizationRuleId') ? fileServices.diagnosticEventHubAuthorizationRuleId : '' diagnosticEventHubName: contains(fileServices, 'diagnosticEventHubName') ? fileServices.diagnosticEventHubName : '' @@ -457,7 +449,6 @@ module storageAccount_queueServices 'queue-service/main.bicep' = if (!empty(queu name: '${uniqueString(deployment().name, location)}-Storage-QueueServices' params: { storageAccountName: storageAccount.name - diagnosticLogsRetentionInDays: contains(queueServices, 'diagnosticLogsRetentionInDays') ? queueServices.diagnosticLogsRetentionInDays : 365 diagnosticStorageAccountId: contains(queueServices, 'diagnosticStorageAccountId') ? queueServices.diagnosticStorageAccountId : '' diagnosticEventHubAuthorizationRuleId: contains(queueServices, 'diagnosticEventHubAuthorizationRuleId') ? queueServices.diagnosticEventHubAuthorizationRuleId : '' diagnosticEventHubName: contains(queueServices, 'diagnosticEventHubName') ? queueServices.diagnosticEventHubName : '' @@ -474,7 +465,6 @@ module storageAccount_tableServices 'table-service/main.bicep' = if (!empty(tabl name: '${uniqueString(deployment().name, location)}-Storage-TableServices' params: { storageAccountName: storageAccount.name - diagnosticLogsRetentionInDays: contains(tableServices, 'diagnosticLogsRetentionInDays') ? tableServices.diagnosticLogsRetentionInDays : 365 diagnosticStorageAccountId: contains(tableServices, 'diagnosticStorageAccountId') ? tableServices.diagnosticStorageAccountId : '' diagnosticEventHubAuthorizationRuleId: contains(tableServices, 'diagnosticEventHubAuthorizationRuleId') ? tableServices.diagnosticEventHubAuthorizationRuleId : '' diagnosticEventHubName: contains(tableServices, 'diagnosticEventHubName') ? tableServices.diagnosticEventHubName : '' diff --git a/modules/storage/storage-account/main.json b/modules/storage/storage-account/main.json index c64220a4fc..aaf1f658ef 100644 --- a/modules/storage/storage-account/main.json +++ b/modules/storage/storage-account/main.json @@ -5,7 +5,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "3064442913839722689" + "templateHash": "14955719000423184958" }, "name": "Storage Accounts", "description": "This module deploys a Storage Account.", @@ -265,15 +265,6 @@ "description": "Optional. If true, enables NFS 3.0 support for the storage account. Requires enableHierarchicalNamespace to be true." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "minValue": 0, - "maxValue": 365, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -422,11 +413,7 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], @@ -764,7 +751,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "609426544615556519" + "templateHash": "13560297539192628062" }, "name": "Private Endpoints", "description": "This module deploys a Private Endpoint.", @@ -898,7 +885,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -964,7 +951,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "18114841529204248478" + "templateHash": "17831763001460207830" }, "name": "Private Endpoint Private DNS Zone Groups", "description": "This module deploys a Private Endpoint Private DNS Zone Group.", @@ -1031,7 +1018,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -1272,7 +1259,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -1309,7 +1296,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "9756021983971600432" + "templateHash": "2581396185828179457" }, "name": "Storage Account Management Policies", "description": "This module deploys a Storage Account Management Policy.", @@ -1355,7 +1342,7 @@ { "condition": "[not(empty(parameters('rules')))]", "type": "Microsoft.Storage/storageAccounts/managementPolicies", - "apiVersion": "2021-09-01", + "apiVersion": "2023-01-01", "name": "[format('{0}/{1}', parameters('storageAccountName'), 'default')]", "properties": { "policy": { @@ -1390,7 +1377,8 @@ } }, "dependsOn": [ - "[resourceId('Microsoft.Storage/storageAccounts', parameters('name'))]" + "[resourceId('Microsoft.Storage/storageAccounts', parameters('name'))]", + "[resourceId('Microsoft.Resources/deployments', format('{0}-Storage-BlobServices', uniqueString(deployment().name, parameters('location'))))]" ] }, { @@ -1588,10 +1576,9 @@ "deleteRetentionPolicyEnabled": "[if(contains(parameters('blobServices'), 'deleteRetentionPolicyEnabled'), createObject('value', parameters('blobServices').deleteRetentionPolicyEnabled), createObject('value', false()))]", "deleteRetentionPolicyDays": "[if(contains(parameters('blobServices'), 'deleteRetentionPolicyDays'), createObject('value', parameters('blobServices').deleteRetentionPolicyDays), createObject('value', 7))]", "isVersioningEnabled": "[if(contains(parameters('blobServices'), 'isVersioningEnabled'), createObject('value', parameters('blobServices').isVersioningEnabled), createObject('value', false()))]", - "lastAccessTimeTrackingPolicyEnable": "[if(contains(parameters('blobServices'), 'lastAccessTimeTrackingPolicyEnable'), createObject('value', parameters('blobServices').lastAccessTimeTrackingPolicyEnable), createObject('value', false()))]", + "lastAccessTimeTrackingPolicyEnabled": "[if(contains(parameters('blobServices'), 'lastAccessTimeTrackingPolicyEnabled'), createObject('value', parameters('blobServices').lastAccessTimeTrackingPolicyEnabled), createObject('value', false()))]", "restorePolicyEnabled": "[if(contains(parameters('blobServices'), 'restorePolicyEnabled'), createObject('value', parameters('blobServices').restorePolicyEnabled), createObject('value', false()))]", "restorePolicyDays": "[if(contains(parameters('blobServices'), 'restorePolicyDays'), createObject('value', parameters('blobServices').restorePolicyDays), createObject('value', 6))]", - "diagnosticLogsRetentionInDays": "[if(contains(parameters('blobServices'), 'diagnosticLogsRetentionInDays'), createObject('value', parameters('blobServices').diagnosticLogsRetentionInDays), createObject('value', 365))]", "diagnosticStorageAccountId": "[if(contains(parameters('blobServices'), 'diagnosticStorageAccountId'), createObject('value', parameters('blobServices').diagnosticStorageAccountId), createObject('value', ''))]", "diagnosticEventHubAuthorizationRuleId": "[if(contains(parameters('blobServices'), 'diagnosticEventHubAuthorizationRuleId'), createObject('value', parameters('blobServices').diagnosticEventHubAuthorizationRuleId), createObject('value', ''))]", "diagnosticEventHubName": "[if(contains(parameters('blobServices'), 'diagnosticEventHubName'), createObject('value', parameters('blobServices').diagnosticEventHubName), createObject('value', ''))]", @@ -1609,7 +1596,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "1395192341429097070" + "templateHash": "16838270897726250953" }, "name": "Storage Account blob Services", "description": "This module deploys a Storage Account Blob Service.", @@ -1713,7 +1700,7 @@ "description": "Optional. Use versioning to automatically maintain previous versions of your blobs." } }, - "lastAccessTimeTrackingPolicyEnable": { + "lastAccessTimeTrackingPolicyEnabled": { "type": "bool", "defaultValue": false, "metadata": { @@ -1742,15 +1729,6 @@ "description": "Optional. Blob containers to create." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "minValue": 0, - "maxValue": 365, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -1829,11 +1807,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -1842,16 +1816,12 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], "name": "default", - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "enableReferencedModulesTelemetry": false }, "resources": [ @@ -1895,9 +1865,9 @@ }, "isVersioningEnabled": "[parameters('isVersioningEnabled')]", "lastAccessTimeTrackingPolicy": { - "enable": "[parameters('lastAccessTimeTrackingPolicyEnable')]", - "name": "[if(equals(parameters('lastAccessTimeTrackingPolicyEnable'), true()), 'AccessTimeTracking', null())]", - "trackingGranularityInDays": "[if(equals(parameters('lastAccessTimeTrackingPolicyEnable'), true()), 1, null())]" + "enable": "[parameters('lastAccessTimeTrackingPolicyEnabled')]", + "name": "[if(equals(parameters('lastAccessTimeTrackingPolicyEnabled'), true()), 'AccessTimeTracking', null())]", + "trackingGranularityInDays": "[if(equals(parameters('lastAccessTimeTrackingPolicyEnabled'), true()), 1, null())]" }, "restorePolicy": { "enabled": "[parameters('restorePolicyEnabled')]", @@ -2485,7 +2455,6 @@ "storageAccountName": { "value": "[parameters('name')]" }, - "diagnosticLogsRetentionInDays": "[if(contains(parameters('fileServices'), 'diagnosticLogsRetentionInDays'), createObject('value', parameters('fileServices').diagnosticLogsRetentionInDays), createObject('value', 365))]", "diagnosticStorageAccountId": "[if(contains(parameters('fileServices'), 'diagnosticStorageAccountId'), createObject('value', parameters('fileServices').diagnosticStorageAccountId), createObject('value', ''))]", "diagnosticEventHubAuthorizationRuleId": "[if(contains(parameters('fileServices'), 'diagnosticEventHubAuthorizationRuleId'), createObject('value', parameters('fileServices').diagnosticEventHubAuthorizationRuleId), createObject('value', ''))]", "diagnosticEventHubName": "[if(contains(parameters('fileServices'), 'diagnosticEventHubName'), createObject('value', parameters('fileServices').diagnosticEventHubName), createObject('value', ''))]", @@ -2506,7 +2475,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "1594285537604698727" + "templateHash": "17282775888269025572" }, "name": "Storage Account File Share Services", "description": "This module deploys a Storage Account File Share Service.", @@ -2544,15 +2513,6 @@ "description": "Optional. The service properties for soft delete." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "minValue": 0, - "maxValue": 365, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -2638,11 +2598,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -2651,15 +2607,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "enableReferencedModulesTelemetry": false }, "resources": [ @@ -3109,7 +3061,6 @@ "storageAccountName": { "value": "[parameters('name')]" }, - "diagnosticLogsRetentionInDays": "[if(contains(parameters('queueServices'), 'diagnosticLogsRetentionInDays'), createObject('value', parameters('queueServices').diagnosticLogsRetentionInDays), createObject('value', 365))]", "diagnosticStorageAccountId": "[if(contains(parameters('queueServices'), 'diagnosticStorageAccountId'), createObject('value', parameters('queueServices').diagnosticStorageAccountId), createObject('value', ''))]", "diagnosticEventHubAuthorizationRuleId": "[if(contains(parameters('queueServices'), 'diagnosticEventHubAuthorizationRuleId'), createObject('value', parameters('queueServices').diagnosticEventHubAuthorizationRuleId), createObject('value', ''))]", "diagnosticEventHubName": "[if(contains(parameters('queueServices'), 'diagnosticEventHubName'), createObject('value', parameters('queueServices').diagnosticEventHubName), createObject('value', ''))]", @@ -3128,7 +3079,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "13219619797955519085" + "templateHash": "3707030790801090324" }, "name": "Storage Account Queue Services", "description": "This module deploys a Storage Account Queue Service.", @@ -3149,15 +3100,6 @@ "description": "Optional. Queues to create." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "minValue": 0, - "maxValue": 365, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -3236,11 +3178,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -3249,16 +3187,12 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], "name": "default", - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "enableReferencedModulesTelemetry": false }, "resources": [ @@ -3650,7 +3584,6 @@ "storageAccountName": { "value": "[parameters('name')]" }, - "diagnosticLogsRetentionInDays": "[if(contains(parameters('tableServices'), 'diagnosticLogsRetentionInDays'), createObject('value', parameters('tableServices').diagnosticLogsRetentionInDays), createObject('value', 365))]", "diagnosticStorageAccountId": "[if(contains(parameters('tableServices'), 'diagnosticStorageAccountId'), createObject('value', parameters('tableServices').diagnosticStorageAccountId), createObject('value', ''))]", "diagnosticEventHubAuthorizationRuleId": "[if(contains(parameters('tableServices'), 'diagnosticEventHubAuthorizationRuleId'), createObject('value', parameters('tableServices').diagnosticEventHubAuthorizationRuleId), createObject('value', ''))]", "diagnosticEventHubName": "[if(contains(parameters('tableServices'), 'diagnosticEventHubName'), createObject('value', parameters('tableServices').diagnosticEventHubName), createObject('value', ''))]", @@ -3669,7 +3602,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "15029180251266513913" + "templateHash": "16178057085724361046" }, "name": "Storage Account Table Services", "description": "This module deploys a Storage Account Table Service.", @@ -3690,15 +3623,6 @@ "description": "Optional. tables to create." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "minValue": 0, - "maxValue": 365, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -3777,11 +3701,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -3790,16 +3710,12 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], "name": "default", - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "enableReferencedModulesTelemetry": false }, "resources": [ diff --git a/modules/storage/storage-account/management-policy/README.md b/modules/storage/storage-account/management-policy/README.md index 2931f7fb9f..471cefa283 100644 --- a/modules/storage/storage-account/management-policy/README.md +++ b/modules/storage/storage-account/management-policy/README.md @@ -13,7 +13,7 @@ This module deploys a Storage Account Management Policy. | Resource Type | API Version | | :-- | :-- | -| `Microsoft.Storage/storageAccounts/managementPolicies` | [2021-09-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Storage/2021-09-01/storageAccounts/managementPolicies) | +| `Microsoft.Storage/storageAccounts/managementPolicies` | [2023-01-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Storage/storageAccounts/managementPolicies) | ## Parameters diff --git a/modules/storage/storage-account/management-policy/main.bicep b/modules/storage/storage-account/management-policy/main.bicep index 7594e558f1..de6c694754 100644 --- a/modules/storage/storage-account/management-policy/main.bicep +++ b/modules/storage/storage-account/management-policy/main.bicep @@ -24,12 +24,12 @@ resource defaultTelemetry 'Microsoft.Resources/deployments@2021-04-01' = if (ena } } -resource storageAccount 'Microsoft.Storage/storageAccounts@2021-09-01' existing = { +resource storageAccount 'Microsoft.Storage/storageAccounts@2023-01-01' existing = { name: storageAccountName } // lifecycle policy -resource managementPolicy 'Microsoft.Storage/storageAccounts/managementPolicies@2021-09-01' = if (!empty(rules)) { +resource managementPolicy 'Microsoft.Storage/storageAccounts/managementPolicies@2023-01-01' = if (!empty(rules)) { name: 'default' parent: storageAccount properties: { diff --git a/modules/storage/storage-account/management-policy/main.json b/modules/storage/storage-account/management-policy/main.json index f22270f4e7..ed8bcbe20d 100644 --- a/modules/storage/storage-account/management-policy/main.json +++ b/modules/storage/storage-account/management-policy/main.json @@ -5,7 +5,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "9756021983971600432" + "templateHash": "2581396185828179457" }, "name": "Storage Account Management Policies", "description": "This module deploys a Storage Account Management Policy.", @@ -51,7 +51,7 @@ { "condition": "[not(empty(parameters('rules')))]", "type": "Microsoft.Storage/storageAccounts/managementPolicies", - "apiVersion": "2021-09-01", + "apiVersion": "2023-01-01", "name": "[format('{0}/{1}', parameters('storageAccountName'), 'default')]", "properties": { "policy": { diff --git a/modules/storage/storage-account/queue-service/README.md b/modules/storage/storage-account/queue-service/README.md index f0410dd6f9..043a0b7c67 100644 --- a/modules/storage/storage-account/queue-service/README.md +++ b/modules/storage/storage-account/queue-service/README.md @@ -33,7 +33,6 @@ This module deploys a Storage Account Queue Service. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, StorageDelete, StorageRead, StorageWrite]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[Transaction]` | `[Transaction]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | diff --git a/modules/storage/storage-account/queue-service/main.bicep b/modules/storage/storage-account/queue-service/main.bicep index 649f1f0147..29ee8b7d02 100644 --- a/modules/storage/storage-account/queue-service/main.bicep +++ b/modules/storage/storage-account/queue-service/main.bicep @@ -9,11 +9,6 @@ param storageAccountName string @description('Optional. Queues to create.') param queues array = [] -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -58,20 +53,12 @@ var name = 'default' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -79,10 +66,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var enableReferencedModulesTelemetry = false diff --git a/modules/storage/storage-account/queue-service/main.json b/modules/storage/storage-account/queue-service/main.json index 0ff7fb5367..33a2c49f58 100644 --- a/modules/storage/storage-account/queue-service/main.json +++ b/modules/storage/storage-account/queue-service/main.json @@ -5,7 +5,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "13219619797955519085" + "templateHash": "3707030790801090324" }, "name": "Storage Account Queue Services", "description": "This module deploys a Storage Account Queue Service.", @@ -26,15 +26,6 @@ "description": "Optional. Queues to create." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "minValue": 0, - "maxValue": 365, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -113,11 +104,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -126,16 +113,12 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], "name": "default", - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "enableReferencedModulesTelemetry": false }, "resources": [ diff --git a/modules/storage/storage-account/table-service/README.md b/modules/storage/storage-account/table-service/README.md index ef4e9243f6..978bb97f0d 100644 --- a/modules/storage/storage-account/table-service/README.md +++ b/modules/storage/storage-account/table-service/README.md @@ -32,7 +32,6 @@ This module deploys a Storage Account Table Service. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, StorageDelete, StorageRead, StorageWrite]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[Transaction]` | `[Transaction]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | diff --git a/modules/storage/storage-account/table-service/main.bicep b/modules/storage/storage-account/table-service/main.bicep index 3d43322b4d..cbf0bf086b 100644 --- a/modules/storage/storage-account/table-service/main.bicep +++ b/modules/storage/storage-account/table-service/main.bicep @@ -9,11 +9,6 @@ param storageAccountName string @description('Optional. tables to create.') param tables array = [] -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -58,20 +53,12 @@ var name = 'default' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -79,10 +66,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var enableReferencedModulesTelemetry = false diff --git a/modules/storage/storage-account/table-service/main.json b/modules/storage/storage-account/table-service/main.json index c2eac6c04e..67a9622a48 100644 --- a/modules/storage/storage-account/table-service/main.json +++ b/modules/storage/storage-account/table-service/main.json @@ -5,7 +5,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "15029180251266513913" + "templateHash": "16178057085724361046" }, "name": "Storage Account Table Services", "description": "This module deploys a Storage Account Table Service.", @@ -26,15 +26,6 @@ "description": "Optional. tables to create." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "minValue": 0, - "maxValue": 365, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -113,11 +104,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -126,16 +113,12 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], "name": "default", - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "enableReferencedModulesTelemetry": false }, "resources": [ diff --git a/modules/synapse/private-link-hub/.test/common/dependencies.bicep b/modules/synapse/private-link-hub/.test/common/dependencies.bicep index 9bb5aa16b5..2c91060579 100644 --- a/modules/synapse/private-link-hub/.test/common/dependencies.bicep +++ b/modules/synapse/private-link-hub/.test/common/dependencies.bicep @@ -12,56 +12,56 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource networkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2021-08-01' = { - name: networkSecurityGroupName - location: location - properties: {} +resource networkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2023-04-01' = { + name: networkSecurityGroupName + location: location + properties: {} } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - networkSecurityGroup: { - id: networkSecurityGroup.id - } - privateEndpointNetworkPolicies: 'Disabled' - privateLinkServiceNetworkPolicies: 'Enabled' - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + networkSecurityGroup: { + id: networkSecurityGroup.id + } + privateEndpointNetworkPolicies: 'Disabled' + privateLinkServiceNetworkPolicies: 'Enabled' + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.azuresynapse.net' - location: 'global' + name: 'privatelink.azuresynapse.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/synapse/private-link-hub/README.md b/modules/synapse/private-link-hub/README.md index 5a39499cf2..a625cc96ae 100644 --- a/modules/synapse/private-link-hub/README.md +++ b/modules/synapse/private-link-hub/README.md @@ -16,8 +16,8 @@ This module deploys an Azure Synapse Analytics (Private Link Hub). | :-- | :-- | | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | | `Microsoft.Synapse/privateLinkHubs` | [2021-06-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Synapse/2021-06-01/privateLinkHubs) | ## Parameters diff --git a/modules/synapse/private-link-hub/main.json b/modules/synapse/private-link-hub/main.json index 0fac192eb1..0b5a879abb 100644 --- a/modules/synapse/private-link-hub/main.json +++ b/modules/synapse/private-link-hub/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6990684837465089957" - } + "version": "0.20.4.51522", + "templateHash": "16010893380841476470" + }, + "name": "Azure Synapse Analytics", + "description": "This module deploys an Azure Synapse Analytics (Private Link Hub).", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -32,14 +35,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "enableDefaultTelemetry": { "type": "bool", @@ -136,8 +139,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15727929666985454365" + "version": "0.20.4.51522", + "templateHash": "7605248718189253682" } }, "parameters": { @@ -298,9 +301,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -365,14 +371,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -430,7 +436,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -495,9 +501,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -508,8 +517,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -560,7 +569,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -630,8 +639,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -801,7 +810,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } diff --git a/modules/synapse/workspace/.test/common/dependencies.bicep b/modules/synapse/workspace/.test/common/dependencies.bicep index 361c4fe443..821b4f8eb0 100644 --- a/modules/synapse/workspace/.test/common/dependencies.bicep +++ b/modules/synapse/workspace/.test/common/dependencies.bicep @@ -13,64 +13,64 @@ param storageAccountName string var addressPrefix = '10.0.0.0/16' resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-07-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.sql.azuresynapse.net' - location: 'global' + name: 'privatelink.sql.azuresynapse.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetworkName}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetworkName}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource storageAccount 'Microsoft.Storage/storageAccounts@2022-09-01' = { - name: storageAccountName - location: location - sku: { - name: 'Standard_LRS' - } - kind: 'StorageV2' - properties: { - isHnsEnabled: true - } - - resource blobService 'blobServices@2022-09-01' = { - name: 'default' - - resource container 'containers@2022-09-01' = { - name: 'synapsews' - } + name: storageAccountName + location: location + sku: { + name: 'Standard_LRS' + } + kind: 'StorageV2' + properties: { + isHnsEnabled: true + } + + resource blobService 'blobServices@2022-09-01' = { + name: 'default' + + resource container 'containers@2022-09-01' = { + name: 'synapsews' } + } } @description('The principal ID of the created Managed Identity.') diff --git a/modules/synapse/workspace/.test/common/main.test.bicep b/modules/synapse/workspace/.test/common/main.test.bicep index 5a4fdf72ea..b9e21c6690 100644 --- a/modules/synapse/workspace/.test/common/main.test.bicep +++ b/modules/synapse/workspace/.test/common/main.test.bicep @@ -102,7 +102,6 @@ module testDeployment '../../main.bicep' = { name: 'shir01' } ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/synapse/workspace/README.md b/modules/synapse/workspace/README.md index 41c1cbda90..85195eaa20 100644 --- a/modules/synapse/workspace/README.md +++ b/modules/synapse/workspace/README.md @@ -18,8 +18,8 @@ This module deploys a Synapse Workspace. | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | | `Microsoft.KeyVault/vaults/accessPolicies` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.KeyVault/2022-07-01/vaults/accessPolicies) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | | `Microsoft.Synapse/workspaces` | [2021-06-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Synapse/2021-06-01/workspaces) | | `Microsoft.Synapse/workspaces/integrationRuntimes` | [2021-06-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Synapse/2021-06-01/workspaces/integrationRuntimes) | | `Microsoft.Synapse/workspaces/keys` | [2021-06-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Synapse/2021-06-01/workspaces/keys) | @@ -54,7 +54,6 @@ This module deploys a Synapse Workspace. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, BuiltinSqlReqsEnded, GatewayApiRequests, IntegrationActivityRuns, IntegrationPipelineRuns, IntegrationTriggerRuns, SQLSecurityAuditEvents, SynapseLinkEvent, SynapseRbacOperations]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | | `diagnosticWorkspaceId` | string | `''` | | Resource ID of the diagnostic log analytics workspace. | @@ -366,7 +365,6 @@ module workspace './synapse/workspace/main.bicep' = { 'SynapseLinkEvent' 'SynapseRbacOperations' ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -452,9 +450,6 @@ module workspace './synapse/workspace/main.bicep' = { "SynapseRbacOperations" ] }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/synapse/workspace/integration-runtime/main.json b/modules/synapse/workspace/integration-runtime/main.json index b664a79779..758aa10c62 100644 --- a/modules/synapse/workspace/integration-runtime/main.json +++ b/modules/synapse/workspace/integration-runtime/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5721182358539699224" - } + "version": "0.20.4.51522", + "templateHash": "3836470848906868544" + }, + "name": "Synapse Workspace Integration Runtimes", + "description": "This module deploys a Synapse Workspace Integration Runtime.", + "owner": "Azure/module-maintainers" }, "parameters": { "workspaceName": { @@ -23,13 +26,13 @@ }, "type": { "type": "string", - "metadata": { - "description": "Required. The type of Integration Runtime." - }, "allowedValues": [ "Managed", "SelfHosted" - ] + ], + "metadata": { + "description": "Required. The type of Integration Runtime." + } }, "typeProperties": { "type": "object", diff --git a/modules/synapse/workspace/key/main.json b/modules/synapse/workspace/key/main.json index 1899072ef2..95d5cd7e00 100644 --- a/modules/synapse/workspace/key/main.json +++ b/modules/synapse/workspace/key/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14628625784774249252" - } + "version": "0.20.4.51522", + "templateHash": "11818706446850681387" + }, + "name": "Synapse Workspaces Keys", + "description": "This module deploys a Synapse Workspaces Key.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/synapse/workspace/main.bicep b/modules/synapse/workspace/main.bicep index 7799db3908..b0c627634d 100644 --- a/modules/synapse/workspace/main.bicep +++ b/modules/synapse/workspace/main.bicep @@ -105,11 +105,6 @@ param roleAssignments array = [] @description('Optional. Configuration details for private endpoints. For security reasons, it is recommended to use private endpoints whenever possible.') param privateEndpoints array = [] -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -157,20 +152,12 @@ var identity = { var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified diff --git a/modules/synapse/workspace/main.json b/modules/synapse/workspace/main.json index 05c067648e..7ae7ac9409 100644 --- a/modules/synapse/workspace/main.json +++ b/modules/synapse/workspace/main.json @@ -5,7 +5,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "3345433640294788580" + "templateHash": "6192759054109646804" }, "name": "Synapse Workspaces", "description": "This module deploys a Synapse Workspace.", @@ -229,15 +229,6 @@ "description": "Optional. Configuration details for private endpoints. For security reasons, it is recommended to use private endpoints whenever possible." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "minValue": 0, - "maxValue": 365, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -302,11 +293,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], @@ -316,7 +303,7 @@ "type": "[variables('identityType')]", "userAssignedIdentities": "[if(not(empty(variables('userAssignedIdentitiesUnion'))), variables('userAssignedIdentitiesUnion'), null())]" }, - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "enableReferencedModulesTelemetry": false }, "resources": [ @@ -868,7 +855,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "609426544615556519" + "templateHash": "13560297539192628062" }, "name": "Private Endpoints", "description": "This module deploys a Private Endpoint.", @@ -1002,7 +989,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -1068,7 +1055,7 @@ "_generator": { "name": "bicep", "version": "0.20.4.51522", - "templateHash": "18114841529204248478" + "templateHash": "17831763001460207830" }, "name": "Private Endpoint Private DNS Zone Groups", "description": "This module deploys a Private Endpoint Private DNS Zone Group.", @@ -1135,7 +1122,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -1376,7 +1363,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } diff --git a/modules/virtual-machine-images/image-template/.test/common/dependencies.bicep b/modules/virtual-machine-images/image-template/.test/common/dependencies.bicep index f13169b643..a4bd9d76a3 100644 --- a/modules/virtual-machine-images/image-template/.test/common/dependencies.bicep +++ b/modules/virtual-machine-images/image-template/.test/common/dependencies.bicep @@ -62,7 +62,7 @@ resource msi_contibutorRoleAssignment 'Microsoft.Authorization/roleAssignments@2 } } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { name: virtualNetworkName location: location properties: { diff --git a/modules/virtual-machine-images/image-template/main.json b/modules/virtual-machine-images/image-template/main.json index d3946ec734..30f21e918d 100644 --- a/modules/virtual-machine-images/image-template/main.json +++ b/modules/virtual-machine-images/image-template/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9359283397847619664" - } + "version": "0.20.4.51522", + "templateHash": "838675247784542627" + }, + "name": "Virtual Machine Image Templates", + "description": "This module deploys a Virtual Machine Image Template that can be consumed by Azure Image Builder (AIB).", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -38,8 +41,8 @@ "buildTimeoutInMinutes": { "type": "int", "defaultValue": 0, - "maxValue": 960, "minValue": 0, + "maxValue": 960, "metadata": { "description": "Optional. Image build timeout in minutes. Allowed values: 0-960. 0 means the default 240 minutes." } @@ -129,13 +132,13 @@ "storageAccountType": { "type": "string", "defaultValue": "Standard_LRS", - "metadata": { - "description": "Optional. Storage account type to be used to store the image in the Azure Compute Gallery." - }, "allowedValues": [ "Standard_LRS", "Standard_ZRS" - ] + ], + "metadata": { + "description": "Optional. Storage account type to be used to store the image in the Azure Compute Gallery." + } }, "stagingResourceGroup": { "type": "string", @@ -147,14 +150,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "tags": { "type": "object", @@ -334,8 +337,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13408820321849136528" + "version": "0.20.4.51522", + "templateHash": "1642889532812614498" } }, "parameters": { diff --git a/modules/web/connection/main.json b/modules/web/connection/main.json index 750014d6c4..b6ee149b14 100644 --- a/modules/web/connection/main.json +++ b/modules/web/connection/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14555471655592960659" - } + "version": "0.20.4.51522", + "templateHash": "15514317301300272794" + }, + "name": "API Connections", + "description": "This module deploys an Azure API Connection.", + "owner": "Azure/module-maintainers" }, "parameters": { "api": { @@ -80,14 +83,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "tags": { "type": "object", @@ -183,8 +186,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15293872186826158574" + "version": "0.20.4.51522", + "templateHash": "2642908825697266610" } }, "parameters": { diff --git a/modules/web/hosting-environment/.test/asev2/dependencies.bicep b/modules/web/hosting-environment/.test/asev2/dependencies.bicep index 8ea40d41f7..c514fe19a2 100644 --- a/modules/web/hosting-environment/.test/asev2/dependencies.bicep +++ b/modules/web/hosting-environment/.test/asev2/dependencies.bicep @@ -12,62 +12,62 @@ param managedIdentityName string var addressPrefix = '10.0.0.0/16' -resource networkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2021-08-01' = { - name: networkSecurityGroupName - location: location - properties: { - securityRules: [ - { - name: 'AllowPortsForASE2' - properties: { - access: 'Allow' - destinationAddressPrefix: addressPrefix - destinationPortRange: '454-455' - direction: 'Inbound' - priority: 1020 - protocol: '*' - sourceAddressPrefix: 'AppServiceManagement' - sourcePortRange: '*' - } - } - ] - } +resource networkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2023-04-01' = { + name: networkSecurityGroupName + location: location + properties: { + securityRules: [ + { + name: 'AllowPortsForASE2' + properties: { + access: 'Allow' + destinationAddressPrefix: addressPrefix + destinationPortRange: '454-455' + direction: 'Inbound' + priority: 1020 + protocol: '*' + sourceAddressPrefix: 'AppServiceManagement' + sourcePortRange: '*' + } + } + ] + } } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] + } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + networkSecurityGroup: { + id: networkSecurityGroup.id + } + delegations: [ { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - networkSecurityGroup: { - id: networkSecurityGroup.id - } - delegations: [ - { - name: 'ase' - properties: { - serviceName: 'Microsoft.Web/hostingEnvironments' - } - } - ] - } + name: 'ase' + properties: { + serviceName: 'Microsoft.Web/hostingEnvironments' + } } - ] - } + ] + } + } + ] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/web/hosting-environment/.test/asev2/main.test.bicep b/modules/web/hosting-environment/.test/asev2/main.test.bicep index 3f83844fc3..1941d8545e 100644 --- a/modules/web/hosting-environment/.test/asev2/main.test.bicep +++ b/modules/web/hosting-environment/.test/asev2/main.test.bicep @@ -87,7 +87,6 @@ module testDeployment '../../main.bicep' = { value: '1' } ] - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/web/hosting-environment/.test/asev3/dependencies.bicep b/modules/web/hosting-environment/.test/asev3/dependencies.bicep index 74137cddf1..8e5e6f7c5d 100644 --- a/modules/web/hosting-environment/.test/asev3/dependencies.bicep +++ b/modules/web/hosting-environment/.test/asev3/dependencies.bicep @@ -18,108 +18,108 @@ param certDeploymentScriptName string var addressPrefix = '10.0.0.0/16' -resource networkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2021-08-01' = { - name: networkSecurityGroupName - location: location - properties: { - securityRules: [ - { - name: 'AllowPortsForASE' - properties: { - access: 'Allow' - destinationAddressPrefix: '10.0.7.0/24' - destinationPortRange: '454-455' - direction: 'Inbound' - priority: 1010 - protocol: '*' - sourceAddressPrefix: 'AppServiceManagement' - sourcePortRange: '*' - } - } - ] - } +resource networkSecurityGroup 'Microsoft.Network/networkSecurityGroups@2023-04-01' = { + name: networkSecurityGroupName + location: location + properties: { + securityRules: [ + { + name: 'AllowPortsForASE' + properties: { + access: 'Allow' + destinationAddressPrefix: '10.0.7.0/24' + destinationPortRange: '454-455' + direction: 'Inbound' + priority: 1010 + protocol: '*' + sourceAddressPrefix: 'AppServiceManagement' + sourcePortRange: '*' + } + } + ] + } } -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] + } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + networkSecurityGroup: { + id: networkSecurityGroup.id + } + delegations: [ { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - networkSecurityGroup: { - id: networkSecurityGroup.id - } - delegations: [ - { - name: 'ase' - properties: { - serviceName: 'Microsoft.Web/hostingEnvironments' - } - } - ] - } + name: 'ase' + properties: { + serviceName: 'Microsoft.Web/hostingEnvironments' + } } - ] - } + ] + } + } + ] + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource keyVault 'Microsoft.KeyVault/vaults@2022-07-01' = { - name: keyVaultName - location: location - properties: { - sku: { - family: 'A' - name: 'standard' - } - tenantId: tenant().tenantId - enablePurgeProtection: null - enabledForTemplateDeployment: true - enabledForDiskEncryption: true - enabledForDeployment: true - enableRbacAuthorization: true - accessPolicies: [] + name: keyVaultName + location: location + properties: { + sku: { + family: 'A' + name: 'standard' } + tenantId: tenant().tenantId + enablePurgeProtection: null + enabledForTemplateDeployment: true + enabledForDiskEncryption: true + enabledForDeployment: true + enableRbacAuthorization: true + accessPolicies: [] + } } resource keyPermissions 'Microsoft.Authorization/roleAssignments@2022-04-01' = { - name: guid('msi-${managedIdentity.name}-KeyVault-Admin-RoleAssignment') - scope: keyVault - properties: { - principalId: managedIdentity.properties.principalId - roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '00482a5a-887f-4fb3-b363-3b7fe8e74483') // Key Vault Administrator - principalType: 'ServicePrincipal' - } + name: guid('msi-${managedIdentity.name}-KeyVault-Admin-RoleAssignment') + scope: keyVault + properties: { + principalId: managedIdentity.properties.principalId + roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '00482a5a-887f-4fb3-b363-3b7fe8e74483') // Key Vault Administrator + principalType: 'ServicePrincipal' + } } resource certDeploymentScript 'Microsoft.Resources/deploymentScripts@2020-10-01' = { - name: certDeploymentScriptName - location: location - kind: 'AzurePowerShell' - identity: { - type: 'UserAssigned' - userAssignedIdentities: { - '${managedIdentity.id}': {} - } - } - properties: { - azPowerShellVersion: '8.0' - retentionInterval: 'P1D' - arguments: '-KeyVaultName "${keyVault.name}" -CertName "asev3certificate" -CertSubjectName "CN=*.internal.contoso.com"' - scriptContent: loadTextContent('../../../../.shared/.scripts/Set-CertificateInKeyVault.ps1') + name: certDeploymentScriptName + location: location + kind: 'AzurePowerShell' + identity: { + type: 'UserAssigned' + userAssignedIdentities: { + '${managedIdentity.id}': {} } + } + properties: { + azPowerShellVersion: '8.0' + retentionInterval: 'P1D' + arguments: '-KeyVaultName "${keyVault.name}" -CertName "asev3certificate" -CertSubjectName "CN=*.internal.contoso.com"' + scriptContent: loadTextContent('../../../../.shared/.scripts/Set-CertificateInKeyVault.ps1') + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/web/hosting-environment/.test/asev3/main.test.bicep b/modules/web/hosting-environment/.test/asev3/main.test.bicep index 27c63ec145..11b13d0ee2 100644 --- a/modules/web/hosting-environment/.test/asev3/main.test.bicep +++ b/modules/web/hosting-environment/.test/asev3/main.test.bicep @@ -95,7 +95,6 @@ module testDeployment '../../main.bicep' = { inboundIpAddressOverride: '10.0.0.10' remoteDebugEnabled: true upgradePreference: 'Late' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/web/hosting-environment/README.md b/modules/web/hosting-environment/README.md index 942d442db9..c602501fb8 100644 --- a/modules/web/hosting-environment/README.md +++ b/modules/web/hosting-environment/README.md @@ -47,7 +47,6 @@ This module deploys an App Service Environment. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[allLogs]` | `['', allLogs, AppServiceEnvironmentPlatformLogs]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | | `diagnosticWorkspaceId` | string | `''` | | Resource ID of the diagnostic log analytics workspace. | @@ -282,7 +281,6 @@ module hostingEnvironment './web/hosting-environment/main.bicep' = { ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -346,9 +344,6 @@ module hostingEnvironment './web/hosting-environment/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, @@ -431,7 +426,6 @@ module hostingEnvironment './web/hosting-environment/main.bicep' = { customDnsSuffixKeyVaultReferenceIdentity: '' diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -509,9 +503,6 @@ module hostingEnvironment './web/hosting-environment/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/web/hosting-environment/configuration--customdnssuffix/main.json b/modules/web/hosting-environment/configuration--customdnssuffix/main.json index a5c56c232a..a09f93e81e 100644 --- a/modules/web/hosting-environment/configuration--customdnssuffix/main.json +++ b/modules/web/hosting-environment/configuration--customdnssuffix/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14999057769396977441" - } + "version": "0.20.4.51522", + "templateHash": "11788859333407565296" + }, + "name": "Hosting Environment Custom DNS Suffix Configuration", + "description": "This module deploys a Hosting Environment Custom DNS Suffix Configuration.", + "owner": "Azure/module-maintainers" }, "parameters": { "hostingEnvironmentName": { diff --git a/modules/web/hosting-environment/configuration--networking/main.json b/modules/web/hosting-environment/configuration--networking/main.json index fb0db57fdc..4ed8ea7eae 100644 --- a/modules/web/hosting-environment/configuration--networking/main.json +++ b/modules/web/hosting-environment/configuration--networking/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10424547902180820059" - } + "version": "0.20.4.51522", + "templateHash": "16351992787760940933" + }, + "name": "Hosting Environment Network Configuration", + "description": "This module deploys a Hosting Environment Network Configuration.", + "owner": "Azure/module-maintainers" }, "parameters": { "hostingEnvironmentName": { diff --git a/modules/web/hosting-environment/main.bicep b/modules/web/hosting-environment/main.bicep index 40ec20ece0..dbaade31fd 100644 --- a/modules/web/hosting-environment/main.bicep +++ b/modules/web/hosting-environment/main.bicep @@ -120,11 +120,6 @@ param systemAssignedIdentity bool = false @description('Optional. The ID(s) to assign to the resource.') param userAssignedIdentities object = {} -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -156,20 +151,12 @@ param diagnosticSettingsName string = '' var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified diff --git a/modules/web/hosting-environment/main.json b/modules/web/hosting-environment/main.json index 0a3eb7ae08..82944f13dc 100644 --- a/modules/web/hosting-environment/main.json +++ b/modules/web/hosting-environment/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "1989221922012543604" - } + "version": "0.20.4.51522", + "templateHash": "8748704169658147866" + }, + "name": "App Service Environments", + "description": "This module deploys an App Service Environment.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -26,14 +29,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -52,13 +55,13 @@ "kind": { "type": "string", "defaultValue": "ASEv3", - "metadata": { - "description": "Optional. Kind of resource." - }, "allowedValues": [ "ASEv2", "ASEv3" - ] + ], + "metadata": { + "description": "Optional. Kind of resource." + } }, "clusterSettings": { "type": "array", @@ -229,15 +232,6 @@ "description": "Optional. The ID(s) to assign to the resource." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -302,15 +296,11 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "identityType": "[if(parameters('systemAssignedIdentity'), if(not(empty(parameters('userAssignedIdentities'))), 'SystemAssigned,UserAssigned', 'SystemAssigned'), if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None'))]", "enableReferencedModulesTelemetry": false, "identity": "[if(not(equals(variables('identityType'), 'None')), createObject('type', variables('identityType'), 'userAssignedIdentities', if(not(empty(parameters('userAssignedIdentities'))), parameters('userAssignedIdentities'), null())), null())]" @@ -422,9 +412,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10424547902180820059" - } + "version": "0.20.4.51522", + "templateHash": "16351992787760940933" + }, + "name": "Hosting Environment Network Configuration", + "description": "This module deploys a Hosting Environment Network Configuration.", + "owner": "Azure/module-maintainers" }, "parameters": { "hostingEnvironmentName": { @@ -558,9 +551,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "14999057769396977441" - } + "version": "0.20.4.51522", + "templateHash": "11788859333407565296" + }, + "name": "Hosting Environment Custom DNS Suffix Configuration", + "description": "This module deploys a Hosting Environment Custom DNS Suffix Configuration.", + "owner": "Azure/module-maintainers" }, "parameters": { "hostingEnvironmentName": { @@ -684,8 +680,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15912113861904370144" + "version": "0.20.4.51522", + "templateHash": "16350418428946694714" } }, "parameters": { diff --git a/modules/web/serverfarm/.test/common/main.test.bicep b/modules/web/serverfarm/.test/common/main.test.bicep index 4829eff14a..4d1be19acd 100644 --- a/modules/web/serverfarm/.test/common/main.test.bicep +++ b/modules/web/serverfarm/.test/common/main.test.bicep @@ -70,7 +70,6 @@ module testDeployment '../../main.bicep' = { size: 'S1' tier: 'Standard' } - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/web/serverfarm/README.md b/modules/web/serverfarm/README.md index 91bbd57e2f..a96a2a13e7 100644 --- a/modules/web/serverfarm/README.md +++ b/modules/web/serverfarm/README.md @@ -35,7 +35,6 @@ This module deploys an App Service Plan. | `appServiceEnvironmentId` | string | `''` | | The Resource ID of the App Service Environment to use for the App Service Plan. | | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub. | @@ -233,7 +232,6 @@ module serverfarm './web/serverfarm/main.bicep' = { // Non-required parameters diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -287,9 +285,6 @@ module serverfarm './web/serverfarm/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, diff --git a/modules/web/serverfarm/main.bicep b/modules/web/serverfarm/main.bicep index bac8c02ef6..e94ffce02d 100644 --- a/modules/web/serverfarm/main.bicep +++ b/modules/web/serverfarm/main.bicep @@ -66,11 +66,6 @@ param enableDefaultTelemetry bool = true @description('Optional. The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings".') param diagnosticSettingsName string = '' -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 - @description('Optional. Resource ID of the diagnostic storage account. For security reasons, it is recommended to set diagnostic settings to send data to either storage account, log analytics workspace or event hub.') param diagnosticStorageAccountId string = '' @@ -101,10 +96,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] // ============ // diff --git a/modules/web/serverfarm/main.json b/modules/web/serverfarm/main.json index d77ee525e5..5dca04a299 100644 --- a/modules/web/serverfarm/main.json +++ b/modules/web/serverfarm/main.json @@ -4,15 +4,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5102051810775375915" - } + "version": "0.20.4.51522", + "templateHash": "10904675387778545087" + }, + "name": "App Service Plans", + "description": "This module deploys an App Service Plan.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { "type": "string", - "maxLength": 40, "minLength": 1, + "maxLength": 40, "metadata": { "description": "Required. The name of the app service plan to deploy." } @@ -91,14 +94,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -128,15 +131,6 @@ "description": "Optional. The name of the diagnostic setting, if deployed. If left empty, it defaults to \"-diagnosticSettings\"." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -193,11 +187,7 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ] @@ -302,8 +292,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "5292744640364919279" + "version": "0.20.4.51522", + "templateHash": "304746815992718029" } }, "parameters": { diff --git a/modules/web/site/.test/functionAppCommon/dependencies.bicep b/modules/web/site/.test/functionAppCommon/dependencies.bicep index c58bb47c3a..8aad6585b5 100644 --- a/modules/web/site/.test/functionAppCommon/dependencies.bicep +++ b/modules/web/site/.test/functionAppCommon/dependencies.bicep @@ -24,103 +24,103 @@ param hybridConnectionName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.azurewebsites.net' - location: 'global' + name: 'privatelink.azurewebsites.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource storageAccount 'Microsoft.Storage/storageAccounts@2021-09-01' = { - name: storageAccountName - location: location - sku: { - name: 'Standard_LRS' - } - kind: 'StorageV2' - properties: {} + name: storageAccountName + location: location + sku: { + name: 'Standard_LRS' + } + kind: 'StorageV2' + properties: {} } resource serverFarm 'Microsoft.Web/serverfarms@2022-03-01' = { - name: serverFarmName - location: location - sku: { - name: 'S1' - tier: 'Standard' - size: 'S1' - family: 'S' - capacity: 1 - } - properties: {} + name: serverFarmName + location: location + sku: { + name: 'S1' + tier: 'Standard' + size: 'S1' + family: 'S' + capacity: 1 + } + properties: {} } resource applicationInsights 'Microsoft.Insights/components@2020-02-02' = { - name: applicationInsightsName - location: location - kind: '' - properties: {} + name: applicationInsightsName + location: location + kind: '' + properties: {} } resource namespace 'Microsoft.Relay/namespaces@2021-11-01' = { - name: relayNamespaceName - location: location - sku: { - name: 'Standard' - } - properties: {} + name: relayNamespaceName + location: location + sku: { + name: 'Standard' + } + properties: {} } resource hybridConnection 'Microsoft.Relay/namespaces/hybridConnections@2021-11-01' = { - name: hybridConnectionName - parent: namespace - properties: { - requiresClientAuthorization: true - userMetadata: '[{"key":"endpoint","value":"db-server.constoso.com:1433"}]' - } + name: hybridConnectionName + parent: namespace + properties: { + requiresClientAuthorization: true + userMetadata: '[{"key":"endpoint","value":"db-server.constoso.com:1433"}]' + } } resource authorizationRule 'Microsoft.Relay/namespaces/hybridConnections/authorizationRules@2021-11-01' = { - name: 'defaultSender' - parent: hybridConnection - properties: { - rights: [ - 'Send' - ] - } + name: 'defaultSender' + parent: hybridConnection + properties: { + rights: [ + 'Send' + ] + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/web/site/.test/functionAppCommon/main.test.bicep b/modules/web/site/.test/functionAppCommon/main.test.bicep index ed5a59c4f7..4c966e89bb 100644 --- a/modules/web/site/.test/functionAppCommon/main.test.bicep +++ b/modules/web/site/.test/functionAppCommon/main.test.bicep @@ -140,7 +140,6 @@ module testDeployment '../../main.bicep' = { runtimeVersion: '~1' } } - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/web/site/.test/webAppCommon/dependencies.bicep b/modules/web/site/.test/webAppCommon/dependencies.bicep index 1642941bfb..66c92ec819 100644 --- a/modules/web/site/.test/webAppCommon/dependencies.bicep +++ b/modules/web/site/.test/webAppCommon/dependencies.bicep @@ -18,86 +18,86 @@ param hybridConnectionName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.azurewebsites.net' - location: 'global' + name: 'privatelink.azurewebsites.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource serverFarm 'Microsoft.Web/serverfarms@2022-03-01' = { - name: serverFarmName - location: location - sku: { - name: 'S1' - tier: 'Standard' - size: 'S1' - family: 'S' - capacity: 1 - } - properties: {} + name: serverFarmName + location: location + sku: { + name: 'S1' + tier: 'Standard' + size: 'S1' + family: 'S' + capacity: 1 + } + properties: {} } resource relayNamespace 'Microsoft.Relay/namespaces@2021-11-01' = { - name: relayNamespaceName - location: location - sku: { - name: 'Standard' - } - properties: {} + name: relayNamespaceName + location: location + sku: { + name: 'Standard' + } + properties: {} } resource hybridConnection 'Microsoft.Relay/namespaces/hybridConnections@2021-11-01' = { - name: hybridConnectionName - parent: relayNamespace - properties: { - requiresClientAuthorization: true - userMetadata: '[{"key":"endpoint","value":"db-server.constoso.com:1433"}]' - } + name: hybridConnectionName + parent: relayNamespace + properties: { + requiresClientAuthorization: true + userMetadata: '[{"key":"endpoint","value":"db-server.constoso.com:1433"}]' + } } resource authorizationRule 'Microsoft.Relay/namespaces/hybridConnections/authorizationRules@2021-11-01' = { - name: 'defaultSender' - parent: hybridConnection - properties: { - rights: [ - 'Send' - ] - } + name: 'defaultSender' + parent: hybridConnection + properties: { + rights: [ + 'Send' + ] + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/web/site/.test/webAppCommon/main.test.bicep b/modules/web/site/.test/webAppCommon/main.test.bicep index 78d71daac3..dd669262c0 100644 --- a/modules/web/site/.test/webAppCommon/main.test.bicep +++ b/modules/web/site/.test/webAppCommon/main.test.bicep @@ -68,7 +68,6 @@ module testDeployment '../../main.bicep' = { name: '${namePrefix}${serviceShort}001' kind: 'app' serverFarmResourceId: nestedDependencies.outputs.serverFarmResourceId - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId @@ -77,7 +76,6 @@ module testDeployment '../../main.bicep' = { slots: [ { name: 'slot1' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: diagnosticDependencies.outputs.storageAccountResourceId diagnosticWorkspaceId: diagnosticDependencies.outputs.logAnalyticsWorkspaceResourceId diagnosticEventHubAuthorizationRuleId: diagnosticDependencies.outputs.eventHubAuthorizationRuleId diff --git a/modules/web/site/README.md b/modules/web/site/README.md index d76222d28a..15b9c76197 100644 --- a/modules/web/site/README.md +++ b/modules/web/site/README.md @@ -19,8 +19,8 @@ This module deploys a Web or Function App. | `Microsoft.Authorization/roleAssignments` | [2020-10-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-10-01-preview/roleAssignments) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | | `Microsoft.Web/sites` | [2021-03-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Web/2021-03-01/sites) | | `Microsoft.Web/sites/basicPublishingCredentialsPolicies` | [2022-03-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Web/sites) | | `Microsoft.Web/sites/config` | [2022-03-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Web/sites) | @@ -59,7 +59,6 @@ This module deploys a Web or Function App. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[if(equals(parameters('kind'), 'functionapp'), createArray('FunctionAppLogs'), createArray('AppServiceHTTPLogs', 'AppServiceConsoleLogs', 'AppServiceAppLogs', 'AppServiceAuditLogs', 'AppServiceIPSecAuditLogs', 'AppServicePlatformLogs'))]` | `['', allLogs, AppServiceAppLogs, AppServiceAuditLogs, AppServiceConsoleLogs, AppServiceHTTPLogs, AppServiceIPSecAuditLogs, AppServicePlatformLogs, FunctionAppLogs]` | The name of logs that will be streamed. "allLogs" includes all possible logs for the resource. Set to '' to disable log collection. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | @@ -535,7 +534,6 @@ module site './web/site/main.bicep' = { } diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -689,9 +687,6 @@ module site './web/site/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, @@ -856,7 +851,6 @@ module site './web/site/main.bicep' = { ] diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' enableDefaultTelemetry: '' @@ -904,7 +898,6 @@ module site './web/site/main.bicep' = { { diagnosticEventHubAuthorizationRuleId: '' diagnosticEventHubName: '' - diagnosticLogsRetentionInDays: 7 diagnosticStorageAccountId: '' diagnosticWorkspaceId: '' hybridConnectionRelays: [ @@ -999,9 +992,6 @@ module site './web/site/main.bicep' = { "diagnosticEventHubName": { "value": "" }, - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "diagnosticStorageAccountId": { "value": "" }, @@ -1066,7 +1056,6 @@ module site './web/site/main.bicep' = { { "diagnosticEventHubAuthorizationRuleId": "", "diagnosticEventHubName": "", - "diagnosticLogsRetentionInDays": 7, "diagnosticStorageAccountId": "", "diagnosticWorkspaceId": "", "hybridConnectionRelays": [ diff --git a/modules/web/site/basic-publishing-credentials-policy/main.json b/modules/web/site/basic-publishing-credentials-policy/main.json index d590b4e2a4..a0fdbb05a0 100644 --- a/modules/web/site/basic-publishing-credentials-policy/main.json +++ b/modules/web/site/basic-publishing-credentials-policy/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6496735735518197935" - } + "version": "0.20.4.51522", + "templateHash": "8892331579235840311" + }, + "name": "Web Site Basic Publishing Credentials Policies", + "description": "This module deploys a Web Site Basic Publishing Credentials Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/web/site/config--appsettings/main.json b/modules/web/site/config--appsettings/main.json index cf46aaf47d..ce4da68102 100644 --- a/modules/web/site/config--appsettings/main.json +++ b/modules/web/site/config--appsettings/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8947665391771130821" - } + "version": "0.20.4.51522", + "templateHash": "18373728467474969101" + }, + "name": "Site App Settings", + "description": "This module deploys a Site App Setting.", + "owner": "Azure/module-maintainers" }, "parameters": { "appName": { diff --git a/modules/web/site/config--authsettingsv2/main.json b/modules/web/site/config--authsettingsv2/main.json index c1bcea1c4d..66fefc6307 100644 --- a/modules/web/site/config--authsettingsv2/main.json +++ b/modules/web/site/config--authsettingsv2/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12960661892407144506" - } + "version": "0.20.4.51522", + "templateHash": "17947854639766033581" + }, + "name": "Site Auth Settings V2 Config", + "description": "This module deploys a Site Auth Settings V2 Configuration.", + "owner": "Azure/module-maintainers" }, "parameters": { "appName": { diff --git a/modules/web/site/hybrid-connection-namespace/relay/main.json b/modules/web/site/hybrid-connection-namespace/relay/main.json index e8da9f0fa9..d9d30a2bea 100644 --- a/modules/web/site/hybrid-connection-namespace/relay/main.json +++ b/modules/web/site/hybrid-connection-namespace/relay/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11916683553936252746" - } + "version": "0.20.4.51522", + "templateHash": "2808108711462639357" + }, + "name": "Web/Function Apps Hybrid Connection Relay", + "description": "This module deploys a Site Hybrid Connection Namespace Relay.", + "owner": "Azure/module-maintainers" }, "parameters": { "hybridConnectionResourceId": { diff --git a/modules/web/site/main.bicep b/modules/web/site/main.bicep index f28d9d8599..95aea690e2 100644 --- a/modules/web/site/main.bicep +++ b/modules/web/site/main.bicep @@ -98,10 +98,6 @@ param enableDefaultTelemetry bool = true param roleAssignments array = [] // Diagnostic Settings -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -206,20 +202,12 @@ param hybridConnectionRelays array = [] var diagnosticsLogsSpecified = [for category in filter(diagnosticLogCategoriesToEnable, item => item != 'allLogs' && item != ''): { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsLogs = contains(diagnosticLogCategoriesToEnable, 'allLogs') ? [ { categoryGroup: 'allLogs' enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } } ] : contains(diagnosticLogCategoriesToEnable, '') ? [] : diagnosticsLogsSpecified @@ -227,10 +215,6 @@ var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var identityType = systemAssignedIdentity ? (!empty(userAssignedIdentities) ? 'SystemAssigned,UserAssigned' : 'SystemAssigned') : (!empty(userAssignedIdentities) ? 'UserAssigned' : 'None') @@ -334,7 +318,6 @@ module app_slots 'slot/main.bicep' = [for (slot, index) in slots: { setAzureWebJobsDashboard: contains(slot, 'setAzureWebJobsDashboard') ? slot.setAzureWebJobsDashboard : setAzureWebJobsDashboard authSettingV2Configuration: contains(slot, 'authSettingV2Configuration') ? slot.authSettingV2Configuration : authSettingV2Configuration enableDefaultTelemetry: enableReferencedModulesTelemetry - diagnosticLogsRetentionInDays: contains(slot, 'diagnosticLogsRetentionInDays') ? slot.diagnosticLogsRetentionInDays : diagnosticLogsRetentionInDays diagnosticStorageAccountId: contains(slot, 'diagnosticStorageAccountId') ? slot.diagnosticStorageAccountId : diagnosticStorageAccountId diagnosticWorkspaceId: contains(slot, 'diagnosticWorkspaceId') ? slot.diagnosticWorkspaceId : diagnosticWorkspaceId diagnosticEventHubAuthorizationRuleId: contains(slot, 'diagnosticEventHubAuthorizationRuleId') ? slot.diagnosticEventHubAuthorizationRuleId : diagnosticEventHubAuthorizationRuleId diff --git a/modules/web/site/main.json b/modules/web/site/main.json index 324a02b294..00917005c0 100644 --- a/modules/web/site/main.json +++ b/modules/web/site/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8556452883620957061" - } + "version": "0.20.4.51522", + "templateHash": "13974380780985159210" + }, + "name": "Web/Function Apps", + "description": "This module deploys a Web or Function App.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -142,14 +145,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "privateEndpoints": { "type": "array", @@ -186,15 +189,6 @@ "description": "Optional. Array of role assignment objects that contain the 'roleDefinitionIdOrName' and 'principalId' to define RBAC role assignments on this resource. In the roleDefinitionIdOrName attribute, you can provide either the display name of the role definition, or its fully qualified ID in the following format: '/providers/Microsoft.Authorization/roleDefinitions/c2f4ef07-c644-48eb-af81-4b1b4947fb11'." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -371,11 +365,7 @@ "count": "[length(filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), ''))))))]", "input": { "category": "[filter(parameters('diagnosticLogCategoriesToEnable'), lambda('item', and(not(equals(lambdaVariables('item'), 'allLogs')), not(equals(lambdaVariables('item'), '')))))[copyIndex('diagnosticsLogsSpecified')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -384,15 +374,11 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], - "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true(), 'retentionPolicy', createObject('enabled', true(), 'days', parameters('diagnosticLogsRetentionInDays')))), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", + "diagnosticsLogs": "[if(contains(parameters('diagnosticLogCategoriesToEnable'), 'allLogs'), createArray(createObject('categoryGroup', 'allLogs', 'enabled', true())), if(contains(parameters('diagnosticLogCategoriesToEnable'), ''), createArray(), variables('diagnosticsLogsSpecified')))]", "identityType": "[if(parameters('systemAssignedIdentity'), if(not(empty(parameters('userAssignedIdentities'))), 'SystemAssigned,UserAssigned', 'SystemAssigned'), if(not(empty(parameters('userAssignedIdentities'))), 'UserAssigned', 'None'))]", "identity": "[if(not(equals(variables('identityType'), 'None')), createObject('type', variables('identityType'), 'userAssignedIdentities', if(not(empty(parameters('userAssignedIdentities'))), parameters('userAssignedIdentities'), null())), null())]", "enableReferencedModulesTelemetry": false @@ -513,9 +499,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8947665391771130821" - } + "version": "0.20.4.51522", + "templateHash": "18373728467474969101" + }, + "name": "Site App Settings", + "description": "This module deploys a Site App Setting.", + "owner": "Azure/module-maintainers" }, "parameters": { "appName": { @@ -655,9 +644,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12960661892407144506" - } + "version": "0.20.4.51522", + "templateHash": "17947854639766033581" + }, + "name": "Site Auth Settings V2 Config", + "description": "This module deploys a Site Auth Settings V2 Configuration.", + "owner": "Azure/module-maintainers" }, "parameters": { "appName": { @@ -792,7 +784,6 @@ "enableDefaultTelemetry": { "value": "[variables('enableReferencedModulesTelemetry')]" }, - "diagnosticLogsRetentionInDays": "[if(contains(parameters('slots')[copyIndex()], 'diagnosticLogsRetentionInDays'), createObject('value', parameters('slots')[copyIndex()].diagnosticLogsRetentionInDays), createObject('value', parameters('diagnosticLogsRetentionInDays')))]", "diagnosticStorageAccountId": "[if(contains(parameters('slots')[copyIndex()], 'diagnosticStorageAccountId'), createObject('value', parameters('slots')[copyIndex()].diagnosticStorageAccountId), createObject('value', parameters('diagnosticStorageAccountId')))]", "diagnosticWorkspaceId": "[if(contains(parameters('slots')[copyIndex()], 'diagnosticWorkspaceId'), createObject('value', parameters('slots')[copyIndex()].diagnosticWorkspaceId), createObject('value', parameters('diagnosticWorkspaceId')))]", "diagnosticEventHubAuthorizationRuleId": "[if(contains(parameters('slots')[copyIndex()], 'diagnosticEventHubAuthorizationRuleId'), createObject('value', parameters('slots')[copyIndex()].diagnosticEventHubAuthorizationRuleId), createObject('value', parameters('diagnosticEventHubAuthorizationRuleId')))]", @@ -829,9 +820,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13778120720358101018" - } + "version": "0.20.4.51522", + "templateHash": "16902564518059278998" + }, + "name": "Web/Function App Deployment Slots", + "description": "This module deploys a Web or Function App Deployment Slot.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -974,14 +968,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "privateEndpoints": { "type": "array", @@ -1011,15 +1005,6 @@ "description": "Optional. Array of role assignment objects that contain the 'roleDefinitionIdOrName' and 'principalId' to define RBAC role assignments on this resource. In the roleDefinitionIdOrName attribute, you can provide either the display name of the role definition, or its fully qualified ID in the following format: '/providers/Microsoft.Authorization/roleDefinitions/c2f4ef07-c644-48eb-af81-4b1b4947fb11'." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -1220,11 +1205,7 @@ "count": "[length(parameters('diagnosticLogCategoriesToEnable'))]", "input": { "category": "[parameters('diagnosticLogCategoriesToEnable')[copyIndex('diagnosticsLogs')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -1233,11 +1214,7 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], @@ -1368,9 +1345,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3348890338028712435" - } + "version": "0.20.4.51522", + "templateHash": "5493142537935111696" + }, + "name": "Site Slot App Settings", + "description": "This module deploys a Site Slot App Setting.", + "owner": "Azure/module-maintainers" }, "parameters": { "slotName": { @@ -1519,9 +1499,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4506238262937483474" - } + "version": "0.20.4.51522", + "templateHash": "9353145154752028146" + }, + "name": "Site Slot Auth Settings V2 Config", + "description": "This module deploys a Site Auth Settings V2 Configuration.", + "owner": "Azure/module-maintainers" }, "parameters": { "appName": { @@ -1649,9 +1632,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10162571329501184760" - } + "version": "0.20.4.51522", + "templateHash": "18138499386350818749" + }, + "name": "Web/Function Apps Slot Hybrid Connection Relay", + "description": "This module deploys a Site Slot Hybrid Connection Namespace Relay.", + "owner": "Azure/module-maintainers" }, "parameters": { "hybridConnectionResourceId": { @@ -1786,8 +1772,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6058525857462854449" + "version": "0.20.4.51522", + "templateHash": "17495218577109675288" } }, "parameters": { @@ -1926,9 +1912,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1993,14 +1982,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -2058,7 +2047,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -2123,9 +2112,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -2136,8 +2128,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -2188,7 +2180,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -2258,8 +2250,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -2429,7 +2421,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } @@ -2512,9 +2504,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6496735735518197935" - } + "version": "0.20.4.51522", + "templateHash": "8892331579235840311" + }, + "name": "Web Site Basic Publishing Credentials Policies", + "description": "This module deploys a Web Site Basic Publishing Credentials Policy.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -2640,9 +2635,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11916683553936252746" - } + "version": "0.20.4.51522", + "templateHash": "2808108711462639357" + }, + "name": "Web/Function Apps Hybrid Connection Relay", + "description": "This module deploys a Site Hybrid Connection Namespace Relay.", + "owner": "Azure/module-maintainers" }, "parameters": { "hybridConnectionResourceId": { @@ -2773,8 +2771,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "16625824009136107504" + "version": "0.20.4.51522", + "templateHash": "12172515144547720998" } }, "parameters": { @@ -2942,9 +2940,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -3009,14 +3010,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -3074,7 +3075,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -3139,9 +3140,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -3152,8 +3156,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -3204,7 +3208,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -3274,8 +3278,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -3445,7 +3449,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } diff --git a/modules/web/site/slot/README.md b/modules/web/site/slot/README.md index 639cae1ebd..4e7a78d912 100644 --- a/modules/web/site/slot/README.md +++ b/modules/web/site/slot/README.md @@ -18,8 +18,8 @@ This module deploys a Web or Function App Deployment Slot. | `Microsoft.Authorization/roleAssignments` | [2020-10-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-10-01-preview/roleAssignments) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | | `Microsoft.Insights/diagnosticSettings` | [2021-05-01-preview](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Insights/2021-05-01-preview/diagnosticSettings) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | | `Microsoft.Web/sites/slots` | [2022-03-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Web/2022-03-01/sites/slots) | | `Microsoft.Web/sites/slots/config` | [2022-03-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Web/sites) | | `Microsoft.Web/sites/slots/hybridConnectionNamespaces/relays` | [2022-03-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Web/2022-03-01/sites/slots/hybridConnectionNamespaces/relays) | @@ -58,7 +58,6 @@ This module deploys a Web or Function App Deployment Slot. | `diagnosticEventHubAuthorizationRuleId` | string | `''` | | Resource ID of the diagnostic event hub authorization rule for the Event Hubs namespace in which the event hub should be created or streamed to. | | `diagnosticEventHubName` | string | `''` | | Name of the diagnostic event hub within the namespace to which logs are streamed. Without this, an event hub is created for each log category. | | `diagnosticLogCategoriesToEnable` | array | `[if(equals(parameters('kind'), 'functionapp'), createArray('FunctionAppLogs'), createArray('AppServiceHTTPLogs', 'AppServiceConsoleLogs', 'AppServiceAppLogs', 'AppServiceAuditLogs', 'AppServiceIPSecAuditLogs', 'AppServicePlatformLogs'))]` | `[AppServiceAppLogs, AppServiceAuditLogs, AppServiceConsoleLogs, AppServiceHTTPLogs, AppServiceIPSecAuditLogs, AppServicePlatformLogs, FunctionAppLogs]` | The name of logs that will be streamed. | -| `diagnosticLogsRetentionInDays` | int | `365` | | Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely. | | `diagnosticMetricsToEnable` | array | `[AllMetrics]` | `[AllMetrics]` | The name of metrics that will be streamed. | | `diagnosticSettingsName` | string | `''` | | The name of the diagnostic setting, if deployed. If left empty, it defaults to "-diagnosticSettings". | | `diagnosticStorageAccountId` | string | `''` | | Resource ID of the diagnostic storage account. | diff --git a/modules/web/site/slot/config--appsettings/main.json b/modules/web/site/slot/config--appsettings/main.json index 2f7a67ebd9..594f72e5f3 100644 --- a/modules/web/site/slot/config--appsettings/main.json +++ b/modules/web/site/slot/config--appsettings/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3348890338028712435" - } + "version": "0.20.4.51522", + "templateHash": "5493142537935111696" + }, + "name": "Site Slot App Settings", + "description": "This module deploys a Site Slot App Setting.", + "owner": "Azure/module-maintainers" }, "parameters": { "slotName": { diff --git a/modules/web/site/slot/config--authsettingsv2/main.json b/modules/web/site/slot/config--authsettingsv2/main.json index 082efc4a17..0511d830c2 100644 --- a/modules/web/site/slot/config--authsettingsv2/main.json +++ b/modules/web/site/slot/config--authsettingsv2/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4506238262937483474" - } + "version": "0.20.4.51522", + "templateHash": "9353145154752028146" + }, + "name": "Site Slot Auth Settings V2 Config", + "description": "This module deploys a Site Auth Settings V2 Configuration.", + "owner": "Azure/module-maintainers" }, "parameters": { "appName": { diff --git a/modules/web/site/slot/hybrid-connection-namespace/relay/main.json b/modules/web/site/slot/hybrid-connection-namespace/relay/main.json index a8d51d1f58..221ed4d8dc 100644 --- a/modules/web/site/slot/hybrid-connection-namespace/relay/main.json +++ b/modules/web/site/slot/hybrid-connection-namespace/relay/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10162571329501184760" - } + "version": "0.20.4.51522", + "templateHash": "18138499386350818749" + }, + "name": "Web/Function Apps Slot Hybrid Connection Relay", + "description": "This module deploys a Site Slot Hybrid Connection Namespace Relay.", + "owner": "Azure/module-maintainers" }, "parameters": { "hybridConnectionResourceId": { diff --git a/modules/web/site/slot/main.bicep b/modules/web/site/slot/main.bicep index 75871fe8dd..f293bc18d1 100644 --- a/modules/web/site/slot/main.bicep +++ b/modules/web/site/slot/main.bicep @@ -97,10 +97,6 @@ param enableDefaultTelemetry bool = true param roleAssignments array = [] // Diagnostic Settings -@description('Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely.') -@minValue(0) -@maxValue(365) -param diagnosticLogsRetentionInDays int = 365 @description('Optional. Resource ID of the diagnostic storage account.') param diagnosticStorageAccountId string = '' @@ -217,20 +213,12 @@ param hybridConnectionRelays array = [] var diagnosticsLogs = [for category in diagnosticLogCategoriesToEnable: { category: category enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var diagnosticsMetrics = [for metric in diagnosticMetricsToEnable: { category: metric timeGrain: null enabled: true - retentionPolicy: { - enabled: true - days: diagnosticLogsRetentionInDays - } }] var identityType = systemAssignedIdentity ? (!empty(userAssignedIdentities) ? 'SystemAssigned,UserAssigned' : 'SystemAssigned') : (!empty(userAssignedIdentities) ? 'UserAssigned' : 'None') diff --git a/modules/web/site/slot/main.json b/modules/web/site/slot/main.json index 1195d9c1d2..e2d9a3c9ae 100644 --- a/modules/web/site/slot/main.json +++ b/modules/web/site/slot/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "13778120720358101018" - } + "version": "0.20.4.51522", + "templateHash": "16902564518059278998" + }, + "name": "Web/Function App Deployment Slots", + "description": "This module deploys a Web or Function App Deployment Slot.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -149,14 +152,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "privateEndpoints": { "type": "array", @@ -186,15 +189,6 @@ "description": "Optional. Array of role assignment objects that contain the 'roleDefinitionIdOrName' and 'principalId' to define RBAC role assignments on this resource. In the roleDefinitionIdOrName attribute, you can provide either the display name of the role definition, or its fully qualified ID in the following format: '/providers/Microsoft.Authorization/roleDefinitions/c2f4ef07-c644-48eb-af81-4b1b4947fb11'." } }, - "diagnosticLogsRetentionInDays": { - "type": "int", - "defaultValue": 365, - "maxValue": 365, - "minValue": 0, - "metadata": { - "description": "Optional. Specifies the number of days that logs will be kept for; a value of 0 will retain data indefinitely." - } - }, "diagnosticStorageAccountId": { "type": "string", "defaultValue": "", @@ -395,11 +389,7 @@ "count": "[length(parameters('diagnosticLogCategoriesToEnable'))]", "input": { "category": "[parameters('diagnosticLogCategoriesToEnable')[copyIndex('diagnosticsLogs')]]", - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } }, { @@ -408,11 +398,7 @@ "input": { "category": "[parameters('diagnosticMetricsToEnable')[copyIndex('diagnosticsMetrics')]]", "timeGrain": null, - "enabled": true, - "retentionPolicy": { - "enabled": true, - "days": "[parameters('diagnosticLogsRetentionInDays')]" - } + "enabled": true } } ], @@ -543,9 +529,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "3348890338028712435" - } + "version": "0.20.4.51522", + "templateHash": "5493142537935111696" + }, + "name": "Site Slot App Settings", + "description": "This module deploys a Site Slot App Setting.", + "owner": "Azure/module-maintainers" }, "parameters": { "slotName": { @@ -694,9 +683,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "4506238262937483474" - } + "version": "0.20.4.51522", + "templateHash": "9353145154752028146" + }, + "name": "Site Slot Auth Settings V2 Config", + "description": "This module deploys a Site Auth Settings V2 Configuration.", + "owner": "Azure/module-maintainers" }, "parameters": { "appName": { @@ -824,9 +816,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "10162571329501184760" - } + "version": "0.20.4.51522", + "templateHash": "18138499386350818749" + }, + "name": "Web/Function Apps Slot Hybrid Connection Relay", + "description": "This module deploys a Site Slot Hybrid Connection Namespace Relay.", + "owner": "Azure/module-maintainers" }, "parameters": { "hybridConnectionResourceId": { @@ -961,8 +956,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "6058525857462854449" + "version": "0.20.4.51522", + "templateHash": "17495218577109675288" } }, "parameters": { @@ -1101,9 +1096,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -1168,14 +1166,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -1233,7 +1231,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -1298,9 +1296,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -1311,8 +1312,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -1363,7 +1364,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -1433,8 +1434,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -1604,7 +1605,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } diff --git a/modules/web/static-site/.test/common/dependencies.bicep b/modules/web/static-site/.test/common/dependencies.bicep index 83aa7bcd46..8a181924d6 100644 --- a/modules/web/static-site/.test/common/dependencies.bicep +++ b/modules/web/static-site/.test/common/dependencies.bicep @@ -15,67 +15,67 @@ param serverFarmName string var addressPrefix = '10.0.0.0/16' -resource virtualNetwork 'Microsoft.Network/virtualNetworks@2022-01-01' = { - name: virtualNetworkName - location: location - properties: { - addressSpace: { - addressPrefixes: [ - addressPrefix - ] - } - subnets: [ - { - name: 'defaultSubnet' - properties: { - addressPrefix: addressPrefix - } - } - ] +resource virtualNetwork 'Microsoft.Network/virtualNetworks@2023-04-01' = { + name: virtualNetworkName + location: location + properties: { + addressSpace: { + addressPrefixes: [ + addressPrefix + ] } + subnets: [ + { + name: 'defaultSubnet' + properties: { + addressPrefix: addressPrefix + } + } + ] + } } resource privateDNSZone 'Microsoft.Network/privateDnsZones@2020-06-01' = { - name: 'privatelink.azurestaticapps.net' - location: 'global' + name: 'privatelink.azurestaticapps.net' + location: 'global' - resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { - name: '${virtualNetwork.name}-vnetlink' - location: 'global' - properties: { - virtualNetwork: { - id: virtualNetwork.id - } - registrationEnabled: false - } + resource virtualNetworkLinks 'virtualNetworkLinks@2020-06-01' = { + name: '${virtualNetwork.name}-vnetlink' + location: 'global' + properties: { + virtualNetwork: { + id: virtualNetwork.id + } + registrationEnabled: false } + } } resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2018-11-30' = { - name: managedIdentityName - location: location + name: managedIdentityName + location: location } resource serverFarm 'Microsoft.Web/serverfarms@2022-03-01' = { - name: serverFarmName - location: location - sku: { - name: 'S1' - tier: 'Standard' - size: 'S1' - family: 'S' - capacity: 1 - } - properties: {} + name: serverFarmName + location: location + sku: { + name: 'S1' + tier: 'Standard' + size: 'S1' + family: 'S' + capacity: 1 + } + properties: {} } resource functionApp 'Microsoft.Web/sites@2022-03-01' = { - name: siteName - location: location - kind: 'functionapp' - properties: { - serverFarmId: serverFarm.id - } + name: siteName + location: location + kind: 'functionapp' + properties: { + serverFarmId: serverFarm.id + } } @description('The resource ID of the created Virtual Network Subnet.') diff --git a/modules/web/static-site/README.md b/modules/web/static-site/README.md index 5c552478a4..ed1b374c88 100644 --- a/modules/web/static-site/README.md +++ b/modules/web/static-site/README.md @@ -16,8 +16,8 @@ This module deploys a Static Web App. | :-- | :-- | | `Microsoft.Authorization/locks` | [2020-05-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2020-05-01/locks) | | `Microsoft.Authorization/roleAssignments` | [2022-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Authorization/2022-04-01/roleAssignments) | -| `Microsoft.Network/privateEndpoints` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints) | -| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2022-07-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2022-07-01/privateEndpoints/privateDnsZoneGroups) | +| `Microsoft.Network/privateEndpoints` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints) | +| `Microsoft.Network/privateEndpoints/privateDnsZoneGroups` | [2023-04-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Network/2023-04-01/privateEndpoints/privateDnsZoneGroups) | | `Microsoft.Web/staticSites` | [2021-03-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Web/2021-03-01/staticSites) | | `Microsoft.Web/staticSites/config` | [2022-03-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Web/staticSites/config) | | `Microsoft.Web/staticSites/customDomains` | [2022-03-01](https://learn.microsoft.com/en-us/azure/templates/Microsoft.Web/2022-03-01/staticSites/customDomains) | diff --git a/modules/web/static-site/config/main.json b/modules/web/static-site/config/main.json index e3f329b1c0..117377cfd0 100644 --- a/modules/web/static-site/config/main.json +++ b/modules/web/static-site/config/main.json @@ -4,20 +4,23 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12376748263215313179" - } + "version": "0.20.4.51522", + "templateHash": "5981963633647576119" + }, + "name": "Static Web App Site Config", + "description": "This module deploys a Static Web App Site Config.", + "owner": "Azure/module-maintainers" }, "parameters": { "kind": { "type": "string", - "metadata": { - "description": "Required. Type of settings to apply." - }, "allowedValues": [ "appsettings", "functionappsettings" - ] + ], + "metadata": { + "description": "Required. Type of settings to apply." + } }, "properties": { "type": "object", diff --git a/modules/web/static-site/custom-domain/main.json b/modules/web/static-site/custom-domain/main.json index b1961db961..df87e1cfb4 100644 --- a/modules/web/static-site/custom-domain/main.json +++ b/modules/web/static-site/custom-domain/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12195390626164178443" - } + "version": "0.20.4.51522", + "templateHash": "12334533883169216576" + }, + "name": "Static Web App Site Custom Domains", + "description": "This module deploys a Static Web App Site Custom Domain.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { diff --git a/modules/web/static-site/linked-backend/main.json b/modules/web/static-site/linked-backend/main.json index 4dea2ef44e..daa994ad65 100644 --- a/modules/web/static-site/linked-backend/main.json +++ b/modules/web/static-site/linked-backend/main.json @@ -4,9 +4,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8648101447208201436" - } + "version": "0.20.4.51522", + "templateHash": "7461352396319136343" + }, + "name": "Static Web App Site Linked Backends", + "description": "This module deploys a Custom Function App into a Static Web App Site using the Linked Backends property.", + "owner": "Azure/module-maintainers" }, "parameters": { "backendResourceId": { diff --git a/modules/web/static-site/main.json b/modules/web/static-site/main.json index 796c2d8628..c12fbd8ee3 100644 --- a/modules/web/static-site/main.json +++ b/modules/web/static-site/main.json @@ -4,15 +4,18 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "9306291304981639951" - } + "version": "0.20.4.51522", + "templateHash": "12552939286678689828" + }, + "name": "Static Web Apps", + "description": "This module deploys a Static Web App.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { "type": "string", - "maxLength": 40, "minLength": 1, + "maxLength": 40, "metadata": { "description": "Required. Name of the static site." } @@ -20,13 +23,13 @@ "sku": { "type": "string", "defaultValue": "Free", - "metadata": { - "description": "Optional. Type of static site to deploy." - }, "allowedValues": [ "Free", "Standard" - ] + ], + "metadata": { + "description": "Optional. Type of static site to deploy." + } }, "allowConfigFileUpdates": { "type": "bool", @@ -45,26 +48,26 @@ "stagingEnvironmentPolicy": { "type": "string", "defaultValue": "Enabled", - "metadata": { - "description": "Optional. State indicating whether staging environments are allowed or not allowed for a static web app." - }, "allowedValues": [ "Enabled", "Disabled" - ] + ], + "metadata": { + "description": "Optional. State indicating whether staging environments are allowed or not allowed for a static web app." + } }, "enterpriseGradeCdnStatus": { "type": "string", "defaultValue": "Disabled", - "metadata": { - "description": "Optional. State indicating the status of the enterprise grade CDN serving traffic to the static web app." - }, "allowedValues": [ "Disabled", "Disabling", "Enabled", "Enabling" - ] + ], + "metadata": { + "description": "Optional. State indicating the status of the enterprise grade CDN serving traffic to the static web app." + } }, "buildProperties": { "type": "object", @@ -125,14 +128,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "privateEndpoints": { "type": "array", @@ -276,9 +279,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "8648101447208201436" - } + "version": "0.20.4.51522", + "templateHash": "7461352396319136343" + }, + "name": "Static Web App Site Linked Backends", + "description": "This module deploys a Custom Function App into a Static Web App Site using the Linked Backends property.", + "owner": "Azure/module-maintainers" }, "parameters": { "backendResourceId": { @@ -406,20 +412,23 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12376748263215313179" - } + "version": "0.20.4.51522", + "templateHash": "5981963633647576119" + }, + "name": "Static Web App Site Config", + "description": "This module deploys a Static Web App Site Config.", + "owner": "Azure/module-maintainers" }, "parameters": { "kind": { "type": "string", - "metadata": { - "description": "Required. Type of settings to apply." - }, "allowedValues": [ "appsettings", "functionappsettings" - ] + ], + "metadata": { + "description": "Required. Type of settings to apply." + } }, "properties": { "type": "object", @@ -529,20 +538,23 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12376748263215313179" - } + "version": "0.20.4.51522", + "templateHash": "5981963633647576119" + }, + "name": "Static Web App Site Config", + "description": "This module deploys a Static Web App Site Config.", + "owner": "Azure/module-maintainers" }, "parameters": { "kind": { "type": "string", - "metadata": { - "description": "Required. Type of settings to apply." - }, "allowedValues": [ "appsettings", "functionappsettings" - ] + ], + "metadata": { + "description": "Required. Type of settings to apply." + } }, "properties": { "type": "object", @@ -653,9 +665,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12195390626164178443" - } + "version": "0.20.4.51522", + "templateHash": "12334533883169216576" + }, + "name": "Static Web App Site Custom Domains", + "description": "This module deploys a Static Web App Site Custom Domain.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -775,8 +790,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "15458581898010442411" + "version": "0.20.4.51522", + "templateHash": "16510980031659768154" } }, "parameters": { @@ -888,9 +903,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "11825715538543749879" - } + "version": "0.20.4.51522", + "templateHash": "13560297539192628062" + }, + "name": "Private Endpoints", + "description": "This module deploys a Private Endpoint.", + "owner": "Azure/module-maintainers" }, "parameters": { "name": { @@ -955,14 +973,14 @@ "lock": { "type": "string", "defaultValue": "", - "metadata": { - "description": "Optional. Specify the type of lock." - }, "allowedValues": [ "", "CanNotDelete", "ReadOnly" - ] + ], + "metadata": { + "description": "Optional. Specify the type of lock." + } }, "roleAssignments": { "type": "array", @@ -1020,7 +1038,7 @@ }, { "type": "Microsoft.Network/privateEndpoints", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[parameters('name')]", "location": "[parameters('location')]", "tags": "[parameters('tags')]", @@ -1085,9 +1103,12 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "12684511314187066258" - } + "version": "0.20.4.51522", + "templateHash": "17831763001460207830" + }, + "name": "Private Endpoint Private DNS Zone Groups", + "description": "This module deploys a Private Endpoint Private DNS Zone Group.", + "owner": "Azure/module-maintainers" }, "parameters": { "privateEndpointName": { @@ -1098,8 +1119,8 @@ }, "privateDNSResourceIds": { "type": "array", - "maxLength": 5, "minLength": 1, + "maxLength": 5, "metadata": { "description": "Required. Array of private DNS zone resource IDs. A DNS zone group can support up to 5 DNS zones." } @@ -1150,7 +1171,7 @@ }, { "type": "Microsoft.Network/privateEndpoints/privateDnsZoneGroups", - "apiVersion": "2022-07-01", + "apiVersion": "2023-04-01", "name": "[format('{0}/{1}', parameters('privateEndpointName'), parameters('name'))]", "properties": { "privateDnsZoneConfigs": "[variables('privateDnsZoneConfigs')]" @@ -1220,8 +1241,8 @@ "metadata": { "_generator": { "name": "bicep", - "version": "0.19.5.34762", - "templateHash": "18055161250379920591" + "version": "0.20.4.51522", + "templateHash": "11548486149222715894" } }, "parameters": { @@ -1391,7 +1412,7 @@ "metadata": { "description": "The location the resource was deployed into." }, - "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2022-07-01', 'full').location]" + "value": "[reference(resourceId('Microsoft.Network/privateEndpoints', parameters('name')), '2023-04-01', 'full').location]" } } } diff --git a/utilities/tools/Invoke-PipelinesForBranch.ps1 b/utilities/tools/Invoke-PipelinesForBranch.ps1 index 9c55cc9777..22d3e9e37b 100644 --- a/utilities/tools/Invoke-PipelinesForBranch.ps1 +++ b/utilities/tools/Invoke-PipelinesForBranch.ps1 @@ -193,7 +193,7 @@ Optional. The Azure DevOps project to run the pipelines in. Required if the chos Optional. The folder in Azure DevOps the pipelines are registerd in. Required if the chosen environment is `AzureDevOps`. Defaults to 'CARML-Modules'. .EXAMPLE -Invoke-PipelinesForBranch -PersonalAccessToken '' -TargetBranch 'feature/branch' -Environment 'GitHub' -PipelineFilter 'ms.network.*' -GitHubPipelineInputs @{ prerelease = 'false'; deploymentValidation = 'false'; removeDeployment = 'true' } +Invoke-PipelinesForBranch -PersonalAccessToken '' -TargetBranch 'feature/branch' -Environment 'GitHub' -PipelineFilter 'ms.network.*' -GitHubPipelineInputs @{ prerelease = 'false'; staticValidation = 'true'; deploymentValidation = 'true'; removeDeployment = 'true' } Run all GitHub workflows that start with 'ms.network.*' using branch 'feature/branch'. Also returns all GitHub status badges. diff --git a/utilities/tools/Set-ModuleReadMe.ps1 b/utilities/tools/Set-ModuleReadMe.ps1 index c9f9a169c6..9f55b4cca6 100644 --- a/utilities/tools/Set-ModuleReadMe.ps1 +++ b/utilities/tools/Set-ModuleReadMe.ps1 @@ -492,13 +492,12 @@ Mandatory. The JSON parameters block to process (ideally already without 'value' Mandatory. A list of all required top-level (i.e. non-nested) parameter names .EXAMPLE -Get-OrderedParametersJSON -RequiredParametersList @('name') -ParametersJSON '{ "diagnosticLogsRetentionInDays": 7,"lock": "CanNotDelete","name": "carml" }' +Get-OrderedParametersJSON -RequiredParametersList @('name') -ParametersJSON '{ "lock": "CanNotDelete","name": "carml" }' Order the given JSON object alphabetically. Would result into: @{ name: 'carml' - diagnosticLogsRetentionInDays: 7 lock: 'CanNotDelete' } #> @@ -551,7 +550,7 @@ Mandatory. The parameter JSON object to process Mandatory. A list of all required top-level (i.e. non-nested) parameter names .EXAMPLE -Build-OrderedJSONObject -RequiredParametersList @('name') -ParametersJSON '{ "lock": { "value": "CanNotDelete" }, "name": { "value": "carml" }, "diagnosticLogsRetentionInDays": { "value": 7 } }' +Build-OrderedJSONObject -RequiredParametersList @('name') -ParametersJSON '{ "lock": { "value": "CanNotDelete" }, "name": { "value": "carml" } }' Build a formatted Parameter-JSON object with one required parameter. Would result into: @@ -564,9 +563,6 @@ Build a formatted Parameter-JSON object with one required parameter. Would resul "value": "carml" }, // Non-required parameters - "diagnosticLogsRetentionInDays": { - "value": 7 - }, "lock": { "value": "CanNotDelete" } @@ -792,7 +788,6 @@ Convert the given JSONParameters object with one required parameter to a formatt // Required parameters name: 'carml' // Non-required parameters - diagnosticLogsRetentionInDays: 7 lock: 'CanNotDelete' ' #>