# swinton/aws-ecs-fargate-example architecture

> Architecture diagram of the GitHub repository swinton/aws-ecs-fargate-example, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-07). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/swinton/aws-ecs-fargate-example
- Repository: https://github.com/swinton/aws-ecs-fargate-example

## Overview

This repository documents a small command-line example for creating and tearing down an AWS ECS/Fargate deployment. The README presents cluster creation, task-definition creation, service creation, and public-IP listing as separate user-run steps, followed by teardown. No source excerpts are available, so the graph shows only those documented invocations; it does not infer script-to-script calls or how the JSON task definition is consumed.

Main entry points: [`script/create-cluster.sh`](https://github.com/swinton/aws-ecs-fargate-example/blob/master/script/create-cluster.sh) (Create cluster), [`script/create-task-definition.sh`](https://github.com/swinton/aws-ecs-fargate-example/blob/master/script/create-task-definition.sh) (Create task definition), [`script/create-service.sh`](https://github.com/swinton/aws-ecs-fargate-example/blob/master/script/create-service.sh) (Create service), [`script/list-public-ip.sh`](https://github.com/swinton/aws-ecs-fargate-example/blob/master/script/list-public-ip.sh) (List public IP)

## Diagram (Mermaid)

```mermaid
flowchart TD

node_operator(("Operator"))
node_cluster["Create cluster<br/>[create-cluster.sh]"]
node_task["Create task definition"]
node_service["Create service<br/>[create-service.sh]"]
node_public_ip["List public IP<br/>[list-public-ip.sh]"]
node_teardown["Teardown cluster<br/>[teardown.sh]"]
node_task_config["Task definition config"]

node_operator -->|"runs"| node_cluster
node_operator -->|"runs"| node_task
node_operator -->|"runs"| node_service
node_operator -->|"runs"| node_public_ip
node_operator -->|"runs"| node_teardown

click node_cluster "https://github.com/swinton/aws-ecs-fargate-example/blob/master/script/create-cluster.sh"
click node_task "https://github.com/swinton/aws-ecs-fargate-example/blob/master/script/create-task-definition.sh"
click node_service "https://github.com/swinton/aws-ecs-fargate-example/blob/master/script/create-service.sh"
click node_public_ip "https://github.com/swinton/aws-ecs-fargate-example/blob/master/script/list-public-ip.sh"
click node_teardown "https://github.com/swinton/aws-ecs-fargate-example/blob/master/script/teardown.sh"
click node_task_config "https://github.com/swinton/aws-ecs-fargate-example/blob/master/task-definition.json"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_operator toneIndigo
class node_cluster,node_service,node_public_ip,node_teardown toneTeal
class node_task,node_task_config toneRose
```

## Components

### Other components

- **Operator**
- [Create cluster](https://github.com/swinton/aws-ecs-fargate-example/blob/master/script/create-cluster.sh): `script/create-cluster.sh`
- [Create task definition](https://github.com/swinton/aws-ecs-fargate-example/blob/master/script/create-task-definition.sh): `script/create-task-definition.sh`
- [Create service](https://github.com/swinton/aws-ecs-fargate-example/blob/master/script/create-service.sh): `script/create-service.sh`
- [List public IP](https://github.com/swinton/aws-ecs-fargate-example/blob/master/script/list-public-ip.sh): `script/list-public-ip.sh`
- [Teardown cluster](https://github.com/swinton/aws-ecs-fargate-example/blob/master/script/teardown.sh): `script/teardown.sh`
- [Task definition config](https://github.com/swinton/aws-ecs-fargate-example/blob/master/task-definition.json): `task-definition.json`

## Connections

- Operator → Create cluster: runs (evidence: `README.md`)
- Operator → Create task definition: runs (evidence: `README.md`)
- Operator → Create service: runs (evidence: `README.md`)
- Operator → List public IP: runs (evidence: `README.md`)
- Operator → Teardown cluster: runs (evidence: `README.md`)
