Day 23: ASP.NET Application end-to-end Build & Deploy | Live Project-1 | Part-1

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hey everyone good morning and good evening okay let's start with today's session let's see what exactly we're doing today okay so last time we spoke about work item management let me go and do a quick recap okay so last time we spoke about work item management we saw how we can create work items we saw how we can migrate work items we saw how we can create queries out of the work item and this is how you will be playing around with work items in real time so that was about work item today we'll focus on our first application wherein we'll be creating a first application in asp.net so this is basically the first project and then we'll talk about continuous integration and we'll be building that application and we'll be deploying that application also okay so anyone has any questions till now guys anyone has any difficulty completing the assignments any doubt till now if not then there's a prerequisite before we start go ahead and download visual studio any version will be okay 2019 is preferred so visual studio 2019 for Windows 10 or whatever version of Windows you're using or if you're using Mac you can even install visual studio for that you can go with the latest version 2022 also that doesn't matter nothing will change it's only a minor change or else if you want you can go with 2019 this is the link from where you can download this it's a simple exe file guys just have to click next next next and your Visual Studio will get installed on your local system so go through this link there will be an installer which will be running so while you're doing an installer this is something will get open just give me one let me show you the installer so this is the V Visual Studio installer which will get downloaded and in this installer there are two plugins which are required so make sure to install those two plugins wait while the install is coming up so it's a Community Edition guys which you need to download not the Enterprise one the Enterprise comes only for $30 is free post that you have to go and purchase license so we don't need the Enterprise version we need the community version okay now in this these are the boxes which you need to check the first one asp.net web development and Azure development these are the only boxes which you requir because if you down check everything it's a big file which will get downloaded on your local system so we don't want unnecessary things only thing I required will be aspn web development and we'll need a Azure development that's it these are the plugins which is required when when you get this individual installer page select this plugin click on install automatically these plugins will get installed okay so this is a prerequisite so make sure to download visual studio so there are multiple IDE tools which we will be using in this course the first one is Visual Studio second one is vs code so these are the IDE tools IDE tools are nothing but it's a integrated development tool wherein you get support of various plugins okay so basically I just want to give you a look and feel how the developer will be developing an application and how they will be using git using IDE tools okay so just to give you the look and feel we are just installing all this and developing things from scratch okay make sense okay just to reiterate Bia uh Visual Studio toolkit which you need to install I have shared the link in the group chat just go and install Visual Studio okay and there are two plugins which is needed it's asp.net and Azure development plugin while you're installing the visual studio toolkit okay let's start before I start I need to create a repository because all my application will go inside this repository okay so we haven't used this also yet okay forget about this let's create a new one name it as um devops web app give whatever name you want to give so this is the name which I'm giving to my Repository so I will be creating a web app web application so I'm just giving a name as web app this is in the main branch if you want to create new Branch out of it so it's better to do it right itself this is the right time to do it and as I said this is how you'll be start linking your work items if you want to link any work items so this is the first place of linking your work item and eventually link it with everything whatever you do if I link it over here so what will happen if I do any let's do a link user story this let's select user Story 3 so what will happen if you go and look into the user story now that's user Story 3 let's go to the boards where is three this is three now you'll see the develop Branch got linked automatically now whatever I do at the develop Branch everything will be posted over here whether you do a push whether you create PR whether you do a commit everything will start popping up over here so that is a benefit of linking things okay so in reality the the developer who creates a temporary Branch not for the develop Branch he'll not link a develop Branch so he creates a temporary Branch so that temporary Branch will be linked and whatever he does on the temporary Branch everything will start popping up okay so we got the develop Branch created and let's go and open Visual Studio now or else if you want to clone there are I I have showed you the way of cloning like just get clone but if you want you can directly clone into a IDE tool like what you what exactly we using visual studio see it will open a visual studio for me and it will clone the repository directly so even this is a way of cloning things directly okay I feel this is timeconsuming because it will go in open visual studio for me then it will ask ask me for a sign in and things like that it will do so let's wait while we are cloning just to reiterate what exactly we are doing so this complete week we'll focus on creating an application we'll focus on building that application we'll focus on releasing that application there are two types of build which you can do in Azure devops a classic and a yaml based so we'll do both okay first we focus on classic we'll see how the classic build and release happens then the second we'll focus on yaml how the yaml build and release will happen because before yaml we need to understand what is yaml syntax the basic of yaml then only we'll start writing the yaml scripts okay so this will be the complete week dedicated to build and release or maybe we'll take more than a week not just a week it's not sufficient so we'll take more than a week okay so if you see the visual studio got opened over here it's taking time let's wait while the page is popping up not responding okay okay while we are waiting for this let's understand what exactly is continuous integration let me open my PPT or else I have it in this PPD also just wait okay so do we have everything over here integration yeah integration is there what happened to visual studio still not responding okay let me close this visual studio and reopen it not visible in the tax manage okay let's wait while this is not responding so this is one way of cloning guys I'll show you a different way of cloning directly inside the visual studio that is it will not open things automatically so this is opening multiple windows automatically that's why it's not responding right now and I'm opening Visual Studio after long that's also a case Okay so before I jump on and start creating applications and start building the application the very important topic is what exactly is continuous [Music] integration what exactly is continuous integration is the very important topic which we need to understand and this is definitely a interview question not straightforward that they will not ask you what exactly is continuous integration but it definitely will be an interview question when you go for appear for a interview I'll give you a scenario how exactly the question will be asked later but for now can someone tell me what is continuous integration what do you understand with the word continuous integration or continuous build anyone any anything will be okay guys so whatever you know just tell me based on that we'll understand yeah I would say a um a continuous integration is a complete um when you're talking of your your plan a continuous planning a continuous testing and building of code like nonstop but going automatically perfect anyone else wants to add something anyone no one country integration means uh we can build and release uh pipelines with the help of in between there is a approval manager approval that means country integration MH this delivery and deploy is something related to There Is No Interruption like there is no need to requirement for approval like manes and that so this is the difference between integration deployment perfect okay so delivery deployment is a different story altogether so that is something we'll do later for now we focus more on integration part and as rightly said by you guys that integration is a continuous process wherein the build and the testing is happening continuously okay what do I mean by continuously that is something we'll discuss in details now so integration as we all know integration starts with a developer when a developer gets a user story assigned and the developer was asked to create any new feature or to do any new development okay so he makes use of any tool like you can make use of Visual Studio the way we are using visual studio now Eclipse vs code depending upon the code which he's writing if he writing Java then Eclipse if he's using net then definitely visual studio if using Python and all then we got pycharm so we got dedicated IDE tools which is more specific to that language it doesn't mean that you cannot write python in Visual Studio guys you can even write python in Visual Studio so it's just what tool the developer is comfortable with the developer will get go with that tool okay in my example I've took three because we'll be using Java also later so visual studio eclipse and vs code now he makes use of those plugins and he starts building his code once he done with done with the local build he will push the changes to the local G repository so basically he will commit to the local local branch itself so once he done with the testing and everything development he will push the changes to the local kit once everything is well thorough at the local then he will push the changes to the remote repository now remote repository could be anything in my case I have take took Azure repos it could be be GitHub it could be git lab anything whichever they like so there's no restriction as such so whatever the project is using based on that they will push the changes okay so development using the IDE tool local commit when the local commit is done pushing the changes into remote repository when the changes goes into remote repository your aure pipelines now your build will get triggered automatically your Azure build will get triggered automatically because we have we are talking about continuous integration okay so in continuous integration the build gets triggered automatically so the build has it has multiple phases you will have your build you will have your test you will have your release you will have your deploy so over here we just talking about build test we are talking about continuous integration so there's no release and deploy release deploy will be in your contined delivery or continuous deployment whichever model you're selecting for now focus on integration so what exactly build and test is all about what exactly happens in the build so in the build the code gets merged with your remote repos okay so basically your code is getting merged and actual build is nothing but compiling source code what will happen your source code will will get compiled post the compilation so this is your actual build which is happening over here your com source code is getting compiled over here and then you will have your unit test cases so if there's any unit test cases which needs to be executed you will have that test cases getting executed post that if you have any automated test cases such as if you have integrated sonar QQ what exactly is sonar Q we'll understand that in a greater details later for now sonar is nothing but it's a static code analysis okay so it has list of policies and list of profile using which it will go and do a static code analysis on your source code okay based on that it will give you a quality report and based on that if any of the criteria is not meeting then it may break your build also so we have all such conditions with sonar so you'll have your unit test cases integrated then you will have your static code analysis done post that you will have your artifacts created artifact is nothing but it's a output file which will be eventually deployed at your end server in case of java it could be a jar file it could be a war file in case of net it could be a zip file it could be a dll whatever you're doing if it's just a config chain it could be a dll if it's complete application it could be a zip file in case of python again it will be a zip file in case of SQL database automation it could be a dpack file or a backpack file these are all extension packages which will be eventually created at the end of the day when you're when you're when you're done with a successful build okay so what is build merging the code with the remote Repose compiling the source code running the unit test cases running the code analysis creating a build artifact this is all together forms a continuous integration this is a continuous loop your development never stops your developers keep on developing things he will push the changes to the local he'll push the changes to the remote pose that your build pipeline will trigger the build pipeline will have all this task fetching the code from the remote repository compiling the source code running the test cases running the automated test cases publishing the artifact then this complete process is known as continuous integration process make sense anyone any questions over here okay straightforward continuous integration workflow now how do you get this question in an interview they will not directly ask you questions what is continuous integration they will simply tell you that I am a net developer and I'm creating a web application in net that a web application needs to be deployed on AKs give me me the complete cicd flow how do I build and release the net application this is a scenario based question so the first part is continuous integration wherein you talk about all this now because I I have mentioned AKs so there are multiple other things also comes in picture about your Docker file creating image pushing the image and things like that so let's not confuse yourself let's uh change the question let's deploy this application on either on VM or Azure web app okay so in that case this image and all will not come that is something we'll do it in later don't worry I'll I'll show you how do we deploy a microservice application on kubernetes and all that is something we'll do it later but for now let's keep it very simple how do we deploy this application on Azure VM or Azure web app okay so in this case you don't need to add Docker file and deployment files and all this okay so this is what your continuous integration basic flow should look like and this is what you need to talk about in an interview when you're giving an interview and explaining that you have worked on uh end to end build and deployment for any application now this flow will not change irrespective of what application you're using whether it's a Java application the only difference will be while building the Java application you'll be making use of a third party build tool such as as Maven grel or end anyone of anyone you can use it in case of net you will be using vs build or Ms build so these are all plugins which will help you build your application okay so nothing much different rest all the flow remain as it is okay guys so this is continuous integration let's if you're all good with this let's close this PP and let's go back to visual studio this guy is still not responding okay it's responding not this account use a different account okay my account is this one so I just log in this is the email ID successfully logged in okay now I can simply go in this is my local path where my uh repository will be cloned let's change it to the desktop that is a default path guys Source repo I'll go to this PC and put it on the desktop itself close let's give it a name devops web app clone now this is other way of cloning directly cloning to the IDE okay there's one more option over here I think we have not covered this generate G credentials now why do you use this this option why do you need to generate credential because as if now you're using your user ID password okay for cloning now where exactly this is used now this is for developers guys wherein if they want to integrate git with their application they cannot pass in the user ID password over there that is not the right way of doing so they can have a temporary get credential created see this this is how they can create and they can pass on this information over there they they they do not need to pass on their own passwords they can have this passwords created and they can pass in this okay this is also one way of cloning basically this is used within the application if they if they want to do something like fetching files within the application then executing it or if they have anything at such step in that application then they can make use of this user ID and password just keep this in mind okay now this is clone now if you see at the bottom now this git changes what you see this is a if you're using 2019 and above I think it's there in 2017 also I'm not sure there there is a git tab so basically this is a small git window if you click on this git if you go to view and if you open this git changes this is the screen which will open this screen what you see right now and at the top you can see all your branches so develop is one which we have cloned if you go into the remote you can see your main branch also if you want to check out to your main just double click and it will eventually check you out onto the main branch okay and if you want to go back to develop you can go back to develop now you're incoming and outgoing commits will be visible at the top 0 0 and at the bottom if you get see this is your one to commit so this is a SQL light file so this is uh random file which got added don't worry about this later we'll add a git ignore file which will ignore all this okay and then this up Arrow what you see this is changes which got committed and which is ready to push this is your repository devops _ web app and this is a develop Branch Where You Are right now at the top this four toggles which you see this is for fetch get fetch this is for get pull this is for git push this is get sync sync is basically we'll pull the changes first then it will push the changes so basically it will sync your local copy with the remote copy okay now if you want to create any new Branch directly you can create a new Branch also over here okay it will be created is out of develop let me tell you when the developer developing things they will not go and look into aure repos mostly all they will do it do it directly from here like if they want to create a temp Branch for their development they can simply do it over here directly this way see we are checked out with temp Branch okay now when you do a commit there are multiple options which you have Commit all commit all and push commit all and sync stash we all know what is stash correct hopefully guys what is stash get stash what it does where you keep your yeah temp tempod perfect wherein if you want to have your working directory to be clean and you don't want to lose your uncommitted task to you stash it correct okay that's good so this is a very good and very useful git Window Guys which developers will be using 95% of time and plus if you're using any IDE tool for your development like you'll be creating the build pipelines release pipeline you'll be writing the yaml scripts so even you will be using any such IDE tools okay so three ways of accessing we saw from the command line we saw from the portal from the GUI now this is the third using an IDE tool how you will be using git now with Visual Studio git comes by default this plugin which you see it's comes by default so you don't have to worry okay this is I'm using 2019 guys the this is screen is of 2019 but even if you're using the higher version you will find this screen get changes screen over there also okay let's go and create a first esp.net project okay now let me go to the files let me go to the new project okay just look for as.net core web app at the very top asp.net core now what is the difference between asp.net Legacy and asp.net core anyone any idea asp.net core web app and asp.net Legacy so the only difference is asp.net core is platform independent it can be deployed on Linux it can be deployed on Mac it can be deployed on Windows it supports IIs it supports engine X web servers and many others and if you go with asp.net Legacy that is platform dependent that means you it can be only deployed on Windows and the only web server it supports it is IIs web server so even Microsoft they knew that if they don't upgrade and if they don't make anything independent and if they so they will be thrown out of the market so they have came come up with asp.net code which is can be deployed on any OS basically okay so that is what we'll see because this is the application which we're developing right now we'll have to go and deploy it on now I'll deploy it on Azure web app then we'll deploy it on container Docker container then we'll deploy it on kuber natives then we'll deploy it on AKs we'll create that application as a image which will push eventually into ACR so many things we are doing so yeah we'll stick with asp.net core so don't worry you don't need to learn asp.net we will be using the default templates which we get get and that is a template we'll be using so it's not an hardcore application which we are developing don't worry okay so asp.net core web app this is the option we select the first and if you see it's written in shop Linux Mac OS windows and it can be deployed wherever you want okay let's click on next give a name whatever name you want to give it name it as devops web apps something like this and where exactly this is getting stored this is getting stored on your local DB repo this is the folder which we have created DB repo are you sure this is the name of the folder no this is the name of the folder devops web app okay create a solution this is the 3.1 out of support this was LTS why showing out of support this is the one which we can use 3.1 and let's go and create the latest was in 5.0 but even the 5.0 is showing out of supp okay forget about it let's go and create this project so basically what we did first we have created a me Branch okay then we clone the repos sorry first we have created the repository then we clone the repository then we have created a new Branch temp Branch then we have created a project all together these are multiple things which we do now if you go and see there are 60 there are more changes more than 100 changes should so all your files which is related to your application is getting created right now now how do you view you can view in the solution Explorer how do I get this solution Explorer go to views there's option of solution Explorer it will eventually open this so this is all related to your project you have your triw root wherein you can keep all your static and dynamic files you can keep your pages over here and all your application settings so this is a web application which you're creating and if you have any dependencies so all your dependencies will come over here we don't need to learn this we are not a developer so just an fii okay if you want to make any changes I can simply this is your index page guys basically this is your homepage wherein you can make whatever changes you want to do okay so it's welcome so I'll just edit this to welcome to devops maer okay now let's save at the top you can see the save if you want to see what exactly you're doing you can do a local build and you can test it at the Top If You see there is a integrated IIs Express this is nothing but it's a web server using which you can run this application locally now if you see this build has started so whatever we have changed the build has started and it will start your application in a debug mode and it will open a browser the default browser and it will launch the application if there's any issue you can see that in the debug mode so this is the local testing which you're doing right now so on a local host your application will be up and running let's wait it may take time guys see the debug mode has started okay so it has opened the browser on the Local Host 44345 let's wait while the application is coming up now if you see at the visual studio this is how it will look like it will start checking everything it has this Visual Studio has application inside integrated so it is also giving you application inside events you can see those events once the application is up and you can even see the memory CPU utilization which is happening right now so that's our diagnostic tool everything comes in see welcome to devops mailer this is your if I just go through all these Pages you can see those hits coming in it will come over here break points local so it will all start popping up once you start using the application you can see the events memory users CPU users you can see all the things over here so this is kind of a local testing if you want to do it you can make use of this I express and as soon as you close this window all this will be gone and you can see the debug logs over here okay so so this is a quick glance if you want to test your application locally this is how you will be doing things locally now you got more than 99 changes 99 plus changes which you have got and in this there are so many files which is not even required the cach a. CSS all these files are there so this is all added because this is the first time we adding the project if you see the a at the very extreme right a means it's been added okay if there's any changes to an existing file you'll see m m is to modified okay keep this in mind now let me do a commit let's do a initial commit okay commit all which which will basically commit to your local so this is getting committed on your local it it will not get pushed to the temp Branch but and there's no temp Branch also guys when you do a push automatically the temp Branch will also get created so keep that in mind so things are getting pushed locally done there's a commit ID got created now if you see there's one commit to push okay if you see this you got this commit ID created if you click on this commit ID you can see the history at the left hand side this is all what changes are there in this commit 105 changes okay now if I want to push I can simply push it now pushing has started if you come to the gate changes you can see successfully push temp Branch to origin now if I come back over here this Branch will would have been created automatically see do you see this the branch got created automatically did we create create this branch in the remote no that was created directly from my local now if you see this Branch this branch has all the files this is your application correct your pages if you go into the pages index.html welcome to Devos M your application is pushed into your repository it's there in the temp Branch if you want to push it in the develop Branch either you can create a pull request from here or you can create a p request from here also see as soon as I click on create pull request it took you to the same page of creating a pull request so basically developers they use visual studio if if they're working with net or net core or net or net apis or anything as such that they use this screen a lot okay so when you when they come back this is what they see now you can integrate your user story everything with it and you can just create a pull request now let's I'm not covering this uh this approval and all we have already done that okay just do a squash I don't need the unnecessary history because if you go and look into my temp Branch you can see there's a commit so I don't want that so I can have my own commit done if you go and look into the develop you can see a new commit initial commit was created readme.md was added previously now if you look into my develop I have all the changes okay this is how the developer will be working guys this is how they will be creating a temp Branch for themselves doing the development once they are done with the development they will push the changes to the develop branch and from the from the develop Branch we'll have a build pipelines okay in between if you want to put in some policies and things like that it's totally up to you if you want to restrict if want to add if you want to add Talan in between you want to have approval process you want to have Branch policies added so that is totally up to the project and what kind of security you're enabling you can go and put that okay I'll we good tell you anyone any questions any doubt before we jump on and start creating the first build pipeline anyone no one no doubt yes why not sure okay uh let's uh do a quick recap what all things we did okay what is the target we are creating a net application and we need to build and release that net application how the application is created that is none of your concern guys that will be created by developers I'll be sharing this project file this application which I've created I'll be uploading this application on the drive and if you guys want to directly access this so you can just open this folder and you can just go into this and there is a solution file over here basically if you just click on this solution file you'll have this page you you'll have something like this open okay the only thing you have to do is you have to create your own Branch own repository and copy this file contain this entire thing into that repository on your local that's it and do a get add and get push that's it okay if you want to make things very simple but this application creation was not that difficult we are just using the default template which we get it with future Studio okay then talking about that then what we did once we have the application I went ahead over here created a new Branch why did I create just to give you a glimpse I could have done things on develop Branch also but how in reality in real time the the developer they do the development just to have an idea I've created a new Branch over here then inside that new Branch I have created my project then once I'm done with my changes I tested it locally okay things were looking good no error then I pushed everything to my temp Branch when I pushed everything to my temp Branch it was reflecting in inside my temp Branch then I have created a pull request that pull request was basically from temp Branch to my develop branch and I have pushed everything from my temp Branch to my develop Branch why did I push to my develop Branch because all my pipelines the integration pipelines will be created at the develop Branch not at the temp Branch well this is a temporary Branch created by developers and it may get deleted later develop branch and the main branch is something we will be taking care so hence things were pushed into the develop Branch okay so this is what we did till now okay hopefully makes sense now this is something you need to do it by yourself then you then only you'll understand more for now this is what we did okay what next then now we can have a build pipeline created now build pipeline in uh Azure they WS to be very specific there are two types of build pipeline classic and yaml based classic is more like a GUI based wherein you can go and select the plugins manually and you can have your build pipeline created very easily the second is the yaml based which is on a concept of Pac that is pipeline as a code methodology now yaml is the one which we need to learn guys more than 80 80% of your task what you do nowadays will be based on Pac methodology so that is something we'll be focused more on but it doesn't mean that we'll not do classic we'll do classic also the classic reason is you come across some project wherein they're using all classic then you should know how to work with classic classic is very easy it's a GUI base wherein you can select the plugins manually and yaml is wherein you need to write scripts okay it's it's not that difficult don't worry about the scripting part if you don't know don't know I'll cover that from scratch so basically you need to write things by yourself and there are plugins which I'll show you which which will eventually help you to write those scripts okay so don't worry about anything if you don't know so what is the benefit of using yaml based is your build and release will be part of your repository what do I mean by rep if it is part of your repository if it is part of your repository the first thing you will have all the benefits of a git what are the benefits of get it will be versioned automatically if there's any change a commit will be created and your things will get versioned automatically secondly it will be backed up you will have multiple copies of your build and release pipelines also you can easily collaborate with other developers you can share that piece of code and if there's any changes required then the other developers can help you out doing those changes plus it will be readily available anywhere in the world and if you want to create a new pipeline out of that yaml easily you can clone and create new pipelines very easily so these are the benefits of pipeline as a code hence we will need we will need to learn pipeline as a code methodology a lot okay so start starting with classic how do we create a classic pipe L let's see that I'll go to the pipeline section the first pipeline option what you see this is where your build pipeline will come in okay okay one important thing before we jump on this there is a form which you need to fill in guys if you're using the uh azard Deo for very first time even I'm using for the very first time this is my new account this is the form which you need to fill in this is a request which will go to Microsoft and they will enable free tier agent access to you this is the form which you guys need to fill in make sure to fill in because this takes time time with along two to three working days and after that they will enable this for you so you'll get a confirmation from Microsoft once you fill in the form and then they will have the free tier agent pull access enabled to you I don't have it now is it active Okay let's go and use it and let's see because this account I have created way long but we need to fill in the form if we want to execute the pipelines okay so make sure to fill the form now itself and be ready while you come to this section you need to have your U agent pull active so that you can execute your build and releases okay or else it will not let you execute anything keep this in mind okay so this is the section wherein you can have your first build created so you just click on create build now at the top whatever you see this options whatever you see this is all telling you to write yaml scripts you see this yaml yaml yaml so basically even Microsoft is not giving you classic option to create any classic pipeline because even they want you to write yaml scripts only because classic will be sooner or later it will go obsolete so hence even I am not focusing more on that but yeah if you come down at the bottom use the classic Editor to create pipeline without EML now this is at the at the bottom somewhere is written like if someone is new and if they have coming to this screen for the very first time they will not even go to classic that is the whole thing what Microsoft is trying to do over here okay so but we'll focus on classic 4 first this is how classic will give you a GUI based approach wherein you can go and select things it is selecting asking you to select the source where exactly your source is so we we have the code in Azure git correct we don't have it in GitHub or bid bucket or Sub verion sub verion is SVN guys it's still there because there are people around the world who are still using SVN that's a centralized Version Control if you have anything as such you can use it other G apart from this if you have gitlab and all then you can so basically you need to connect to that how the connection will be created and all uh you need to create a service Connection in order to connect to the all these third party tools for now we'll stick with Azure repos I'll show you later how do we connect don't worry this is the project name this is the repository name this is the branch we are creating the first pipeline continue now again it is telling you to use the AML everywhere it is telling you to go and use yaml yaml yaml but we need to stick with classic now what exactly okay perfect let me reshare okay guys so wh we talking about the build pipeline okay so I'm not using this yaml for now so we'll stick with this plugins which we have now what application we are using we using asp.net core so if you see there are two application net desktop which is more the Legacy one and the asp.net so automatic automatically it is detecting the source code and it has detected that it has uh esp.net application so it's giving you the all the ASV doted application at the top okay so I'll select this one so as soon as I select you you can see all the relevant task which is relevant to this project and it is giving you all the tasks which can be used for building this application now new get we'll talk about new get in details but new get is just a third party tool it's a package management tool basically which is managing all the third party plugins related to asp.net so we we requireed Newgate guys even though I'm not using any dependency have not used any new get packages over here but in order to build a net application you will need new get install so in order to build your new in order to run your net application you will need new even if you're running it by yourself building it everything by yourself you will need Newgate installed on your system so this is what it is doing it is installing Newgate where exactly it is installing it is installing on the agent pool agent pool is not nothing but it's a mediator wherein all your execution is happening so if you want to build this application you need to have a agent pool correct agent pool let's go back and understand this agent pool first okay agent pool is nothing but it's a VM it's a virtual machine which has everything installed already installed like what what all things needs to be installed if you want to run a esp. application so you need to have MS build installed on top of it you will need vs build install on top of it you need a net plugins install on top of it then only you can run a esp. net build on top of it correct so this a agent is nothing but it's a pre pre-build pre-compiled VM which is which can be used to run or build any application so this is all there are two types of agent pool which you will come across I'll talk about agent pool in a great details when we uh learn agent pool so there are selfhosted agent pool and there are Microsoft hosted agent pool the one which we using the form which I have created that is for Microsoft hosted agent pool later I'll teach you how to create your own agent pool and how do you run your build and release using your own agent pool that is something we'll see later for now we using Microsoft hosted agent pool so all this task basically in order to build your net application these are the list of tasks which you need to run where do you run this is it getting executed on your local no if you see I'm using a browser based aure Dev offs okay so this is on browser so if I'm running this browser right now from Mumbai if tomorrow if I go to us I can do the same thing from there also so this is not there on my local system or nothing as such this is a browser based Azure DeVos which we using right now okay so where this steps will get executed so this steps will get executed on this agent pool from where did from where did I get this agent pool this is a Microsoft hosted agent pool so Microsoft is giving me 2,000 minutes free for my learning perspective can I use this 2,000 minute free from my production no at that time your company has to go and purchase the agent pools from Microsoft it's not free okay this is for learning Microsoft is giving me this VM free how this VM is created things like that we'll understand that in a greater details don't worry about this but for now just imagine this is a VM on on which VM which is a pre-compiled VM which has everything which is required to build your net application okay let's rename this I have some good name to it so let's name it as web app develop okay so this is for web app for my develop Branch okay guys now if you want to know more about the agent pool this is what the agent is Windows 2019 you can select other agent pool also open to Mac OS and things like that but Windows 2019 will be more relevant to your net application if I'm using a Java I would have selected UB 2 what for esp.net Windows 2019 is more relevant that is the reason it is automatically selected now if you see at this this is taking the solution file now what exactly this is this is a relative approach now I'll have let's explain let me explain this let let me break this down for you what exactly the star star and forward say star is all about let me save it for now I'm not running it today but let me SA save it for now and let's understand what exactly this is okay now if you go to your branches rip files where exactly your let go to develop Branch where exactly Your solution file is your solution file is somewhere over here correct somewhere over here now when this will execute when this pipeline will execute what will happen everything your complete source code will get copied to an agent pool server that is This Server it's a temporary server which will be created and the life cycle of that server is only limited to when the build is executing if the build fails or build gets successful the server will be automatically deleted from the back end okay now the life cycle is only limited to your build execution now in order to execute your build you will need this source code correct you need this file okay so that file will be cloned this is the location it will go and clone this solution file and it will put it on Azure AG input this is what happens in the backdrop okay then all this task will get executed because without the file the task will not get executed now because this is getting cloned on a third party server now third party it's a Microsoft server how will I how will my agent will know which where exactly the file is we cannot have a absolute path like this defined okay it will be as if now we able to view that my solution is kept somewhere over here but in reality you will have so many files so many applications it will be very difficult for you to understand where exactly the solution file is you can go and manually view it but you for agent to automatically file this file becomes very difficult so hence this relative path now what exactly this thing is doing what exactly this thing is doing let's see this these are these are divided into two category star star and then you got something like dot sln now if we all know this this is a wild card entry this means it will match anything starting with ending with sln if you have anything abc. sln or if you have anything like such as cdb like sln so anything matching with ending with sln it will go and match like something like numbers andn so it will basically match anything ending withn this is what this wild card entry is doing okay now what this guy is doing this is nothing but your levels of folder now your agent pool will not know where exactly this file is kept at what level the file is kept what do I mean by levels just imagine this is the folder which got cloned onto your Agent P now your agent put H agent pool has to go and look into the folder each folders and he needs to find this sln file okay so first he will do and he will go and check into this folder then there are so many folders okay it will look into the folder if the sln file is present or not just imagine it is not present okay then it will go again in the bin folder it will start looking do we have sln it will go in debug folder do we have sln it will go in net C and look for it do we have sln file and imagine the sln f file was found over here so such big path the your this two star will take it will be done automatically so basically what this is doing it will go and check in all the levels where this file is kept ending with do sln and it will get those files for executing the task okay so that is what it it is looking path to solution or package config so basically it is looking for the exact path where exactly the file is kept if you don't want to do this way if you want to have a absolute path you can even go and select this manually they exactly the F you can do it this way also but this is not recommended guys the reason is uh later if you want to create a new build pipeline then you need to go and manually go and change this absolute path which you have selected if it is relative you can reuse this pipeline again if you want okay so the recommended one is this one this is a way of not hardcoding anything now if you see this by this way I am hardcoding the pipeline and if I'm hardcoding anything that means I cannot reuse it okay so this is the one approach okay I think it will stop over here guys it's too much for today and we'll continue this topic again tomorrow and once the build is done I'll cover the agent pool topic first then we'll move on forward okay that's it for today if anyone has any question please do let me know we'll have this topic again recap tomorrow and we'll come continue with this build understanding this build is very important because later I'll be using the same concept and I'll have a yaml file created of the same exact same F okay so if anyone has any questions please do let me know before we wind up the call for today anyone any questions guys let me see if there's anything in the chat cron tab we haven't covered anything about cron tab P sure yet so what exactly the question is K sure can you be more specific please okay no problem so Crown tab we haven't covered but there is a way of scheduling uh things in pipelines that is something I'll cover later that's pipeline Schuler uh wherein based on timing and dates we can execute our pipelines automatically okay anything else guys nothing okay if there's nothing so thank you very much let's meet up tomorrow again and let's continue the same topic of continuous integration okay bye-bye [Music]
Info
Channel: DevOps Mela
Views: 349
Rating: undefined out of 5
Keywords: live, project, asp.net, ci/cd, build, release, azure devops, classic, aws
Id: MicIbHz389A
Channel Id: undefined
Length: 63min 17sec (3797 seconds)
Published: Tue May 21 2024
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.