Module 7: Nginx Web Project

Welcome to the capstone project! In this module, you'll apply everything you've learned to set up a real web server using Nginx. This hands-on project will demonstrate your Linux skills and prepare you for web development tasks.

Real-World Skills: Setting up a web server is a fundamental skill for web developers. This project gives you practical experience that you'll use throughout your career.

What You'll Learn in This Module

Module Objectives

By the end of this module, you will be able to:

Why This Project Matters

This capstone project is important because:

Project Overview

You'll create a simple 3-page website and serve it using Nginx:

Website Structure

my-website/ ├── index.html # Home page ├── about.html # About page ├── contact.html # Contact page ├── css/ │ └── style.css # Styles └── images/ └── logo.png # Images

Skills You'll Use

What is Nginx?

Nginx (pronounced "engine-x") is a high-performance web server:

Project Workflow

Here's the step-by-step process you'll follow:

  1. Install Nginx: Use APT to install the web server
  2. Create Directory: Make a folder for your website
  3. Create Pages: Build HTML pages with content
  4. Add Styles: Create CSS for visual styling
  5. Configure Nginx: Set up the server to serve your site
  6. Start Server: Launch the web service
  7. Test Locally: View your website in your browser
  8. Troubleshoot: Fix any issues that arise

Prerequisites

Before starting this project, you should be comfortable with:

  • Basic command-line operations (cd, ls, mkdir, etc.)
  • File permissions and ownership
  • Installing software with APT
  • Text editing (using nano or another editor)
  • Basic HTML (helpful but not required)
Learning Opportunity: Don't worry if you're not an HTML expert. We'll provide simple templates that you can modify and learn from as you go.

Getting Started

Ready to build your first web server? Start with installing Nginx and setting up the basic configuration.

Start with Nginx Installation

Quick Terms to Know

Here are some terms we'll be using throughout this module:

  • Web Server: Software that serves web pages
  • Document Root: Directory where website files are stored
  • Service: Background program that runs continuously
  • Port: Network endpoint for web traffic (usually 80)
  • Localhost: Your own computer (127.0.0.1)
System Requirements: Make sure you have sufficient disk space and permissions to install software and create files. You'll need sudo access for some operations.

Success Criteria

After completing this module, you'll have successfully:

  • Installed and configured a web server
  • Created a multi-page website
  • Managed files and permissions
  • Started and stopped system services
  • Tested your work in a web browser
  • Gained confidence in your Linux skills
Congratulations! Completing this project means you've mastered the fundamentals of Linux and are ready for web development challenges.
What's Next? You've mastered local web server setup! In Module 8, you'll learn to deploy your nginx website to remote servers using SSH and file transfer tools.