Skip to content

sophiecosgrove/terraform-api-gateway-demo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Internal Amazon API Gateway with Terraform

Intended Architecture

 Architecture Diagram

Deployment Order

In order to avoid dependency issues it is recommended to execute deployment of resources in the following order:

  1. VPC
  2. Relational Database
  3. DynamoDB
  4. S3
  5. Load Balancers
  6. Code Deploy
  7. ECS Cluster
  8. ECR
  9. API Gateway
  10. Backend Microservice 1
  11. Frontend Microservice
  12. Backend Microservice 2

Note: Relational Database, DynamoDB and S3 are dependent on the microservices used in this specific implementation. Only use them in your infrastructure if your applications need them, else replace with your own infrastructure and skip to Load Balancers .

VPC

Init and apply from:

    cd account/environment/infrastructure/vpc

Relational Database

  • Used by the backend users application to persist data.

Init and apply from:

    cd account/environment/services/rds

DynamoDB

  • Used by the backend products application to persist data

Init and apply from:

    cd account/environment/services/dynamodb

S3 Bucket

  • Used by the backend products application to post and persist images.

Init and apply from:

    cd account/environment/services/s3

Load Balancers

Init and apply from:

    cd account/environment/services/load-balancers

Code Deploy

• Used to implement a blue green deployment style.

Init and apply from:

    cd account/emvironment/services/code-deploy

ECS Cluster

  • The cluster in which all the services reside.

Init and apply from:

    cd account/emvironment/services/cluster

ECR

  • After applying this step you will need to push your images to the repositories before continuing.

Init and apply from:

    cd account/environment/services/ecr

API Gateway

Init and apply from:

    cd account/environment/services/api-gateway

Backend Users Service

  • The first service to go up in order to resolve dependency issues.

Init and apply from:

    cd account/environment/services/ecs-backend-users

Frontend Service

Init and apply from:

    cd account/environment/services/ecs-frontend

Backend Products Service

Init and apply from:

    cd account/environment/services/ecs-backend-products

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages