Skip to content

This project setups an infrastructure on AWS, having a VPC, Subnet, Nat instance and deploys a node and React project on the infrastructure. The entire process was automate using Terraform, Packer and Ansible

Notifications You must be signed in to change notification settings

ekpangmichael/Custom-Network-With-AWS-Terraform-Ansible-Packer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Setting up a network with Terraform

This project sets up a network and deploy the Authors Haven application on AWS

Infrastructure

When a user first visit Author's Haven Url, it hits the frontend of the application, the frontend then makes an api call to the backend which in turns makes request to the database server to get the data back to the user .

As shown in the diagram, There is a VPC with two subnets (One is private subnet and the other is a public subnet) Access to the private subnet is only through the private IP of the nat-instance

Prerequisites

Make sure you have the following softwares installs

Getting Started

Use the sample.env file to create your .env file Provide your AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY Credentials

clone the repo
git clone https://github.com/ekpangmichael/Custom-Network-With-AWS-Terraform-Ansible-Packer.git

Deploying

The project uses packer to build the images, Ansible to provision the images and Terraform to provision the infrastructure and deploy the project

cd in the directory and run

> bash deploy.sh -i

to build the Frontend, Backend and Database Images and start provisioning the infrastructure

Destory the infrastructure

You can destory the whole infrastructure with one command

Run

> bash destroy.sh

Other commands

Run

> bash deploy.sh -h or --help to access the help commands

Contributing

Feel free to contribute to this project

About

This project setups an infrastructure on AWS, having a VPC, Subnet, Nat instance and deploys a node and React project on the infrastructure. The entire process was automate using Terraform, Packer and Ansible

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published