# fabiomfrade/infra-cluster architecture

> Architecture diagram of the GitHub repository fabiomfrade/infra-cluster, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-18). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/fabiomfrade/infra-cluster
- Repository: https://github.com/fabiomfrade/infra-cluster

## Overview

This Terraform project provisions a modular AWS Kubernetes platform: an EKS cluster with managed node groups, IAM roles, and security rules, plus optional VPC networking. The documented user-to-result flow is applying the root Terraform configuration to create the infrastructure. The README describes module responsibilities and the node-group/cluster relationship; source excerpts were not provided, so relationships beyond those documented are omitted. Paths identify the module implementation files from the tree.

Main entry points: [`main.tf`](https://github.com/fabiomfrade/infra-cluster/blob/main/main.tf) (Terraform configuration), [`modules/nodegroup/main.tf`](https://github.com/fabiomfrade/infra-cluster/blob/main/modules/nodegroup/main.tf) (Managed node group), [`modules/eks/main.tf`](https://github.com/fabiomfrade/infra-cluster/blob/main/modules/eks/main.tf) (EKS cluster), [`modules/iam/main.tf`](https://github.com/fabiomfrade/infra-cluster/blob/main/modules/iam/main.tf) (Cluster and node IAM roles)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_deployment["Deployment"]
  node_root["Terraform configuration<br/>[main.tf]"]
end

subgraph group_network["Network Infrastructure"]
  node_subnet_infra["VPC and subnets<br/>[main.tf]"]
  node_network_services["NAT, gateways, routes<br/>[main.tf]"]
end

subgraph group_cluster["Kubernetes Cluster"]
  node_eks["EKS cluster<br/>[main.tf]"]
  node_nodegroup["Managed node group<br/>[main.tf]"]
end

subgraph group_access["Identity and Security"]
  node_iam["Cluster and node IAM roles<br/>[main.tf]"]
  node_securitygroups["Cluster and node rules<br/>[main.tf]"]
end

node_operator(("Infrastructure operator"))
node_aws["AWS infrastructure"]

node_operator -->|"applies"| node_root
node_root -->|"configures"| node_subnet_infra
node_root -->|"configures"| node_eks
node_root -->|"configures"| node_nodegroup
node_root -->|"configures"| node_iam
node_root -->|"configures"| node_securitygroups
node_subnet_infra -->|"creates"| node_network_services
node_nodegroup -->|"creates within"| node_eks
node_iam -->|"provides roles"| node_eks
node_iam -->|"provides roles"| node_nodegroup
node_securitygroups -->|"configures rules"| node_eks
node_securitygroups -->|"configures rules"| node_nodegroup
node_eks -->|"provisions"| node_aws
node_nodegroup -->|"provisions"| node_aws
node_iam -->|"creates roles"| node_aws
node_subnet_infra -->|"creates network"| node_aws

click node_root "https://github.com/fabiomfrade/infra-cluster/blob/main/main.tf"
click node_subnet_infra "https://github.com/fabiomfrade/infra-cluster/blob/main/modules/subnet_infra/main.tf"
click node_network_services "https://github.com/fabiomfrade/infra-cluster/blob/main/modules/subnet_infra/main.tf"
click node_eks "https://github.com/fabiomfrade/infra-cluster/blob/main/modules/eks/main.tf"
click node_nodegroup "https://github.com/fabiomfrade/infra-cluster/blob/main/modules/nodegroup/main.tf"
click node_iam "https://github.com/fabiomfrade/infra-cluster/blob/main/modules/iam/main.tf"
click node_securitygroups "https://github.com/fabiomfrade/infra-cluster/blob/main/modules/securitygroups/main.tf"

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_root toneBlue
class node_subnet_infra,node_network_services toneAmber
class node_eks,node_nodegroup toneMint
class node_iam,node_securitygroups toneRose
class node_operator,node_aws toneIndigo
```

## Components

### Deployment

- [Terraform configuration](https://github.com/fabiomfrade/infra-cluster/blob/main/main.tf): `main.tf`

### Network Infrastructure

- [VPC and subnets](https://github.com/fabiomfrade/infra-cluster/blob/main/modules/subnet_infra/main.tf): `modules/subnet_infra/main.tf`
- [NAT, gateways, routes](https://github.com/fabiomfrade/infra-cluster/blob/main/modules/subnet_infra/main.tf): `modules/subnet_infra/main.tf`

### Kubernetes Cluster

- [EKS cluster](https://github.com/fabiomfrade/infra-cluster/blob/main/modules/eks/main.tf): `modules/eks/main.tf`
- [Managed node group](https://github.com/fabiomfrade/infra-cluster/blob/main/modules/nodegroup/main.tf): `modules/nodegroup/main.tf`

### Identity and Security

- [Cluster and node IAM roles](https://github.com/fabiomfrade/infra-cluster/blob/main/modules/iam/main.tf): `modules/iam/main.tf`
- [Cluster and node rules](https://github.com/fabiomfrade/infra-cluster/blob/main/modules/securitygroups/main.tf): `modules/securitygroups/main.tf`

### Other components

- **Infrastructure operator**
- **AWS infrastructure**

## Connections

- Infrastructure operator → Terraform configuration: applies (evidence: `README.md`)
- Terraform configuration → VPC and subnets: configures (evidence: `README.md`)
- Terraform configuration → EKS cluster: configures (evidence: `README.md`)
- Terraform configuration → Managed node group: configures (evidence: `README.md`)
- Terraform configuration → Cluster and node IAM roles: configures (evidence: `README.md`)
- Terraform configuration → Cluster and node rules: configures (evidence: `README.md`)
- VPC and subnets → NAT, gateways, routes: creates (evidence: `README.md`)
- Managed node group → EKS cluster: creates within (evidence: `README.md`)
- Cluster and node IAM roles → EKS cluster: provides roles (evidence: `README.md`)
- Cluster and node IAM roles → Managed node group: provides roles (evidence: `README.md`)
- Cluster and node rules → EKS cluster: configures rules (evidence: `README.md`)
- Cluster and node rules → Managed node group: configures rules (evidence: `README.md`)
- EKS cluster → AWS infrastructure: provisions (evidence: `README.md`)
- Managed node group → AWS infrastructure: provisions (evidence: `README.md`)
- Cluster and node IAM roles → AWS infrastructure: creates roles (evidence: `README.md`)
- VPC and subnets → AWS infrastructure: creates network (evidence: `README.md`)
