Watch videos with subtitles in your language, upload your videos, create your own subtitles! Click here to learn more on "how to Dotsub"

2- Deploying the Application

0 (0 Likes / 0 Dislikes)
deploying an ASP.Net app is pretty easy right click the project and go to publish we have this concept here called publish profile so depending on where we are going to deploy our web app to we can create the profile that includes all the setting with this next time we want to deploy again we can select the profile so we don't have to fill out all the setting again on this page you see we have 3 publish targets Microsoft Azure Websites so if you want to deploy your application to Asure you come here now this point you have to login and if you have any existing website it will be listed here otherwise you can create a new website import is useful when there is an existing pubish profile you want to use in the previous version of Asuze this is how we deploy our application to Azure So on Azure portal we download the publish profile that includes all the setting and then we import it here, and chances are some web hosting company may give you a publish profile the third option is used to create a profile from scratch imagine we want to deploy this application to GoDaddy so we give it a name GoDaddy Profile now on the connection tab, we have a few different publish methods the one that you will probably use most of the time are FTP and File system we also have WebDeploy which only works if the target IRS is configured to support this so it requires a few administrative tasks on the target window server and with this we can deploy directly to the IRS website web deploy package is similar to webdeploy except it doesn't deploy directly to IRS it creates a Zip package that can later be used for different process deploying to IRS but again the target IRS should support webdeploy ususually we use FTP or have our own deployment tool so I have to publish a project on a file system let's select file system set the target location and in the setting page we have this configuration dropdownlist with release and debug now if you are deploying for production you should use the release mode later I will show you how to create configuration for eg specific configuration for your testing or staging environment and then they will be populated here so let's imagine we want to deploy this application to production now note that here in the DB, we have this message DB publishing is not supported for this publish method but if you go back to the connection tab and change the publish method to web Deploy we get this check box Execute Code First Migration with this when your application start up it automatically run all your pending code migration to the DB so no matter what version your databases at it will be automatically migrated to the latest version no this is a great productivity booster because you don't have to do anything extra while deploying your database while not all teams are comfortable with this approach in a lot of places you have to create a SQL scripts to migrate your DB and then either give it to a DBA to responsible for that or import it to an existing homemade DB deployment tool So I will cover that in the next lecture now back to the connection tab, let's put this back to the file system and finally publish in the output window we can see the progress of the publish wizard so site was published successfully now in the target folder we got bin which includes the assemply for our application so we got AutoMapper and Entity Framework Glimpse and a bunch of other assembly inlucding Vidly which is the compilation of our C# Code in the content we have all the style sheet fonts, scripts so these are the files that we need to copy to the target folder on our webserver next we are looking at publishing the database

Video Details

Duration: 4 minutes and 42 seconds
Country:
Language: English
License: Dotsub - Standard License
Genre: None
Views: 1
Posted by: lpk1234 on Nov 5, 2019

Caption and Translate

    Sign In/Register for Dotsub to translate this video.