From 0f82cfaeaf4cba3277e64aaa1c939df41bc644df Mon Sep 17 00:00:00 2001 From: Lyle Xu Date: Fri, 26 Apr 2024 11:01:53 +0800 Subject: [PATCH] remove environment name --- Environments/Todo-Mongo-AKS-LA/main.bicep | 13 +------------ Environments/Todo-Mongo-AKS-LA/manifest.yaml | 6 ------ 2 files changed, 1 insertion(+), 18 deletions(-) diff --git a/Environments/Todo-Mongo-AKS-LA/main.bicep b/Environments/Todo-Mongo-AKS-LA/main.bicep index a2d1c00..5b937ae 100644 --- a/Environments/Todo-Mongo-AKS-LA/main.bicep +++ b/Environments/Todo-Mongo-AKS-LA/main.bicep @@ -1,8 +1,3 @@ -@minLength(1) -@maxLength(64) -@description('Name of the the environment which is used to generate a short unique hash used in all resources.') -param environmentName string - @minLength(1) @description('Primary location for all resources') param location string = resourceGroup().location @@ -17,8 +12,7 @@ param sharedAKSEnvironmentName string var sharedAKSResourceGroup = '${sharedAKSProjectName}-${sharedAKSEnvironmentName}' var abbrs = loadJsonContent('./abbreviations.json') -var resourceToken = toLower(uniqueString(subscription().id, environmentName, location)) -var tags = { 'azd-env-name': environmentName } +var resourceToken = toLower(uniqueString(subscription().id, resourceGroup().id, location)) // Store secrets in a keyvault module keyVault './core/security/keyvault.bicep' = { @@ -26,7 +20,6 @@ module keyVault './core/security/keyvault.bicep' = { params: { name: !empty(keyVaultName) ? keyVaultName : '${abbrs.keyVaultVaults}${resourceToken}' location: location - tags: tags principalId: principalId } } @@ -64,7 +57,6 @@ module cosmos './app/db.bicep' = { accountName: !empty(cosmosAccountName) ? cosmosAccountName : '${abbrs.documentDBDatabaseAccounts}${resourceToken}' databaseName: cosmosDatabaseName location: location - tags: tags keyVaultName: keyVault.outputs.name } } @@ -87,7 +79,6 @@ resource configStoreKeyValue 'Microsoft.AppConfiguration/configurationStores/key properties: { value: cosmos.outputs.connectionStringKey contentType: contentType - tags: tags } } @@ -97,7 +88,6 @@ resource configStoreKeyValue2 'Microsoft.AppConfiguration/configurationStores/ke properties: { value: cosmos.outputs.databaseName contentType: contentType - tags: tags } } @@ -107,7 +97,6 @@ resource configStoreKeyValue3 'Microsoft.AppConfiguration/configurationStores/ke properties: { value: keyVault.outputs.endpoint contentType: contentType - tags: tags } } diff --git a/Environments/Todo-Mongo-AKS-LA/manifest.yaml b/Environments/Todo-Mongo-AKS-LA/manifest.yaml index ae84c16..ae78745 100644 --- a/Environments/Todo-Mongo-AKS-LA/manifest.yaml +++ b/Environments/Todo-Mongo-AKS-LA/manifest.yaml @@ -6,12 +6,6 @@ runner: ARM templatePath: azuredeploy.json parameters: -- id: "environmentName" - name: "Environment Name (e.g. testenv)" - description: "Name of the Environment" - type: string - required: true - - id: "location" name: "Region (e.g. eastus)" description: "Location of the resources"