How many different ways are there to deploy a website under azure portal? - azure

Good day dear community,
i have a smaller project where i need to search for different possibilities to deploy a website under azure portal.
Personally i found 4 different ways how to do it.
App services
App functions Serverless (which i dont understand how to deploy there a website)
Install a VM and then deploy a website
Use docker to deploy your code
Question:
Are there any more ways to deploy a website under azure and can somebody explain the deployment of websites with serverless as i dont understand how to publish a website there. i just managed to get the httptriggers and i am confused with that.
Thanks in advance
sorry for any spelling mistakes.

You can deploy to a website to a VM. But first you will have to setup the VM to be a web server. There are many different pre-configured images with either Linux or Windows OS. This will require you manage the OS of the VM.
An Azure App Service will abstract the OS and VM away from you. The OS will be managed for you and you can configure many settings through the Azure Portal. There are different plans that allow you to use more compute and/or memory. You can also setup Authentication through the portal. You can also elect to deploy you website inside a container to an App Service.
There are also Azure Function Apps which can be used. Azure Function Apps are not intended to serve as the backend to a website, but it can be. These are meant to serve only one purpose, not many like the backend of a whole website ( for example, you might use a different function app to serve content each page of a website instead of just one app service having multiple endpoints serving all pages of a website). With Azure function apps, you can deploy in a container or not in a container.
I am not sure what you mean by number 4, Container over docker. You can deploy a docker container an App Service or a Function App. You can deploy the container to docker hub or azure container registry (to name a couple), but that will not deploy your website so that it is accessible.

Related

Difference between Azure App Services and Web App for Containers

I was looking to use Azure App Services and noticed Azure now offers Web App for Containers, now I wonder what's the difference between them? And couple more questions come to my mind
Assuming I choose Web App for Containers, who is going to manage the container updates?
Is the deployment differs from App Services to Web App for Containers, from application perspective?
Web App for Containers is one of the offerings in Azure App Service. It allows you to deploy containerized applications on Linux and Windows (the latter is in preview).
The platform automatically takes care of OS patching, capacity provisioning, and load balancing. But, the container updates are up to you.
The deployment differs in that you will be deploying your application inside a Docker container instead of deploying directly like you do in a Web App.

Azure : Deploy Angular(Front-End) & Node (Back-End) app without VM

I am new to Azure. I have never used azure. So don't mind if this is some silly question.
I have a client who also doesn't know much about deploying.
I have angular/node apps. He wants to host on Azure WITHOUT using a VM.
I am not sure about azure. So i don't know how to deploy without VM.
I know to deploy with RDP(Remote Desktop).
Can anyone help me with this. Is there a way to deploy angular & node app without VM?
Is there any specific documentation for it? Which services will i need in Azure?
Thanks in advance!
Except Azure VM, there are normally two ways to deploy Node.js app on Azure which include App Service - Web Apps and Web Apps for Containers, please see the links below to know these guides.
For deploying Node.js app on Azure Web Apps.
Create a Node.js web app in Azure
Tutorial: Build a Node.js and MongoDB web app in Azure
To deploy the app with a ZIP file, or via FTP, cloud sync, or deploy continuously, or from local Git, etc. You can see more at the left sidebar of these pages.
For deploying Node.js app on Azure Web App for Containers, it's a simple way to deploy the app on Azure as similiar as on local docker.
Create a Node.js web app in Azure App Service on Linux
Build a Node.js and MongoDB web app in Azure App Service on Linux
To deploy via FTP, cloud sync, or deploy continuously, or from local git, etc. Also, you can see more at the left sidebar of these pages.
Some important tools will help deploying easier.
Deploy via VSCode, you can refer to these offical documents for WebApp(App Services) or Container(Docker Images).
To deploy on WebApp not Container, Kudu is a common tool for debuging and deployment. Meanwhile, for Node.js app, we need to use iisnode to connect IIS as revese proxy for your app, and configure the web.config file via follow the kudu wiki document. The Kudu wiki is very useful and valuable for new to Azure.
There are more details for this topic which can not be listed one by one at here, but the above these are necessary. The offical guide for Javascript developers is helpful for new to Azure.
Jay Gong posted a great answer for hosting on Azure. However, you might want to ask your client if s/he means s/he wants a micro services architecture. For more information on micro services, check out this link.
The other viable option would be an App Service (which is an Azure service that manages deployment and abstracts a lot away, but there's a VM under the hood)? Without a VM for hosting, it would be rather difficult to do anything in the cloud on Azure - the only other option is local hosting, which would be without Azure. I would argue that it ruins the purpose of using cloud services, as it seems your client is confused.

deploying frontend and backend to the same web service on azure

i have a web app that has a seperate nodejs backend and angular frontend.
is it possible to make them both run on the same azure web service? or do i need a stand alone service for each?
my nodejs server is just a light API that feeds my angular app with some statistical data to render it. if it is possible what would be the way to do it?
since i am using typescript i know i need to push my nodejs using zipdeployment and i know i need to use visual studio to push my angular project to azure. but when i want to run both on the same service, how do i do it?
is it possible to make them both run on the same azure web service? or do i need a stand alone service for each?
If you choose the Web App on Windows OS, IIS allows you to configure multiple virtual applications within a single website. For this approach, you could follow Deploying multiple virtual directories to a single Azure Website. Note: The multiple virtual applications would share the same application pool.
As kim mentioned, you pay for the App Service Plan, not for the Web App. You could also host nodejs backend and angular frontend in different web apps under the same app service plan.
For the deployment, you could leverage VS publish wizard or manually upload your files via KUDU or FTP. Moreover, you could also follow Deploy the app section about various approaches for deployment.
You can run multiple web sites in different web apps in Azure so that they are sharing the same Azure App Service.
You can think of the App Service as a virtual machine offering resources for your applications. How many web apps you can run simultaneously depends on the size of your plan, see this page for details.
This way you can deploy them separately, manually or automatically using e.g. VSTS.

Difference between Azure Container Service and Web App for Containers

What is the difference between Azure Container Service and Web App for Containers?
They both seem to offer a fully managed platform on which we can deploy containers. I feel that Web App for Containers must be offering something more, but I don't see it. I've read the Azure Container Service FAQ and the Web App for Containers intro page, but the difference is not obvious to me.
Web App for Containers lets you run your custom Docker container which hosts your Web Application. By default the Web App Service with Linux OS provides built-in Docker images like PHP 7.0 and Node.js 4.5. But by following the instructions from this webpage you can also host your custom docker images which allows you to define your own SW-Stack. The limitation is that you can only deploy one docker image to an App Service. You can scale the App Service to use multiple instances, but each instance will have the same docker image deployed. So this allows you to use Docker as a Service, but isn't intended for deploying Microservices.
Container Services (ACS), Kubernetes Service (AKS) and Service Fabric allow you to deploy and manage multiple (different) Docker containers which might also need to communicate with each other. Let's say you implement a shopping website and want to build your web application based on a Microservices architecture. You end up having one Service (= container) which is used for registration & login of users and another Service which is used for the visitors' shopping carts and purchasing items. Additionally you have many further small services for all the other needed tasks. Because the purchasing service is used more frequently than the sign-up/sign-in service, you will need, for example, 6 instances of the sign-up/sign-in service and 12 instances of the cart service. Basically, ACS, AKS and Service Fabric let you deploy and manage all those different Microservices.
If you want to know the difference between ACS/AKS and Service Fabric you might want to have a look here.

migrating from EC2 to Azure

First of all, I have never used Amazon EC2 neither Windows Azure. But I have a task to move application from EC2 to Azure. App is a REST api written in node.js. Currently I know that there is one EC2 instance with ubuntu with runing app on it. App is deployed to server/instance using tool called Capper. App uses some database and redis. This api is used by mobile clients.
My question is what is the simplest way to move app from EC2 to Azure and what type of service to use on Azure for hosting such app?
You will need to either deploy a Linux-based VM in Azure's "Virtual Machines". Check this article out for assistance: http://www.windowsazure.com/en-us/develop/nodejs/tutorials/getting-started/
Alternatively, you can deploy a node.js app on Windows Azure Websites, by adding a new "Web site" thru the management portal, and pick the node.js template from the gallery of predefined templates.
HTH

Resources