Unlike other services, Azure Web Apps service enables us to build and host web applications in the programming language of our choice without managing infrastructure. It offers auto-scaling and high availability, and supports both, Windows and Linux.
It also allows us to setup automated deployments where we can link our GitHub, VSTS (Visual Studio Team Services), Bitbucket, and external Repo to it. So, when we make any changes in our application and push them to the repository, those changes will deploy to our hosted app automatically.
Let’s start and create Azure Web App step by step.
Primarily, login to Azure Portal and then select App Services from the side menu.
Now, add "New" app service.
There, we can see many App services, out of which we will select "Web App" to deploy a website.
Now, we will fill in the required information like App name, Resource group, Operating system, and select service plan.
Create a new service plan, give App Service Plan Name, then select location of the Server.
Select Pricing tier. We are selecting F1 plan for demo purpose - which is free of cost.
There are many other plans. We can select a plan according to our requirement.
Turn on or off Application Insights according to the requirement and then click on "Create".
Moreover, Application Insights is used to monitor our live web application. It will automatically detect performance anomalies. It includes powerful analytics tools to help you diagnose issues and to understand what users actually do with our app. It's designed to help us continuously improve performance and usability.
Here we go. We have successfully deployed our first web app. After hitting hosted URL in the browser, we will see default browser template.
Now, we will publish our application using Visual Studio 2017.
Firstly, download "Publish profile" from Azure portal by clicking “Get publish profile”.
Let’s quickly create an ASP.NET website.
Adding some message to Default.aspx page.
Go to Solution Explorer – Right click on website >> Publish Web App.
Select Import >> Browse downloaded publish profile.
Click on "Validate Connection"; if successful >> Next >> Publish
We can see deployment process in output window.
Wow, the web app is published successfully.
After successful deployment, we can check our web app. Well, its working!!
Finally, we created a web app and deployed our website on it. Here, we can see how Azure makes it too simple to create and maintain a web app.
You can refer to the below links to know more.
- https://docs.microsoft.com/en-us/azure/app-service-web/app-service-web-overview
- https://docs.microsoft.com/en-us/azure/app-service-web/web-sites-deploy