Microsoft Azure AZ-801 — Section 16: Migrate workloads from previous versions to Server 2022, IIS workloads, & AD DS Part 2

Microsoft Azure AZ-801 — Section 16: Migrate workloads from previous versions to Server 2022, IIS workloads, & AD DS Part 2

95. Overview of App Service Plans

Now, if you are somebody that is looking to host Web related services into Azure, such as a web application, then you come to the right place with Azure, because not only do we have just regular Azure container instances for handling web based containers to the industrial strength Kubernetes, there is another solution called Azure App Service plans.

So, what are Azure App Service plans? Well, this is a another solution that allows us to specify some computing resources that are located in the Azure Cloud data centers that essentially is going to act kind of like a server farm, how you would have a bunch of servers working together to provide some kind of a web server or web service or web application for web hosting purposes. You are essentially going to very easily set up this app service plan, specify what size of services that you’re getting the virtual. There’s basically going to be a bunch of virtual machines that are going to be working together. You’ll specify the operating system. There’s two options. There are Windows and Linux, of course, those are the types of operating systems that they’ve got for handling containers. And of course, containers can sit inside this app service plan.

So, it’s another way of basically producing containers. We would specify the region, the number of VM instances we want. All right. And then, of course, it can you can have this grow so it can support load balancing and having more VMs that get generated. You can have a number of VM instances and allow the small, medium or large size instances depending upon the size you’re looking for and the performance you’re looking for. And of course the pricing is going to be based on that.

Now, what’s really neat about this is Microsoft does allow you to set up this for free. You can have a free pricing tier where you can essentially go in and play around with your app service plan and set things up. And then you can, of course expand later. But there’s free there shared basic standard premium. There’s premium version two, version three, isolated isolates converted to isolated version two. There’s various different options there for setting this up. The thing about the to understand about app service plans is it’s a little more user friendly for somebody that doesn’t want to dig deep into like Kubernetes and understanding all the command line stuff or managing nodes or with Kubernetes and all that, you have a lot more control, especially if you learn all of the different commands for dealing with it. Whereas with that service plan, it’s mostly graphical oriented and pretty user-friendly, pretty easy to use, easy to size things and manage, but it can be more expensive to go the route of an app service plan for a company.

So, you’re kind of getting a tradeoff here. App service plan is going to be could be a little bit more expensive for you, but ease of use is really one of the big things that you’re getting out of it. All right.

So, what are the pricing tiers here? Well, with that service plan, the features that you’re looking for is going to sort of be the deciding factor on which pricing tier you’re going to go with. There’s there is what’s called shared compute. And this is this is free and share. They give you basically two tiers that will that’ll run this, basically allow you to play around with setting up a web service. And there’s a lot of limitations on it, as you’ll see when you get into this. But it does let you set up an app and test it out from a developer standpoint. All right. You get you get quite a quite a bit of limitations as far as CPU usage and all that put on you as well. Then you got dedicated, dedicated computing. You have basic standard premium to premium three. And of course, obviously as you move up the ladder, things are getting a little going to get more expensive, but it’s going to allow you to have a lot more VMs and a lot more capabilities than what you got with the shared compute, the free and the free model essentially. And then you have isolated so you have isolated, isolated, isolated version to essentially these are dedicated VMs that are going to run on a dedicated Azure network. This is going to provide some additional isolation for your applications, and it also provides the maximum level of scale out capabilities that you can possibly get with this. All right.

So, how does my app run and scale? Well, first off, if you’ve got the free or shared tier, your app doesn’t scale. So, you can’t use scaling that. You’d have to change to a different tier. But basically, when you set up your app service, the app itself is going to run on all instances of your VMs. So, however many VMs you’ve got dedicated to this, you’re going to have you’re going to have instances of that app running on all the VMs. You have multiple apps. On the app service plan. It’s running across them. All right.

So, your app service plan essentially is your scaling unit. All right. If the plan is configured to, say, run five virtual machine instances, then all apps in the plan run on all five instances. That’s sort of the way you want to look at it. And you can also, of course, have auto scaling set up so that it has auto scaling rules to scale out when need be. How much does it cost? That’s one of the big things everybody kind of wonders because again, this can get a little bit pricier. You get the ease of use and app service plan is a lot easier to use than setting up Azure container instances or setting up Kubernetes by far. And so what’s the pricing? So the pricing is essentially based on the different tiers you go with shared will free is free, right? You have shared the app receives basically a quote of CPU minutes that it’s allowed to use. All right. And then you have basic standard premium. It’s going to kind of go up from there and you’re going to be charged based on which of those you go with. You get different CPU ram usage and all. When you set this up, you’re going to see all this.

So, don’t worry when you see it, when you actually get in there and play around with it, they tell you the ins and outs of what you get out of each one. So, that’ll help when you actually go through and create this. So, the VM instances are going to be basically are charged the same regardless of how many apps you’re using.

So, it doesn’t matter how many apps you’ve placed on an app service plan, you’re going to be charged the same regardless. All right. It’s based on how many VM instances and all that you have now isolated, isolated verdict version to the app server service environment is going to define the number of isolated workers that run your apps.

So, this will get into the amount of VMs and stuff that’s supported on the hardware that you’ve chosen. All right.

And lastly, one of the things about app service plans. It makes it very easy to deal with. It is the fact that you can resize very easily. What I mean by I’m not talking about scaling out, I’m talking about I can go and change plans very quickly. So, again, I might have selected the free plan just to set things up, but then now I’m ready to go up to a higher level plan. I can do that very quickly, very easily, and I can scale back very easily as well.

So, you could start out with free and then go up if you want, add new features later down the road., maybe, you want to add TLS binding and some of the more some of the security features, more memory, more virtual CPU, core support, storage, whatever it may be, you can very quickly do that. And if you want to go backwards, you can. This is another thing that makes this a sought after solution as opposed to using some of the others like Kubernetes and all that, because it’s a lot harder to do that sort of thing with Azure container instances as well as Kubernetes.

So, resizing is easy. You’ll see that when you jump right in and start using it. How easy it is to do this.

96. Migrate IIS workloads to Azure Web Apps

I’d like to show you now how we can create an app service that we could move is files into webs, website files, maybe, that we’ve built for on our on-premises environment. We could actually pull into this web app service and we could just host that web service online.

So, here we are on We’re going to click the menu button here. We’re going to go to all services and we’re just going to do a search for the word app service, the words app service here.

So, we’ll just put that into the little search. All right. And let’s look for here it is right here. Well, there it was, I should say. There it is, App Services. We’re going to click on that. And you can see I don’t have any app services at the moment, so I’m going to go ahead and click to create an app service. All right. It’s going to bring up the wizard.

Now, it’s asking me about a resource group. I’m just going to call this resource group App Service. RG for App Service Resource Group. Click OC and then I would give it a name, right? So if this was the exam lab practice app service, I might call it something like that exam lab practice app. There we go. And then am I doing code? Is it Docker? Is it a static website? What are we getting at here? Right. Most of the time What? What lots of people do and this is the most common thing to do is they’ll host it through like a Docker container. And so your app can just be packaged up through Docker. Docker is a free download and then you can use Docker. And then from there you would choose Windows. In this case, if your application was built on is you would generally want it to sit on windows. It’s not that you couldn’t put it on a Linux environment if you if you just wanted to move the files over. But if you built it specifically to run with ISE and you expect all framework is stuff to be there, then you would want to go with Windows, right? And then we would choose our use. In my case, you can choose the, the Windows plans that are available. You can use the calculator to look at the pricing and all that and you can see what. Because it is going to create what’s called an app service plan. And then here’s the it’s using a premium V three. You can click change size and you can see the different size options that are available. All right. And this is before production, but you can do this for just for testing purposes and all that they have isolated, which is the higher end stuff. And then when you look at that, of course, these are all the things you’re going to get out of it. Custom domain auto scaling, staging slots, daily backups, something called Track Traffic Manager, which can redirect traffic to different places in different regions. If you’ve if you’ve replicated your web service to different regions, Hyper-V isolation, so it’s protected Azure computing units that gets into the processing power of it. You get a certain amount of memory and you can see that up here, the two virtual CPUs, eight gigs of memory, because this is going to be setting on a virtual machine. This is going to take, in this case, my case, $229 a month.

So, I am going to apply this, but I am going to delete this. I’m not going to leave this in my environment very long here because I don’t really want to use my Azure credit on that. And then if you wanted zone redundancy, so you want like replicas of it in, in different data centers, you could choose enabled for that. From there, I would just click Next go to Docker.

So, then Docker is from there you have what are called Docker images. These are just existing empty images or sometimes they just have like a generic web page, but you can obviously put your own website in there or you again, if another option was to download Docker in your own environment, you can import your own website into a Docker container and you can just upload that container through one of these container services here. This is just a quick start, Windows Azure image and then we will from there we can adjust if we want to support V Nets or not support network injection, connect it to a certain virtual network and you would really want to do that if, if your virtual machines on your network need to get to this website, else it will just be connected to the internet like a traditional website. All right. And then if you want to have monitoring and all that turned on, there’s a monitoring option here, but I’m going to just keep that turned off and then I’m going to click Review and create and we’re going to click create and that’s going to start creating that web app.

So, I’ll go ahead and just pause this recording while that’s happening. All right. Once that’s done deploying, let’s go to the resource group right here and you’ll see the resource group has two different resources. The first is the actual app service plan that’s driving the virtual machines for the app service. And then the second, of course, is the app service, which is actually going to host the Web server web service, I should say, which is the which is where you put your web content. Let’s click on the app service plan first. And so this is the app service plan. You can get a look at the CPU percentage, the memory usage, the data input output of it, and then you can even if you want to scale up or scale out, you can.

So, if you go here to scale up, you can go to a more powerful set of virtual machines that are running this thing where you can see the cost in this case. So, I could go up to 16 gigs, eight virtual CPUs. And that’s called scaling up, or also known as vertical scaling. Then you have scale out, which gets into if you want to have more instances.

So, in a case where you’re getting just a lot of load, your website’s getting hit with a lot of load. Then you can have this thing scale out to where it’ll have more virtual machines that are running and you can generate more instances and you can set up what’s called an auto scale policy for that.

In other words, if the performance reaches a virtual CPU reaches, let’s say 90%, go ahead and generate another node, another virtual machine for handling the load. Of course, it does get more expensive when you do that. Let’s take a look at the actual app service that’s running on the app service plan.

Let’s go back over to our resource group. Here is the app Service and this is what we really care about in this case, because this is what you’d be migrating your eyes services to your web service, your website files, web app files, all that.

So, first off, if you go here, you can see the URL that is given it. You can generate a custom domain name. All you got to do is go down here to custom domains and you can actually have a custom domain name.

So, if I wanted to host the exam lab domain name on this, I could, I could put that in and validate. You do have to register the domain name. And if you’re not familiar with registering a domain name already, you do that through Azure AD, you go to menu, you go to Azure Active Directory and. And then you scroll down and you’ll see custom domain names. You register custom domain name through here, and that’s how you go about doing that. You do have to own the name and all that. But let me go back to my resource groups and we’ll go back to App Service and we’ll open up our app service plan again. All right. But if you go to the temporary domain name that they give you for the site, you’ll see that it brings up a little basically a little AI website that’s telling you is ready to go, but you have to deploy to it using the deployment center. If you come back over here, you’ll see the deployment center is right here. You can click on that. And this is where how you would get your files uploaded.

So, you can use what’s called a container registry if you want, which is a microsoft container registry. Or you can do it the way a lot of people do it, which is to use FTP. So, you download an FTP client and then you connect in through FTP, and then you just upload your website files. So, you back up your files that are on-premises, you upload them there into the service and there you go. You’ve now migrated your, your website.

So, all in all, you’ll see that working with this is not all that difficult. You can also add your TLS certificate stuff. You can add you can generate certificates, purchase certificates if you want right here and add those to support encryption and all that on your side. All right.

So, that is how we could migrate a is workload a is web app or application or just general website into Azure utilizing an app service.