dotnet / aspire

Tools, templates, and packages to accelerate building observable, production-ready apps
https://learn.microsoft.com/dotnet/aspire
MIT License
3.92k stars 479 forks source link

[Azure Deployment] [Azure KeyVault] KeyVault secret name truncated during provisioning #4538

Open 4eversoft opened 5 months ago

4eversoft commented 5 months ago

I have defined a secret to be created during the provisioning process in Azure KeyVault.:

#pragma warning disable AZPROVISION001
var travelLoungeKeyVault = builder.ExecutionContext.IsPublishMode ?
    builder.AddAzureKeyVault("travellounge-keyvault", (_, scope, keyVault) => 
    {
        var secret = new KeyVaultSecret(scope, name: "OpenIDConnectSettings--ClientSecret");
        secret.AssignProperty(x => x.Properties.Value, openIdConnectClientSecret);
    }) :
    builder.AddConnectionString("travellounge-keyvault");
#pragma warning restore AZPROVISION001

This works so far, but the name of the secret is truncated to OpenIDConnectSettings--C

davidfowl commented 5 months ago

@JoshLove-msft @tg-msft