0
votes

I accidentally deleted the storage account my Azure app function was attached to. Now the function is inaccessible. It won't even let me update the settings to try to point it to a newly created storage account. In fact I can't even download the app code to re-upload it as a new app function. EDIT: I have now been able to update the storage account connection string, but still the function shows as inaccessible. Additionally if I try to download the source code, I keep getting the error here:

enter image description here

Any advice, or am i stuffed?

2
Could you show the screenshot of your application settings? Or try to restart your function app?Joy Wang-MSFT
Last time I had this problem, I had to recreate the function app... I think Function Apps is storing some secrets in blob or something like that that break the functionThomas
Do you have consumption or app service plan for your function app?Alexey Rodionov

2 Answers

0
votes

If you have deleted the Storage Account attached to your Function App, you can create a new storage account and edit the value of either AzureWebJobsStorage or WEBSITE_CONTENTAZUREFILECONNECTIONSTRING (depending on your plan I believe) in the application settings with the new connection string, which you can find in the Access keys page of your newly created storage.

Edit: The only caveat is you have to still have the code locally. Your deployed code will be lost, and you will have to deploy it again. Maybe that's what was missing (I didn't see the OP's edit before answering -- apologies).

Source: https://docs.microsoft.com/en-us/azure/azure-functions/functions-recover-storage-account#storage-account-was-deleted

-1
votes

Unfortunately you cannot retrieve your Function App once the storage account that contains it is deleted. Your best bet would be to recreate the Function.