GithubHelp home page GithubHelp logo

clj-ecs's Introduction

Terraform Fargate service for a Clojure app

Provides and example of a AWS Architecture for running a ECS service. The app provided in the repo is a JVM/Clojure application, built into Docker image via pack.alpha

Architecture

The AWS architecture is created by Terraform modules:

A VPC with public (for ALB) and private (for backends) subnets. Contains the following resources defined via Terraform:

  • aws_eip.nat
  • aws_internet_gateway.igw
  • aws_nat_gateway.nat-gw
  • aws_route_table.private
  • aws_route_table.public
  • aws_route_table_association.private-a
  • aws_route_table_association.private-b
  • aws_route_table_association.public-a
  • aws_route_table_association.public-b
  • aws_subnet.private-a
  • aws_subnet.private-b
  • aws_subnet.public-a
  • aws_subnet.public-b
  • aws_vpc.main

A ECS service with a load balancer. Contains the following resources defined via Terraform:

  • aws_cloudwatch_log_group.backend
  • aws_ecs_cluster.backend
  • aws_ecs_service.backend
  • aws_ecs_task_definition.backend
  • aws_iam_role.backend
  • aws_iam_role_policy_attachment.backend
  • aws_lb.backend
  • aws_lb_listener.http
  • aws_lb_target_group.backend
  • aws_s3_bucket.backend-lb-logs
  • aws_s3_bucket_policy.backend-lb-logs
  • aws_security_group.backend
  • aws_security_group.lb

Module for Continuous Integration resources. Contains the following resources defined via Terraform:

  • aws_ecr_repository.backend

Below is a network diagram of the architecture:

Architecture picture

Todo

  • Terraform usage instructions
    • tools/terraform-init
    • Module deployment order (start from here)
  • CircleCI setup
  • Database module
  • State file encryption setup
  • Application environment variables as single Terraform variable of type map, embed as JSON encoded string to container definition
  • EC2 "bastion" node in private network for port forwarding via SSM

clj-ecs's People

Contributors

viesti avatar

Stargazers

 avatar  avatar

Watchers

 avatar  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.