Nicolas De Loof 0eab586106 Create CloudMap private namespace and register services 5 years ago
..
cmd 0eab586106 Create CloudMap private namespace and register services 5 years ago
pkg 0eab586106 Create CloudMap private namespace and register services 5 years ago
LICENSE 1312eec077 Project skaffloding 5 years ago
Makefile 0eab586106 Create CloudMap private namespace and register services 5 years ago
README.md 9a6fe86a86 Introduce "Validate" phase to check/make app ECS-compliant 5 years ago
go.mod 52c6177ff7 API mock and a test case relying on it 5 years ago
go.sum 52c6177ff7 API mock and a test case relying on it 5 years ago
golangci.yaml 52440a4732 Setup Github Action for CI 5 years ago

README.md

Docker CLI plugin for Amazon ECS

Architecture

ECS plugin is a Docker CLI plugin root command ecs require aws profile to get API credentials from ~/.aws/credentials as well as AWS region - those will later be stored in a docker context

A compose.yaml is parsed and converted into a CloudFormation template, which will create all resources in dependent order and cleanup on down command or deployment failure.

  +--------------------------------------+
  | compose.yaml file                    |
  +--------------------------------------+
- Load
  +--------------------------------------+
  | compose Model                        |
  +--------------------------------------+
- Validate
  +--------------------------------------+
  | compose Model suitable for ECS       |
  +--------------------------------------+
- Convert
  +--------------------------------------+
  | CloudFormation Template              |
  +--------------------------------------+
- Apply
  +--------------+      +----------------+  
  | AWS API      |  or  | stack file     |
  +--------------+      +----------------+
  • Load phase relies on compose-go. Any generic code we write for this purpose should be proposed upstream.
  • Validate phase is responsible to inject sane ECS defaults into the compose-go model, and validate the compose.yaml file do not include unsupported features.
  • Convert produces a CloudFormation template to define all resources required to implement the application model on AWS.
  • Apply phase do apply the CloudFormation template, either by exporting to a stack file or to deploy on AWS.