Reputation: 1316
While working on azure functions, I added one more azure function in my existing azure function app.
The function is the only time triggered function in my function app (V1).
Yet before the timer function, I didn't add any reference to storage account in any earlier deployments.
While I try to run the timer based function online, I get the error as below:
The listener for function 'function1' was unable to start. mscorlib: One or more errors occurred. Microsoft.WindowsAzure.Storage: The remote server returned an error: (403) Forbidden.
I googled up and got solutions mentioning to add 'AzureWebJobsStorage' key in application settings and connection string. But got no luck.
Can anyone tell What Can be done?
Upvotes: 3
Views: 668
Reputation: 14093
If you are using storage emulator locally, add UseDevelopmentStorage=true
as the value to AzureWebJobsStorage
, the local.settings.json will be like this:
{
"IsEncrypted": false,
"Values": {
"AzureWebJobsStorage": "UseDevelopmentStorage=true",
"AzureWebJobsDashboard": "UseDevelopmentStorage=true"
}
}
If you want to use the Storage on portal, go to portal to get the Storage Connecting String:
And then add the Connecting String to AzureWebJobsStorage
.
If you test the timetrigger on local and still can't not work with the above solution, please try to copy the same code to a different location. That maybe work.
Do you run on local? Or run on portal? Providing more information helps to resolve this issue.
Another possibility, please check your firewall and network settings.Suggestion from @Varun05. Hope it help.
Upvotes: 1
Reputation: 387
Recheck the firewall and network settings at storage account level. It seems like your firewall settings are restricting the func app to access the storage account
Upvotes: 2