World wide web

Network Guide

How to setup and use a Web Server

Setting up IIS Web Server in Windows

  1. Login to server or PC
  2. For servers:
    1. Load Server Manager, Add Roles and Features.
    2. select Roles, Web Server (IIS).
    3. Add required features.
    4. Add or enable any required features for web server.
    5. Click Install.
      Web Server role
  3. For workstations:
    1. Open Control Panel, Programs and Features and select 'Turn Window features on or off'.
    2. Select Internet Information Services, Web Management Tools and World Wide Web Services.
    3. Click Ok to install.

      IIS on Windows 10
  4. To configure the web server, use the Internet Information Services (IIS) Manager console.
  5. Use Basic Settings to configure location of web pages.
    1. Default document location is c:\Inetpub\wwwroot.
  6. Use Bindings to change the IP address, Port, Host name and protocol (HTTP or HTTPS).
  7. Use the IIS settings to in main IIS window to change other site specific settings.
  8. Additonal plugins can be installed via the Web Platform Installer e.g. .NET, PHP, Python, drivers, IIS features.

  9. Default web site
  10. Once configured, you can access the web site on http://localhost. If you want to access it by name, then add the web site
    name onto DNS, or add it to your hosts file in c:\Windows\System32\Drivers\Etc.

Installing Web Server for Unix or Linux

  1. Login to the server with user with administrator privileges (e.g. sudo).
  2. Install the package using whatever method suitable.
    1. A package manager.
    2. Enter apt-get update; apt-get install apache2 (or nginx)
    3. Enter yum install apache2
  3. Configure the web server.
    1. For apache2, see /etc/apache2.
      1. Create webserver.conf in sites-available/sites-enabled
        (use copy of 000-default.conf as a template for new sites).
    2. For nginx, see /etc/nginx.
      1. Create webserver.conf in sites-available/sites-enabled
        (use a copy of default as a template for new sites).
  4. Create or copy web pages to Document root location e.g. /var/www/html.
  5. Restart the web server service.
    1. Run systemctl restart apache2 or apachectl restart
    2. Run service apache2 restart
    3. Run systemctl restart nginx
    4. Run service nginx restart.
  6. Visit website via http://localhost.