Click here to Skip to main content
Click here to Skip to main content

Tagged as

Go to top

How To Deploy a Web App in IIS

, 8 Nov 2011
Rate this:
Please Sign up or sign in to vote.
How To Deploy a Web App in IIS

Introduction

Listed below are the steps to deploy a web app in IIS.

  1. Click start. Click Run.
  2. Type inetmgr in the Run dialog Box.

  3. Expand the localComputer. Right Click on the Sites. Click Add New Site as shown below:

  4. Type the name of the web site. In my case, it is "MyWebSite". Type the location of the web application or site. Give a port number (You have to manually add this port number to inbound rules of Windows Firewall later). And then press OK.

    If a connection with that port number already exists, then give another port number.

  5. Right click on the site name ("MyWebSite" in my case), click on "Manage Web Site" and "Browse".

  6. In the sub directories of the web site, if any web.config files are present, remove the tags with names authorization, roleprovider, profile, members. As this may cause the error as shown below:

  7. Change the Framework of the application pool to v4.0:

  8. ******************************************

    Change the "CodeBehind" in the aspx file to "CodeFile".

    Change the URLs to the appropriate directory. (Since ~ means root directory, it has a different meaning when executed in Visual Studio when compared to IIS.)

  9. All the above steps make the site work from the same computer in which IIS is installed. If you go to another computer and type the IP address of the system (in which IIS is installed), then you may not be able to access the website. For this, you have to configure the port in the Windows Firewall.
  10. Open the Windows Firewall from control panel as "Control Panel\All Control Panel Items\Windows Firewall". Click "Advanced Settings".

    Right click on InBound Rules as shown below. And fill the details as necessary.

That's it! You can access the web site (hosted with IIS) from within the LAN by just typing the IP address of the system on which IIS is installed as:

http://IPAddress:Portnumber e.g.:- http://192.168.1.1:90 

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Share

About the Author

shashikanth 2011
Software Developer GGK Technologies
India India
No Biography provided

Comments and Discussions

 
QuestionPls sir sort out this problem in mine case while deploying website on IIS. Pinmembersandeep kr. sharma21-May-14 1:51 
GeneralMy vote of 3 PinmemberDmitriy Dokshin5-May-14 9:09 
GeneralMy vote of 5 PinprofessionalKaviSuja4-Sep-13 19:47 
GeneralMy vote of 4 PinmemberMember 916699029-Jun-13 16:25 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

| Advertise | Privacy | Mobile
Web02 | 2.8.140916.1 | Last Updated 8 Nov 2011
Article Copyright 2011 by shashikanth 2011
Everything else Copyright © CodeProject, 1999-2014
Terms of Service
Layout: fixed | fluid