Tuesday, August 21, 2012

Deploy your Website Using IIS 7 - Part II


In Part I of this article, I explained how you could export a package of your website from IIS 7.  If you haven’t already, please read that blog here before continuing with this blog. 

As I pointed out in that blog, it is an industry best practice that developers not have access to the production server.  To deploy a website from the Test environment to the Production environment, I would export a package of my website in the Test server.  I would then instruct the Release team (or their equivalent) to import this package into the IIS of the Production server.  All files in the package contents would be identical in both environments.

Of course, you would want to exclude the web config files and SSL Certificates and other environment-specific files from the package you export.

Here in this blog I explain how your Release team can import a package using the IIS Manager and the Web Deployment Tool in IIS 7.0 or above.

Import a Package


1.     Open the IIS Manager by clicking Start -> Run and typing INETMGR

2.     In IIS Manager, in the Connections pane, select the Server node

3.     In the right-hand Actions pane, under Deploy, click the Import Server or Site Package… link to launch the wizard



4.     Select the package that you exported from the Test server (per Part I of this article).





5.     Enter the Password used to Encrypt the Package





6.     In the Import Server or Site Package dialog, Select All the Contents of the Package




7.     Click Next


8.     Confirm the Server Package Import.  Click OK.




9.      The wizard will now complete the package installation process.  When it is complete, you will see a Summary page that provides a high-level overview of what items were installed from the package.  The Details tab will give a lot of details on exactly what was installed.  Click Finish.




That’s it.  You (or your Release team) have now deployed your website from your Test environment to your Production environment using IIS 7 Manager.