What is the Azure equivalent of GCP's Cloud Run? - azure

I'm looking for an equivalent to Cloud Run (GCP offering) in Azure
In particular:
It deploys a container
Can scale down to 0
Can serve a webapp
Does Azure have such a service?
I was looking at Azure App Service, but it seems to be missing the ability to scale down to 0.

Azure Container Apps is similar to CGP Cloud Run.
It deploys a container: yes
Can scale down to 0: yes
Can serve a webapp: yes
https://azure.microsoft.com/en-us/services/container-apps/

I think the equivalent of Cloud Run would be Azure Container Instances rather than Azure Container Apps.
I would say Azure Container Apps would be the equivalent of App Engine from Google Cloud which comes with more managed services around the served container like authentication, etc...

Related

How to use custom image for Azure Linux Functions in Azure Portal?

May someone have steps to use custom image for Azure Linux Functions in Azure Portal?
To Deploy your Azure Function code in a custom Linux container requires Premium Plan or a Dedicated (App Service Plan) plan hosting.
You can also use default Azure App Service Container
Below are the steps on how to create custom image
Create a function app and Dockerfile using the Azure Functions Core Tools.
Build a custom image using Docker.
Publish a custom image to a container registry.
Create supporting resources in Azure for the function app
Deploy a function app from Docker Hub.
Add application settings to the function app.
Enable continuous deployment.
Enable SSH connections to the container.
Add a Queue storage output binding.
For further information check Azure Linux Function with Custom Image

Understanding Azure Release Pipeline

I'm very new with Azure DevOps and I need some help to understand how to create a Release Pipeline. The Microsoft Doc is very extensive but I can't find what I'm looking for.
I've created a Build Pipeline with the sample python repository. Then I would like to create a Release Pipeline. I linked my account with my subscription, select the App type, but then I'm asking for App service name.
What is this App service ? How can I create it ?
On their documentation (here) they are just saying
App Service Name: Select the name of the web app from your subscription..
No more explanation.
Could someone please give me more information about that ?
Thanks a lot
An Azure DevOps release pipeline deploys the artifacts that are the output of a build pipeline to some environment that you define (Test, QA, Production, etc.).
For web apps the environment will be a "web hosting" (for other apps it could be something different).
The "web hosting" can be a 3rd party (you would deploy using tasks for FTP, WebDeploy, etc.) or it can be Azure "web hosting" PaaS offering, which is named Azure Web Apps.
Azure Web Apps require an Azure App Service Plan (which defines its characteristics and pricing): https://azure.microsoft.com/en-us/pricing/details/app-service/windows/
Note: an Azure App Service can be used not only to host web apps but also to host the back-end (Web APIs) of mobile apps, containers and serverless functions apps. See App Service overview and for high scale and security see Introduction to the App Service Environments
The template for the Release Pipeline that you have chosen (assuming is the one named "Deploy a Python app to Azure App Service and Azure database for MySQL") is intended to "Deploy a Python Django, Bottle, or Flask application to an Azure Web App and database to Azure Database for MySQL." Since it's deploying to an Azure Web App, the task asks you for its Azure Subscription and its App Service Plan within that subscription.
So, if you plan to deploy to an Azure Web App, create a Service Plan in your Azure subscription (you can use the Azure Portal, Azure CLI, etc.). Otherwise remove the task and use a different task to deploy to your 3rd party web hosting.
If you are new to Azure DevOps and want to try out all the cool things, I suggest you to follow Azure DevOps Labs which has a great content to get started from Zero to Advanced.

What is the difference between Azure Container Instances and Web App for Containers?

I just deployed a web app (node.js container and mongo container) using Azure multi-container instances. It's a bit like Docker Compose but works with an Azure specific yaml file: https://learn.microsoft.com/en-us/azure/container-instances/container-instances-multi-container-yaml
Now I see that there is something called "Azure Web App for Containers". This seems to work with a real docker compose yaml file.
Other than the configuration file format, are there any other differences?
Note: I'm talking about Azure container instances, not Azure container services.
Well, azure container instances bill you only for the time container is active, while webapp bill you for the time webapp exists (so all the time). that is one of the biggest differences between those.
But overall, I'd say Azure Web App for Containers is just a shortcut to run containers on existing "stuff". I've recently learned that Azure Web App for Containers offer kubernetes capabilities, so these 2 services evolve in a slightly different directions. Azure Web App for Containers is targeted at long running stuff (always running) while ACI are aimed at scheduled\burstable\short lived workloads (similar to Azure Functions).
Found this link with MS-staff answer.
In summary
Web App for Containers
Recommended if you are already familiar with the Azure Web App environment.
Best if you have one or a few long-running containers/services that are being deployed.
Can use a custom Docker image to run your web app on an application stack that is not already defined in Azure
Azure Container Instances
"Azure Container Instances is a great solution for any scenario that can operate in isolated containers, including simple applications, task automation, and build jobs"
A fast, light-weight and easy way of running containers
Billed for the time your container is active (billing is based on seconds, cores and memory)
Can start containers in Azure in seconds, without the need to provision and manage VMs.
Can also work with Kubernetes through an experimental ACI to Kubernetes connector
Currently, the fastest way to deploy containers on Azure
Based on the Azure docs, " Azure Container Instances guarantees your application is as isolated in a container as it would be in a VM."
Another difference, in addition to the other answer, is that Web App for Containers offers "slots" with which you can run multiple images on the same allocated resources to help increase utilization. As container instances bill per time used, they do not have "slots".
There is a good article about this on Microsoft Learn called: Comparing Container Apps with other Azure container options
Azure Container Instances
Azure Container Instances (ACI) provides a single pod of Hyper-V isolated containers on demand. It can be thought of as a lower-level "building block" option compared to Container Apps. Concepts like scale, load balancing, and certificates are not provided with ACI containers. For example, to scale to five container instances, you create five distinct container instances. Azure Container Apps provide many application-specific concepts on top of containers, including certificates, revisions, scale, and environments. Users often interact with Azure Container Instances through other services. For example, Azure Kubernetes Service can layer orchestration and scale on top of ACI through virtual nodes. If you need a less "opinionated" building block that doesn't align with the scenarios Azure Container Apps is optimizing for, Azure Container Instances is an ideal option.
Azure App Service
Azure App Service provides fully managed hosting for web applications including websites and web APIs. These web applications may be deployed using code or containers. Azure App Service is optimized for web applications. Azure App Service is integrated with other Azure services including Azure Container Apps or Azure Functions. When building web apps, Azure App Service is an ideal option.
Azure Web App for Containers and Azure Web App is the same service and they use an App Service Plan. The only difference is that Publish is set to Docker Container instead of Code by default.
https://azure.microsoft.com/en-us/products/app-service/web/
https://azure.microsoft.com/en-us/products/app-service/containers/#overview
From the article to see other alternatives as well:
There are many options for teams to build and deploy cloud native and containerized applications on Azure.
Azure Container Apps
Azure App Service
Azure Container Instances
Azure Kubernetes Service
Azure Functions
Azure Spring Apps
Azure Red Hat OpenShift
Azure Container Apps
Azure Container Apps enables you to build serverless microservices based on containers. Distinctive features of Container Apps include:
Optimized for running general purpose containers, especially for
applications that span many microservices deployed in containers.
Powered by Kubernetes and open-source technologies like Dapr, KEDA,
and envoy.
Supports Kubernetes-style apps and microservices with features like
service discovery and traffic splitting.
Enables event-driven application architectures by supporting scale
based on traffic and pulling from event sources like queues,
including scale to zero.
Support of long running processes and can run background tasks.
Azure Container Apps doesn't provide direct access to the underlying Kubernetes APIs. If you require access to the Kubernetes APIs and control plane, you should use Azure Kubernetes Service. However, if you would like to build Kubernetes-style applications and don't require direct access to all the native Kubernetes APIs and cluster management, Container Apps provides a fully managed experience based on best-practices. For these reasons, many teams may prefer to start building container microservices with Azure Container Apps.
You can get started building your first container app using the quickstarts.
Azure Kubernetes Service
Azure Kubernetes Service (AKS) provides a fully managed Kubernetes option in Azure. It supports direct access to the Kubernetes API and runs any Kubernetes workload. The full cluster resides in your subscription, with the cluster configurations and operations within your control and responsibility. Teams looking for a fully managed version of Kubernetes in Azure, Azure Kubernetes Service is an ideal option.
Azure Functions
Azure Functions is a serverless Functions-as-a-Service (FaaS) solution. It's optimized for running event-driven applications using the functions programming model. It shares many characteristics with Azure Container Apps around scale and integration with events, but optimized for ephemeral functions deployed as either code or containers. The Azure Functions programming model provides productivity benefits for teams looking to trigger the execution of your functions on events and bind to other data sources. When building FaaS-style functions, Azure Functions is the ideal option. The Azure Functions programming model is available as a base container image, making it portable to other container based compute platforms allowing teams to reuse code as environment requirements change.
Azure Spring Apps
Azure Spring Apps is a platform as a service (PaaS) for Spring developers. If you want to run Spring Boot, Spring Cloud or any other Spring applications on Azure, Azure Spring Apps is an ideal option. The service manages the infrastructure of Spring applications so developers can focus on their code. Azure Spring Apps provides lifecycle management using comprehensive monitoring and diagnostics, configuration management, service discovery, CI/CD integration, blue-green deployments, and more.
Azure Red Hat OpenShift
Azure Red Hat OpenShift is jointly engineered, operated, and supported by Red Hat and Microsoft to provide an integrated product and support experience for running Kubernetes-powered OpenShift. With Azure Red Hat OpenShift, teams can choose their own registry, networking, storage, and CI/CD solutions, or use the built-in solutions for automated source code management, container and application builds, deployments, scaling, health management, and more from OpenShift. If your team or organization is using OpenShift, Azure Red Hat OpenShift is an ideal option.

How to scale docker based services in azure

What is the best way to scale docker based application services in azure. In AWS I know we can use container service. Currently I am using Cloud Service on azure, which enables easy scaling. There is also Service Fabric which looks better than cloud service. But when I use docker how can I scale them to multiple VMs?
Take a look at Azure VM Scale Sets, this allows easy integration with Azure autoscale. See https://azure.microsoft.com/en-us/blog/azure-vm-scale-sets-public-preview/
A couple of additional things worth tracking..
1) The upcoming preview of Azure Container Service, see announcement: https://azure.microsoft.com/en-us/blog/azure-container-service-now-and-the-future/
2) The Mesos Cluster with Marathon and Swarm solution in Azure Quickstart Templates: https://github.com/Azure/azure-quickstart-templates/tree/master/mesos-swarm-marathon
Microsoft have just announced the Azure Container Service which provides Mesos or Swarm orchestration
Launch blog https://azure.microsoft.com/en-us/blog/azure-container-service-preview/
Service home page https://azure.microsoft.com/en-us/documentation/articles/acs-intro/
For scaling plain Docker containers in Azure you can use ACS (Azure Container Service) with Docker Swarm or Mesos DC/OS underneath.
Another option is to use Azure Service Fabric which its version for Linux uses Docker, too. In regards SF for Windows, it will have Docker pretty soon using Windows Docker containers.
Service Fabric goes further (it is not just orchestration of containers for scaling) as it provides application platform and prescriptive frameworks like Stateful services, Reliable Collections and Actor Framework.

Convert Azure VM to Cloud Service

We are putting up a asp.net webapi project on azure. It also does a few other things so it couldnt go up as an azure website. Our IT guy set it up on a Azure Virtual machine.
I've read we'd be more beneficial to run it as a cloud service (cost wise and also maintenance wise).
I'm just wondering if anyone knows if there is a way to convert an azure virtual machine to an azure cloud service?
Thanks
You can't really convert an Azure VM into an Azure Cloud Service. What you could do is deploy your application as a cloud service. Once everything's working well, you can then deploy that application into a cloud service.

Resources