The doc suggested contributor role, but I even tried Owner role, but still seems getting the following error. The App Service does already have the A system assigned managed identity (MSI).
Unhandled Exception: System.AggregateException: One or more errors occurred. (The specified user '' does not have the permissions required to access the configuration store.) ---> System.UnauthorizedAccessException: The specified user '' does not have the permissions required to access the configuration store.
at Microsoft.Azure.AppConfiguration.ManagedIdentityConnector.ManagedIdentityConnector.GetConnectionString(Uri endpoint, Permissions permissions, CancellationToken cancellationToken)
at Microsoft.Azure.AppConfiguration.ManagedIdentityConnector.AzconfigClientFactory.CreateClient(Uri endpoint, Permissions permissions, CancellationToken cancellationToken)
--- End of inner exception stack trace ---
at System.Threading.Tasks.Task1.GetResultCore(Boolean waitCompletionNotification)
at System.Threading.Tasks.Task1.get_Result()
at Microsoft.Extensions.Configuration.AzureAppConfiguration.AzureAppConfigurationOptions.ConnectWithManagedIdentity(String endpoint)
Seems like it has to be exactly Contributor Role. Closing the issue.
Most helpful comment
Seems like it has to be exactly Contributor Role. Closing the issue.