diff --git a/modules/Microsoft.ContainerService/managedClusters/.test/min/deploy.test.bicep b/modules/Microsoft.ContainerService/managedClusters/.test/min/deploy.test.bicep new file mode 100644 index 0000000000..b752b96308 --- /dev/null +++ b/modules/Microsoft.ContainerService/managedClusters/.test/min/deploy.test.bicep @@ -0,0 +1,47 @@ +targetScope = 'subscription' + +// ========== // +// Parameters // +// ========== // + +@description('Optional. The name of the resource group to deploy for testing purposes.') +@maxLength(90) +param resourceGroupName string = 'ms.containerservice.managedclusters-${serviceShort}-rg' + +@description('Optional. The location to deploy resources to.') +param location string = deployment().location + +@description('Optional. A short identifier for the kind of deployment. Should be kept short to not run into resource-name length-constraints.') +param serviceShort string = 'csmmin' + +@description('Optional. Enable telemetry via a Globally Unique Identifier (GUID).') +param enableDefaultTelemetry bool = true + +// ============ // +// Dependencies // +// ============ // + +// General resources +// ================= +resource resourceGroup 'Microsoft.Resources/resourceGroups@2021-04-01' = { + name: resourceGroupName + location: location +} + +module testDeployment '../../deploy.bicep' = { + scope: resourceGroup + name: '${uniqueString(deployment().name, location)}-test-${serviceShort}' + params: { + name: '${serviceShort}001' + enableDefaultTelemetry: enableDefaultTelemetry + systemAssignedIdentity: true + primaryAgentPoolProfile: [ + { + name: 'systempool' + count: 1 + vmSize: 'Standard_DS2_v2' + mode: 'System' + } + ] + } +} diff --git a/modules/Microsoft.ContainerService/managedClusters/readme.md b/modules/Microsoft.ContainerService/managedClusters/readme.md index 357423610f..9765daf02e 100644 --- a/modules/Microsoft.ContainerService/managedClusters/readme.md +++ b/modules/Microsoft.ContainerService/managedClusters/readme.md @@ -865,3 +865,70 @@ module managedClusters './Microsoft.ContainerService/managedClusters/deploy.bice
+ +
+
+via JSON Parameter file
+
+```json
+{
+ "$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentParameters.json#",
+ "contentVersion": "1.0.0.0",
+ "parameters": {
+ // Required parameters
+ "name": {
+ "value": "csmmin001"
+ },
+ "primaryAgentPoolProfile": {
+ "value": [
+ {
+ "count": 1,
+ "mode": "System",
+ "name": "systempool",
+ "vmSize": "Standard_DS2_v2"
+ }
+ ]
+ },
+ // Non-required parameters
+ "enableDefaultTelemetry": {
+ "value": "