Simple Static Website Deployment on AWS - DMJCCLT - dmj.one

Deploying a Basic Static Website on AWS Using Terraform, Ansible, Docker, and GitHub Actions

Difficulty: Easy

Overview

This project introduces you to real-world cloud deployment through a simple, practical example. You will deploy a basic static website (using HTML, CSS, and JavaScript) on AWS. The project uses industry-standard tools in an easy-to-follow manner. You will learn how to automate infrastructure, configure servers, containerize your website, and set up continuous deployment.

Objectives

By completing this project, you will:

What You Will Learn

This project will introduce you to essential cloud and DevOps concepts:

AWS Services

Project Architecture

Your project will have the following components:

Static Website

A simple website made with HTML, CSS, and JavaScript.

Containerization

Your website will be packaged in a Docker container.

Infrastructure

Steps Involved

You will work on these main tasks:

  1. Create an EC2 Instance with Terraform: Write simple Terraform scripts to set up a virtual server on AWS.
  2. Configure the EC2 Instance with Ansible: Use Ansible playbooks to install Docker and Nginx.
  3. Build and Containerize the Website: Create a Dockerfile for your static website and build a Docker image.
  4. Set Up GitHub Actions for CI/CD: Automate the process of building the Docker image, pushing it to ECR, and deploying it to your EC2 instance.
  5. Configure Nginx as a Reverse Proxy: Set up Nginx to serve your static website from the Docker container.
  6. Enable Monitoring with CloudWatch: Configure CloudWatch for basic log and performance monitoring.
  7. Establish Basic Security with IAM: Create simple IAM policies to control access to your AWS resources.

Expected Outcomes

After completing this project, you will be able to:

Real-World Benefits

This project simulates a practical deployment scenario:

Additional Resources

Conclusion

This project offers a simple yet practical introduction to cloud deployment. You will gain essential skills for automating infrastructure, managing server configurations, and deploying applications in the cloud. These skills are directly applicable to daily operations in real-world environments, setting a strong foundation for your future in cloud computing and DevOps.