Giter Club home page Giter Club logo

aws-multi-region's Introduction

Terraform Final Task ITI

This repository contains the Terraform code to deploy infrastructure on AWS in two different region. It includes creating a VPC with public subnets, launching EC2 instances in the public subnets, Create DynamoDB,Store the state file on s3 bucket.

AWS Architecture

terraform final task ITI drawio

Overview

This project uses Terraform to create the following AWS resources per region:

  • VPC
  • Internet Gateway
  • Public Route Table
  • Public EC2 instances
  • DynamoDB

Prerequisites

Before running the deployment script, you will need to have the following:

  • AWS account
  • Terraform installed on your local machine
  • AWS CLI installed on your local machine
  • AWS credentials configured on your local machine
  • A S3 bucket to store the Terraform state file, and DynamoDB to use for state locking.

To get started:

Clone this repository to your local machine.

git clone https://github.com/MOstafaZaRiaa/aws-multi-region.git

Specify the code

Per each project
- File main.tf
1- Region code.
2- Bucket name for tfstate file.
3- Dynamo table name to state lock.
- File terraform.tfvars
1- AMI image belongs to region you have chosen.
2- Write instance type that you need.
3- Write DynamoDB name and key.    

Run terraform init to download the necessary Terraform plugins.

Run terraform apply to create the infrastructure.

Final Result

you can check the look inspect .terraform/terraform.tfstate, you will see that it contains the location of the state file now instead of the actual state file.

check look on state file

aws-multi-region's People

Contributors

mostafazariaa avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.