In azure I have got a Function App deployed in a VNET, alongside a subnet containing a private endpoint connected to a Storage Account through private DNS zones (one for each of the storage types), which is configured to only allow access from selected virtual networks and IP addresses. The RBAC role of Storage Blob Data Owner has been assigned to the function app.
I have created a blob trigger using Visual Studio:
[Function(nameof(BlobTriggered))]
public async Task BlobTriggered([BlobTrigger("testContainer/{name}", Connection = "Storage")] Stream stream, string name) {
// Log information
}
In the portal I have set the following environment variables:
Storage = DefaultEndpointsProtocol=https;AccountName=testStorage2342;EndpointSuffix=core.windows.net;Authentication=ManagedIdentity
Storage__blobServiceUri = https://testStorage2342.blob.core.windows.net
My Storage Account has the following containers:
testContainer
azure-webjobs-hosts
azure-webjobs-secrets
Alongside Visual Studio created two containers in the Storage and an environment variable called AzureWebJobsStorage__AccountName.
Whenever I deploy the Function App and add a file to the testContainer, nothing happens. If I click on the function in the portal and select "Integration" and click on the Trigger, it shows no existing storage account connection. Any ideas how to solve this?
EDIT:
I tried with the proposed approach, by letting the storage account reside in the same VNET as the subnet of the function app, and created a service endpoint to the function app subnet from the storage account. However, I get "This requeist is not authorized to perform this operation using this permission" in the overview of my function app.
My environment variables now looks as follows:
AzureWebJobsStorage__accountName = testStorage2342
Storage__accountName = testStorage2342
Storage__blobServiceUri = https://testStorage2342.blob.core.windows.net
Storage__credential = managedidentity
Any idea why it is still not working?






