It is common these days to package web applications as containers and host them in cloud. On Azure there are many options for hosting containers. One that is often overlooked is Azure App Service Web App for Containers. In this blog post we are going to dive deeper into Web App for Containers, however, before we do, let's explore Azure App Service a little.

Latest posts by Steve Buchanan (see all)

App Service is for hosting web-based applications, REST APIs, web jobs, and mobile backends that are HTTP/S-based in Azure. App Service supports many languages and frameworks including .NET, .NET Core, PHP, Python, Java, and Ruby. App Service leverages cloud capabilities such as load balancing, security (Azure AD, Security Center, ISO, SOC, and PCI compliance, IP restrictions etc.), monitoring, autoscaling, custom domains, and SSL certificates.

One important thing to note about Azure App Service is that when you run your web app in Azure App Service on Linux, it is running a container. Azure App Service on Linux is certainly a good option to host web applications, however, if you have unique custom environment and configuration needs you may run into limitations quickly.

Web App for Containers is a part of the Azure App Service platform and is a great option for developers who need more control over the runtime, framework, tooling, and packages of a web-based application. Web App for Containers will allow you to overcome any limitations related to configuration and environment while still allowing you to leverage the power of and take advantage of the benefits of a PaaS service.

Web App for Containers gives you a way to abstract any underlying container orchestrator such as Kubernetes or Service Fabric. It is a pure PaaS service. Web App for Containers runs a single container and it can run multi-container apps using Docker compose. Note that the multi-container apps functionality is currently in public preview. Web App for Containers supports Linux or Windows Docker containers. It is important to select one or the other up front, as you will need to re-deploy if you want to change this later.

You can deploy images from a private container registry such as Azure Container Registry or a public registry like Docker Hub. Also, Web App for Containers can be used in a CI/CD pipeline with DevOps tools such as Azure DevOps, Maven, Jenkins, and more. Like the standard Azure App Service Web App, Web App for Containers can be scaled vertically (manually) or horizontally (automatically).

Web App for Containers settings in Azure Portal

Web App for Containers settings in Azure Portal

Next let’s go ahead and deploy a Web App for Containers instance to show an example of running a specific container in Web App for Containers. We are going to deploy a Web App for Containers instance with an image from Docker Hub. We will use an image for an open source self-hosted file hosting service like Dropbox/OneDrive known as OwnCloud. We will use the following Azure CLI code in Cloud Shell to do this:

Go to https://shell.azure.com/

# Create a resource group

# Create an Azure App Service plan

# Create a web app using container from Docker Hub

OwnCloud running on Azure App Service Web App for Containers

OwnCloud running on Azure App Service Web App for Containers

In this post we learned about Microsoft’s Azure App Service Platform, Azure App Service on Linux and its limitations, and how we can use Web App for Containers when we need to further customize the environment, configurations, and frameworks to host our web application. We also explored how to deploy a Web App for Containers instance with a specific container on it. To conclude, Web App for Containers is a good option for hosting your containerized web application on Azure.

Read 4sysops without ads by becoming a member!

Your question was not answered? Ask in the forum!

0
Share
0 Comments

Leave a reply

Your email address will not be published. Required fields are marked *

*

© 4sysops 2006 - 2020

CONTACT US

Please ask IT administration questions in the forums. Any other messages are welcome.

Sending

Log in with your credentials

or    

Forgot your details?

Create Account