AZ-140 ep14 | In An Image Gallery Far Far Away!

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
welcome to the azure academy my younglings on the path to becoming an azure imaging master you must learn many skills let's begin i'm dean sefola and this is the azure academy your padawan training begins here what is an image well to put it simply an image is an operating system combined with patches and updates and any customizations you wish to add and the customizations is where things get interesting more about that in a minute and since you are just beginning as a padawan we will start with the simplest kind of image here we are in the azure portal building a new virtual machine and you can see right over here that you have to select an operating system that is an image and windows 10 enterprise is what we'll use for our developers in japan in their personal host pools this is deploying an image out of the azure marketplace microsoft creates and updates all of these images here so that you do not have to now these images don't have any customizations but we can do that in a few additional ways so over here on the advanced screen you can click to add an extension this is a whole new list of possibilities and there's anything here from third party integrations like chef and puppet to powershell desired state configuration or even adding something like the custom script extension which means the sky's the limit and you can do anything you want and you could use this for anything from loading a powershell script for your fslogix configuration security baselines deploying applications and more when you've selected the extension you click over here to pull that extension which is a powershell file in my case from a azure storage account then the arguments are the input parameters that that powershell script needs to function for my example here with fslogix that would be where is the share located where the profiles will be stored so that can be entered into the systems registry complete the rest of the build and you're done that is the first image and if you've successfully completed this you are now the rank of imaging padawan but to attain the rank of azure imaging night will be more difficult and you will have to face the trials i have a new virtual machine that we've deployed here from the marketplace built on server 2019 so if you thought windows 10 was the only way to use wvd these are not the images you're looking for the first and most important thing you need to know when going through these manual steps to create an image is snapshots snapshots will take the virtual machine at the specific point in time when everything is working just fine before you go to do another process so if something goes wrong from here no problem we just revert back to our snapshot that way you don't have to start again from the beginning and since we're already starting off with an updated base image that we pulled out of the azure marketplace we can focus directly on our customizations once you start down the customization path forever will it dominate your image's destiny and that's because the end of the imaging process we will do a sys prep before we capture that vm and just to be sure we're all on the same page here sysprep is a tool that's built into every copy of windows and there's a lot of great features that sysprep will do for you the most important of which is to remove all unique identifiers from the system and that's so you can make an image from it and deploy multiple virtual machines from that image but not everything can survive the sysprep process one example of this is the windows 10 optimizations which i've covered in a previous video another question that you padawans have asked repeatedly in the academy is isn't there a limit to the number of times you can sis prep a system and the answer depends on a certain point of view certain point of view yes there is a limit to how many times you can sis prep and re-arm an image this is really not a concern because in all newer versions of windows the limit is 1001. i find your lack of faith disturbing this is additionally not an issue because of the snapshots you would take a snapshot before you go to do the sysprep process and therefore every time you go to do sysprep is the first time in this particular image we need to have microsoft office teams onedrive edge chrome acrobat reader notepad plus plus and vs code so inside our operating system i've already installed chrome and acrobat reader just by downloading the executables and running them notepad plus plus and vs code will be installed through msix app attach so we'll worry about those later which leaves us with office onedrive and teams each one of these has a special installation in a multi-session environment so let's dig a little deeper and here's an article in the azure docs specifically around creating a master image and including office onedrive and teams and the directions are right down here and if you've never done this before you need to create a configuration xml file and then give that to the office installer to do your custom installation now i've already downloaded all of the installers that we're going to use in this part of the video and you can find links to them all right here in the docs so first we'll take the office deployment tool and when you open that you agree to the license and then it will extract all of the office setup files and some example configuration files but of course we're going to use our own based on the azure docs so i'll take that configuration file and move it into the folder just to make writing the command simpler so let's open powershell and i'll just paste the exact command out of the azure docs which is setup.exe forward slash configure and then the name of the configuration xml file so that'll kick off the office install in the background and you can see that if you open the task manager you'll see that there are office click to run processes as well as the setup.exe and this process will take a couple minutes so i'll fast forward here to the end and you can make sure that it's installed just by looking at your start menu we've got access excel word powerpoint and outlook but notice that onedrive and teams are not installed that's because they were excluded in our configuration file because those need a special installation as well now because we want to control how updates function in office we have a couple other commands to run so back in the docs we've got this next large code block and i'll just copy that and over in the same folder i'll create a new file which i'll call office.cmd and that's so i can run all these commands at the same time it's just a little bit easier so we'll go back into powershell and execute that command and that's done in just a second so office is done and we can move on to one drive and as you can see from our start menu onedrive was excluded from our office build and that's because onedrive needs to be configured per machine where the default is per user now once again the commands we need come right out of the azure docs and when we run that installer it'll take roughly two minutes to do that but i've sped it up for you and now we can go back to the docks where we need to execute execute order 66. okay maybe execute was a poor choice of words we need to run the other commands that are in the docs and we can just do those as one line at a time in powershell so with onedrive done we can now address teams so at the very bottom of the dock there is a link that will take you to the teams installation docs and this is a three-part process part one we need to run this registry key so copy the path and open your reg editor and you can just paste that right here in the top and that'll take you to the microsoft key right click on the microsoft key and then go to new and create a key called teams and then back in the docs we'll copy the d word here and then add that into our registry with a value of one that lets teams know that it's running in a wvd environment next we need to install webrtc this is what's going to do the av redirections for us now i've also downloaded the vc'd redistributable installer and some images need this before the webrtc so i generally just add it anyway it's not going to hurt anything if you do that only takes a moment and when it's done we can now run the webrtc installer which finishes just as quickly now part three we can install teams so i've just copied the command right out of the docs and pasted it in powershell you do need to change the name of the msi placeholder and the log file which i've done and pasted here already and you kick that off that'll take about two minutes or so to install as well and with that here's the full list of applications that are installed on our system adobe reader chrome edge office onedrive and teams remember like i said before notepad plus plus and vs code are going to be handled by msix app attach we'll deal with that in an upcoming video so that's all the app installs that i need if you need any other customizations at this point go ahead and add them now and then when you're ready take another snapshot because it is time for the azure academy trials you must successfully capture this virtual machine as an azure managed image and deploy at least one vm from it so inside the operating system go to c windows system 32 sysprep and in there you want to run sysprep.exe and when you run sysprep you'll see this small dialog box you need to select from the drop down here the enter system out of box experience check the box for generalize and then your shutdown option should be shut down click ok and that'll remove all the unique identifiers and repackage the operating system so that we can deploy it through the imaging process so here in the virtual machine blade click capture at the top at the top you have the subscription and resource group where the vm is currently located you can change that if you want to then over here we have share image to a shared image gallery yes or no in this case we're going to choose no because the shared image gallery is a skill reserved for masters you can choose whether or not to delete your virtual machine it's okay if you do because we can restore the vm from a snapshot if we have to almost every azure region has availability zones at this point and if you choose zone redundancy then the image will be spread out across each zone in your region that's to provide another layer of high availability in this case we're not going to select that but you do have to provide a name at the bottom for your image once that's done go ahead and hit next add the appropriate tags for this particular image and then go ahead and create and now that our vm has been created click on it and then at the top we will deploy our test vm to see if you have passed the trials and walking through this experience is just like any other virtual machine but notice for your image that has been pre-selected for you so we'll just go through the rest of this process quickly and there is our working virtual machine congratulations you have attained the rank of azure imaging night but to become an azure imaging master is the power only one has achieved but if we work together i know that we can discover the secrets of automation if you've done imaging at all in the past you are familiar with the imaging task sequences through tools like mdt or system center configuration manager we can do this in a similar way through something called the azure image builder there are a few prerequisites for the image builder one of which is that you register for the service as it is in preview at this moment but will soon be generally available we will also create an azure shared image gallery and an azure managed id and the service will use the permissions of the managed id to work with the image gallery and we'll be using an arm template to create our imaging task sequence in the resources section down below i've given you a link to this arm template this is for the azure image builder to help get you started you will have to make some changes here but i'll walk you through them first we have the parameters section at the top you'll need to give your template a name an api version and a location where you want the service to be running and we'll be picking east us in this case and here we don't need any variables at this time but you could certainly add them if you wanted to in the resources section we have a brand new resource for the azure image builder called an image template and here's where we'll apply those input parameters and here we also have a section for identity this is that user assigned managed id that you'll create and then assign permissions to work with your shared image gallery and like all azure resources once you've created it the user assigned managed id will have a resource identifier and you just put that right over there the next section is for properties here we have how long the build process can take at maximum and if it reaches 120 minutes then it will time out so be sure that whatever it is you're doing in the later phases falls within 120 minutes or you can change the build timeout parameter then we have the vm profile this is the size of the virtual machine that the service will spin up to do the image build and capture process and if you're pulling a source image which is our next section out of the azure marketplace then be sure that you leave the os disk size here as 127 since that is the default for azure marketplace images speaking of the source the one that we're going to use is the windows 10 multi-session image that has office 365 already baked in and that'll save us a few steps so that's our source the next major section is the customizations here's where you can install applications security baselines and other environmental configurations for your image in windows those need to be provided as powershell scripts and those scripts do need to be accessible to the azure image builder service and our example here of teams this is teams by the way with the av redirection stuff all baked into the script and that script is located on a public github repository two other kinds of important customizations you can add is windows reboots and windows updates you should always have windows update running at the end of your process that way your image is always up to date and what that means is that when you run this template next month after all the new patches come out they'll all get updated and you'll have a new version of your image without you having to do anything and the last major section is where we will distribute the new image that's been created to the shared image gallery and over there we have the particular regions that we will replicate the image into and after you run that template in azure you get a image template resource here at the top we have that source image information of publisher sku offer and version showing us that it is the windows 10 multi-session with office image we've got our distribution section here at the bottom where we've got our shared image gallery set up and then you can see the rest of the details up here at the json view and just to review this one more time we have our source image section we have our customization section of powershell scripts windows reboots and windows updates and then at the bottom we have our distribution section to our shared image gallery and notice one important thing about your distribution even though we're gonna send this image to all three of our regions japan west uk south and us east i've only listed us east here inside the image template the reason for this is once the image has finished creating which in my case will take about 20 minutes any further replications to other regions are going to take additional time and i just don't want to wait that long to make sure that it works i can certainly replicate the images separately to the other regions after the fact and the last section at the bottom are those properties for the image template which is the build timeout the vm sku and the user assigned managed identity that i've given permissions to do all of this work now the last important button we need to click here is the start build button at the top and that'll send this image template off to the azure image builder service and the service is going to spin up a resource group with a really long name like this one and then in there it'll build all of the different resources needed to create build and capture your image automatically now the nice part of this is once the service is done it will clean up after itself and delete all of these resources and when it's all done you'll have a new image sitting inside your shared image gallery ready for us to deploy in our next episode when we provision out our host pools now i've only shown you today a glimpse into being an azure imaging master but i will have a deeper level of training coming soon on the azure image builder so be sure that you are subscribed and have clicked the notification bell so you don't miss that one and let me know what you think about azure academy videos with a star wars twist if you want to see more of this then help this video get to 500 likes and i'll be happy to make more of these and i'll tell you what if we even get to a thousand likes on this video i'll rebrand the whole channel so up to all of you but the circle is now complete when we began you were but the learner now you are on the way to being a master however mastering one aspect of azure does not mean that you have mastered it all there will always be more to learn your path begins here with our az-140 series or you may continue down the dark path with the latest video at the azure academy the choice is yours
Info
Channel: Azure Academy
Views: 3,746
Rating: undefined out of 5
Keywords: Azure Imaging Padawn, Azure Imaging Master, Az-140 wvd imaging, Azure Imaging Knight, In An Image Gallery Far Far Away, AZ-140 ep14, vm imaging, azure image gallery, azure Virtual Desktop, az-140 Windows Virtual Desktop Specialty, az-140 WVD Specialty, Windows Virtual Desktop, Image Gallery, Azure Academy, az-140, WVD, Azure image definition, WVD Certification, Windows Virtual Desktop Specialty, azure image builder, Master Imaging, custom images, Yt:cc=on, Cloud PC, snapshot
Id: teOD3z0PIZ0
Channel Id: undefined
Length: 18min 17sec (1097 seconds)
Published: Sun Apr 18 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.