# tf-cilium/terraform-eks-cilium architecture

> Architecture diagram of the GitHub repository tf-cilium/terraform-eks-cilium, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-01-20). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/tf-cilium/terraform-eks-cilium
- Repository: https://github.com/tf-cilium/terraform-eks-cilium

## Overview

##### Project Type Analysis
This is an Infrastructure as Code (IaC) project using Terraform to deploy an Amazon EKS cluster with Cilium networking. The project is focused on infrastructure provisioning and network configuration.

##### Main Components

A. AWS Cloud (Outer Boundary):
- VPC (from terraform-aws-modules/vpc/aws)
- Multiple Availability Zones (us-east-1a, us-east-1b)

B. Networking Layer:
- VPC CIDR (10.0.0.0/16)
- Service CIDR (10.11.0.0/16)
- Availability Zones

C. EKS Cluster:
- EKS Control Plane
- Worker Nodes
- Kubernetes API Server

D. Cilium Components:
- Cilium CNI
- Optional Components:
- Hubble (if enabled)
- Hubble UI (if enabled)
- Gateway API (if enabled)
- eBPF Host Routing (if enabled)

##### Specific details
- Terraform version (> 1.4)
- EKS version (1.29)
- Cilium version (1.15.4)
- CIDR ranges
- Module sources and versions

##### Optional Features Representation
- Kube-proxy replacement
- eBPF host routing
- Hubble monitoring
- Hubble UI
- Gateway API

Remember to include the kubeconfig output command reference for cluster access, as it's a crucial operational detail mentioned in the outputs.

## Diagram (Mermaid)

```mermaid
graph TB
    subgraph AWS["AWS Cloud Environment"]
        subgraph VPC["VPC (10.0.0.0/16)"]
            subgraph AZ1["AZ: us-east-1a"]
                WN1[Worker Nodes]
            end
            subgraph AZ2["AZ: us-east-1b"]
                WN2[Worker Nodes]
            end
            
            subgraph EKSCluster["EKS Cluster (v1.29)"]
                CP[Control Plane]
                API[Kubernetes API Server]
            end

            subgraph CiliumLayer["Cilium Network Layer (v1.15.4)"]
                CNI[Cilium CNI]
                subgraph OptionalFeatures["Optional Components"]
                    HUB[Hubble]
                    HUI[Hubble UI]
                    GWA[Gateway API]
                    EBP[eBPF Host Routing]
                end
            end
        end
    end

    subgraph TF["Terraform Configuration"]
        MAIN["Main Configuration"]:::file
        VAR["Variables"]:::file
        OUT["Outputs"]:::file
        VER["Versions"]:::file
        LOCK["Dependency Lock"]:::file
        READ["Documentation"]:::file
        PRE["Pre-commit Config"]:::file
        REN["Renovate Config"]:::file
    end

    %% Relationships
    CP --> API
    API --> WN1
    API --> WN2
    CNI --> WN1
    CNI --> WN2
    CNI --> CP
    
    MAIN --> AWS
    VAR --> MAIN
    VER --> MAIN
    
    %% Click Events
    click MAIN "https://github.com/tf-cilium/terraform-eks-cilium/blob/main/main.tf"
    click VAR "https://github.com/tf-cilium/terraform-eks-cilium/blob/main/variables.tf"
    click OUT "https://github.com/tf-cilium/terraform-eks-cilium/blob/main/outputs.tf"
    click VER "https://github.com/tf-cilium/terraform-eks-cilium/blob/main/versions.tf"
    click LOCK "https://github.com/tf-cilium/terraform-eks-cilium/blob/main/.terraform.lock.hcl"
    click READ "https://github.com/tf-cilium/terraform-eks-cilium/blob/main/README.md"
    click PRE "https://github.com/tf-cilium/terraform-eks-cilium/blob/main/.pre-commit-config.yaml"
    click REN "https://github.com/tf-cilium/terraform-eks-cilium/blob/main/renovate.json"

    %% Styles
    classDef file fill:#f9f,stroke:#333,stroke-width:2px
    classDef aws fill:#FF9900,stroke:#232F3E,stroke-width:2px
    classDef network fill:#1EC08E,stroke:#333,stroke-width:2px
    
    %% Legend
    subgraph Legend
        L1[Terraform Files]:::file
        L2[AWS Resources]:::aws
        L3[Network Components]:::network
    end
```
