Integrate a Web App with a CosmosDB database using a Virtual Network Service Endpoint in Azure
Consider the following real-life application scenario. Your Web App (Azure App Service) accesses a CosmosDB instance to read data. Your users access the web application from its UI, and you want to ensure they cannot directly access the CosmosDB instance using its public URL.
In this article, you will learn:
- How to use a System Managed Identity and RBAC roles to access your CosmosDB instance from your Web App
- How to integrate your Web App and your CosmosDB with an Azure Virtual Network
- How to create a Service Endpoint to allow only the Virtual Network to access CosmosDB
- All the necessary
az
CLI commands to complete the tutorial, without using the Azure Portal UI :)