Introduction
In this article, I will explain how to create a Web App/AppService in Azure and enable virtual network integration.
Actually, there are many articles/references are available to create or provision an App Service in Azure so I am not going to explain how actually create a web app but our actual focus would be on enabling virtual network integration with our AppService. with the help of this integration we can integrate other resources like a database server via this private virtual network.
Steps to enable virtual network integration
- As a first step, we need to create a virtual network, go to the marketplace and search for virtual network service and click on create.
- Enter the resource group and virtual network name, click next,
- Click on add subnet,
- Enter the subnet name and address range, click on Add,
- After adding the subnet in the “IP Address” tab, go ahead with the default values of other tabs and click to review and create.
- Once the deployment is completed go to the resource and click on subnets.
- We can find our database subnet below,
- Now we have created the virtual network, let’s go to the marketplace in Azure and search for an app service. Here I will only focus on integrating the virtual network with AppService rather detailed steps of AppService creation.
- Then click on create and enter the required values and choose your App Service plan under the basic tab.
- Go with the default values and click on create under the “review and create” tab. The deployment will be in progress.
- Now go to the app service resource once the deployment is completed and click on networking.
- Click on to configure the virtual network.
- Click on + Add VNet,
- Choose your virtual network “database-vnet” and then “default” subnet and click on OK to integrate the virtual network with the app service.
- We can see that it has been integrated with the app service to securely access the available resources through the Azure virtual network. Now we can integrate our database server with our AppService to securely access the data from the database and expose it to the public web app.
How to integrate a database server with AppService through private virtual network
Conclusion
So we have successfully created a virtual network and integrated it with an AppService.