This might be a silly question.
I have an azure web app and an azure function app running. Both are written in .net
I want to debug the application in the local visual studio with the configuration values from the Azure portal.
How can I download the azure configuration for the web app service and function to use in local VS? Manually copying takes a lot of time and is error-prone.
Directly copying using advanced editing is not giving configuration in a correct format.
After a workaround on this, I found a way by exporting app service configuration to app configuration store and then exporting from there to local file.
There is an import/export option in the App configuration store for each app configuration you created.
Goto
Import/export, choose yoursource and targetlocations and click on apply as shown:Imported keys and values from Azure App service to app configuration first and then import from app configuration store to local file in
jsonformat.Retrieved key-values to local folder:
You can also use
Az CLIcommand to export configuration from Azure app service.Alternatively, You can read configuration from the App configuration store by using builder configuration code as detailed in MSDoc.