I've deployed a .NET Aspire app to Azure using the azd up cmdlet. During the deployment step, a connection string was requested to an Azure SQL database. The app and its connection to the database works as expected.
I now need to change the connection string to point to a different database. I found the connection string secrets in my Azure Container App in the Azure portal and updated them there. But when deploying updates using azd deploy the connection string is reverted to its original value.
I can see in the config.json file of my environment that the connection strings are read from a vault, identified by a GUID. But we have no Azure Key Vault instances in our tenant with that ID, so I'm not sure where this vault is being referenced.
How can I update my connection string to a new value that will ensure subsequent deployments will use it and not override it with the value initially provided?
azd pipeline configwhich will take the values in theconfig.jsonand add the JSON to theAZD_INITIAL_ENVIRONMENT_CONFIGenv var in the pipeline. It's also possible to remove, manually, thevaultUri, which isn't to do with Key Vault but points to user-secrets, I believe, and put your connection string in there in plain text. Then add that JSON to theAZD_INITIAL_ENVIRONMENT_CONFIGin your Pipeline's Library variable group. Not ideal but could get you further forward.