From 956ed39551dad4fedde49656bdca0c9040530519 Mon Sep 17 00:00:00 2001 From: AlexanderSehr Date: Thu, 24 Oct 2024 16:51:52 +0200 Subject: [PATCH] Update to latest --- avm/utl/types/avm-common-types/README.md | 6 +-- avm/utl/types/avm-common-types/main.bicep | 1 + avm/utl/types/avm-common-types/main.json | 47 ++++++++++--------- .../tests/e2e/import/main.test.bicep | 6 +-- 4 files changed, 31 insertions(+), 29 deletions(-) diff --git a/avm/utl/types/avm-common-types/README.md b/avm/utl/types/avm-common-types/README.md index 97107533ab..26bc5bfc2b 100644 --- a/avm/utl/types/avm-common-types/README.md +++ b/avm/utl/types/avm-common-types/README.md @@ -65,7 +65,7 @@ import { privateEndpointMultiServiceType privateEndpointSingleServiceType secretToSetType - secretSetType + secretSetOutputType } from '../../../main.bicep' // Would be: br/public:avm/utl/types/avm-common-types: // ====================== // @@ -309,14 +309,14 @@ param secretToSet secretToSetType[] = [ #disable-next-line outputs-should-not-contain-secrets // Does not contain a secret output secretToSetOutput secretToSetType[] = secretToSet -param secretSet secretSetType[] = [ +param secretSet secretSetOutputType[] = [ { secretResourceId: '/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myRg/providers/Microsoft.KeyVault/vaults/myVault/secrets/mySecret' secretUri: 'https://myVault.${az.environment().suffixes.keyvaultDns}/secrets/mySecret' secretUriWithVersion: 'https://myVault.${az.environment().suffixes.keyvaultDns}/secrets/mySecret/2f4783701d724537a4e0c2d473c31846' } ] -output secretSetOutput secretSetType[] = secretSet +output secretSetOutput secretSetOutputType[] = secretSet ``` diff --git a/avm/utl/types/avm-common-types/main.bicep b/avm/utl/types/avm-common-types/main.bicep index a67e73a59b..01f8e79c97 100644 --- a/avm/utl/types/avm-common-types/main.bicep +++ b/avm/utl/types/avm-common-types/main.bicep @@ -405,6 +405,7 @@ type secretSetOutputType = { } @export() +@description('A map of the exported secrets') type secretsOutputType = { @description('An exported secret\'s references.') *: secretSetOutputType diff --git a/avm/utl/types/avm-common-types/main.json b/avm/utl/types/avm-common-types/main.json index 63c469793c..34218bb4a6 100644 --- a/avm/utl/types/avm-common-types/main.json +++ b/avm/utl/types/avm-common-types/main.json @@ -6,7 +6,7 @@ "_generator": { "name": "bicep", "version": "0.30.23.60470", - "templateHash": "582259741550098970" + "templateHash": "16862752319174543465" }, "name": "Default interface types for AVM modules", "description": "This module provides you with all common variants for AVM interfaces to be used in AVM modules.\n\nDetails for how to implement these interfaces can be found in the AVM documentation [here](https://azure.github.io/Azure-Verified-Modules/specs/shared/interfaces).\n", @@ -885,65 +885,66 @@ "description": "An AVM-aligned type for a customer-managed key." } }, - "secretSetType": { + "secretToSetType": { "type": "object", "properties": { - "secretResourceId": { - "type": "string", - "metadata": { - "description": "The resourceId of the exported secret." - } - }, - "secretUri": { + "name": { "type": "string", "metadata": { - "description": "The secret URI of the exported secret." + "description": "Required. The name of the secret to set." } }, - "secretUriWithVersion": { - "type": "string", + "value": { + "type": "securestring", "metadata": { - "description": "The secret URI with version of the exported secret." + "description": "Required. The value of the secret to set." } } }, "metadata": { "__bicep_export!": true, - "description": "An AVM-aligned type for the output of the secret set via the secrets export feature." + "description": "An AVM-aligned type for the secret to set via the secrets export feature." } }, - "secretToSetType": { + "secretSetOutputType": { "type": "object", "properties": { - "name": { + "secretResourceId": { "type": "string", "metadata": { - "description": "Required. The name of the secret to set." + "description": "The resourceId of the exported secret." } }, - "value": { - "type": "securestring", + "secretUri": { + "type": "string", "metadata": { - "description": "Required. The value of the secret to set." + "description": "The secret URI of the exported secret." + } + }, + "secretUriWithVersion": { + "type": "string", + "metadata": { + "description": "The secret URI with version of the exported secret." } } }, "metadata": { "__bicep_export!": true, - "description": "An AVM-aligned type for the secret to set via the secrets export feature." + "description": "An AVM-aligned type for the output of the secret set via the secrets export feature." } }, "secretsOutputType": { "type": "object", "properties": {}, "additionalProperties": { - "$ref": "#/definitions/secretSetType", + "$ref": "#/definitions/secretSetOutputType", "metadata": { "description": "An exported secret's references." } }, "metadata": { - "__bicep_export!": true + "__bicep_export!": true, + "description": "A map of the exported secrets" } } }, diff --git a/avm/utl/types/avm-common-types/tests/e2e/import/main.test.bicep b/avm/utl/types/avm-common-types/tests/e2e/import/main.test.bicep index 1a087297a0..dd580dec93 100644 --- a/avm/utl/types/avm-common-types/tests/e2e/import/main.test.bicep +++ b/avm/utl/types/avm-common-types/tests/e2e/import/main.test.bicep @@ -24,7 +24,7 @@ import { privateEndpointMultiServiceType privateEndpointSingleServiceType secretToSetType - secretSetType + secretSetOutputType } from '../../../main.bicep' // Would be: br/public:avm/utl/types/avm-common-types: // ====================== // @@ -268,11 +268,11 @@ param secretToSet secretToSetType[] = [ #disable-next-line outputs-should-not-contain-secrets // Does not contain a secret output secretToSetOutput secretToSetType[] = secretToSet -param secretSet secretSetType[] = [ +param secretSet secretSetOutputType[] = [ { secretResourceId: '/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myRg/providers/Microsoft.KeyVault/vaults/myVault/secrets/mySecret' secretUri: 'https://myVault.${az.environment().suffixes.keyvaultDns}/secrets/mySecret' secretUriWithVersion: 'https://myVault.${az.environment().suffixes.keyvaultDns}/secrets/mySecret/2f4783701d724537a4e0c2d473c31846' } ] -output secretSetOutput secretSetType[] = secretSet +output secretSetOutput secretSetOutputType[] = secretSet