Deploying a Website on IIS Server

IIS or Internet Information Services is a powerful service on Windows operating systems used for hosting websites. It is particularly useful for hosting ASP.net applications.

I’ve been playing with various editions of Windows Server 2012 at work and though it would be a good time to put together a quick guide. A few simple steps in this guide will prevent common ‘403 – permission denied’ errors.

First navigate to C:inetpubwwwroot and create a directory for your new site. You can name this whatever you want. This is the root directory of your site- place your site files here.

Screen Shot 2015-07-10 at 23.04.04

Navigate back to C: right click inetpub and select Properties. Click the security tab, then edit followed by add. Type Network Service and then ok.

Screen Shot 2015-07-10 at 23.08.02

Assign Read & execute, List folder contents, Read and Write permissions. Apply and close the window.

Screen Shot 2015-07-11 at 00.14.16

Click advanced then Enable inheritance followed by Replace all child object permissions with inheritable permission entries from this object. Apply and close all windows.

Screen Shot 2015-07-10 at 23.09.00

Open IIS Manager from the Apps window. Right click Sites and select add. Fill in the credentials for your site.

Screen Shot 2015-07-10 at 23.12.05

Back in the main IIS screen, under connections select Application Pools. Right click the application pool just created with your site and select advanced. Find application pool identity and under Built-in account select NetworkService. 

Screen Shot 2015-07-10 at 23.13.55

Back in the main IIS screen, right click the default websites and click remove. 

Screen Shot 2015-07-10 at 23.14.34

 

That’s it! Point your browser towards your domain name or IP address and you should see your site index page.

Leave a Reply

Your email address will not be published. Required fields are marked *