# sumitthakur10/-terraform-terraform-aws-alb architecture

> Architecture diagram of the GitHub repository sumitthakur10/-terraform-terraform-aws-alb, 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/sumitthakur10/-terraform-terraform-aws-alb
- Repository: https://github.com/sumitthakur10/-terraform-terraform-aws-alb

## Overview

This is a Terraform module for provisioning AWS Application and Network Load Balancers. The principal workflow is that a Terraform user supplies network, listener, and target-group configuration; the module creates the load balancer and supporting resources, and listeners can forward traffic to target groups. The README also documents redirects, authentication, security-group rules, and access logs. Source excerpts were unavailable, so internal resource wiring is shown only where the README demonstrates it; implementation paths identify the relevant Terraform files from the tree.

Main entry points: [`main.tf`](https://github.com/sumitthakur10/-terraform-terraform-aws-alb/blob/master/main.tf) (Listeners), [`variables.tf`](https://github.com/sumitthakur10/-terraform-terraform-aws-alb/blob/master/variables.tf) (Module inputs)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_module["Terraform module"]
  node_inputs["Module inputs<br/>[variables.tf]"]
  node_loadbalancer["ALB / NLB<br/>[main.tf]"]
  node_outputs["Module outputs<br/>[outputs.tf]"]
end

subgraph group_routing["Traffic routing"]
  node_listeners["Listeners<br/>[main.tf]"]
  node_rules["Listener rules<br/>[main.tf]"]
  node_targets["Target groups<br/>[main.tf]"]
  node_redirects["Redirect actions<br/>[main.tf]"]
  node_authentication["Listener authentication<br/>[main.tf]"]
end

subgraph group_support["Supporting resources"]
  node_security["Security groups<br/>[main.tf]"]
  node_accesslogs["Access logs<br/>[main.tf]"]
end

node_user(("Terraform user"))
node_aws["AWS"]
node_s3[("S3 log bucket")]
node_cognito["Amazon Cognito"]
node_oidc["OIDC provider"]

node_user -->|"configures"| node_inputs
node_inputs -->|"configures"| node_loadbalancer
node_loadbalancer -->|"creates"| node_aws
node_listeners -->|"forwards to"| node_targets
node_listeners -->|"defines"| node_rules
node_listeners -->|"can redirect"| node_redirects
node_listeners -->|"can authenticate"| node_authentication
node_authentication -->|"uses"| node_cognito
node_authentication -->|"supports"| node_oidc
node_security -->|"creates rules"| node_aws
node_accesslogs -->|"writes logs"| node_s3
node_loadbalancer -->|"configures"| node_accesslogs

click node_inputs "https://github.com/sumitthakur10/-terraform-terraform-aws-alb/blob/master/variables.tf"
click node_loadbalancer "https://github.com/sumitthakur10/-terraform-terraform-aws-alb/blob/master/main.tf"
click node_outputs "https://github.com/sumitthakur10/-terraform-terraform-aws-alb/blob/master/outputs.tf"
click node_listeners "https://github.com/sumitthakur10/-terraform-terraform-aws-alb/blob/master/main.tf"
click node_rules "https://github.com/sumitthakur10/-terraform-terraform-aws-alb/blob/master/main.tf"
click node_targets "https://github.com/sumitthakur10/-terraform-terraform-aws-alb/blob/master/main.tf"
click node_redirects "https://github.com/sumitthakur10/-terraform-terraform-aws-alb/blob/master/main.tf"
click node_authentication "https://github.com/sumitthakur10/-terraform-terraform-aws-alb/blob/master/main.tf"
click node_security "https://github.com/sumitthakur10/-terraform-terraform-aws-alb/blob/master/main.tf"
click node_accesslogs "https://github.com/sumitthakur10/-terraform-terraform-aws-alb/blob/master/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_inputs,node_loadbalancer,node_outputs,node_user toneBlue
class node_listeners,node_rules,node_targets,node_redirects,node_authentication,node_s3 toneAmber
class node_security,node_accesslogs toneMint
class node_aws,node_cognito,node_oidc toneIndigo
```

## Components

### Terraform module

- [Module inputs](https://github.com/sumitthakur10/-terraform-terraform-aws-alb/blob/master/variables.tf): `variables.tf`
- [ALB / NLB](https://github.com/sumitthakur10/-terraform-terraform-aws-alb/blob/master/main.tf): `main.tf`
- [Module outputs](https://github.com/sumitthakur10/-terraform-terraform-aws-alb/blob/master/outputs.tf): `outputs.tf`

### Traffic routing

- [Listeners](https://github.com/sumitthakur10/-terraform-terraform-aws-alb/blob/master/main.tf): `main.tf`
- [Listener rules](https://github.com/sumitthakur10/-terraform-terraform-aws-alb/blob/master/main.tf): `main.tf`
- [Target groups](https://github.com/sumitthakur10/-terraform-terraform-aws-alb/blob/master/main.tf): `main.tf`
- [Redirect actions](https://github.com/sumitthakur10/-terraform-terraform-aws-alb/blob/master/main.tf): `main.tf`
- [Listener authentication](https://github.com/sumitthakur10/-terraform-terraform-aws-alb/blob/master/main.tf): `main.tf`

### Supporting resources

- [Security groups](https://github.com/sumitthakur10/-terraform-terraform-aws-alb/blob/master/main.tf): `main.tf`
- [Access logs](https://github.com/sumitthakur10/-terraform-terraform-aws-alb/blob/master/main.tf): `main.tf`

### Other components

- **Terraform user**
- **AWS**
- **S3 log bucket**
- **Amazon Cognito**
- **OIDC provider**

## Connections

- Terraform user → Module inputs: configures (evidence: `README.md`)
- Module inputs → ALB / NLB: configures (evidence: `README.md`)
- ALB / NLB → AWS: creates (evidence: `README.md`)
- Listeners → Target groups: forwards to (evidence: `README.md`)
- Listeners → Listener rules: defines (evidence: `README.md`)
- Listeners → Redirect actions: can redirect (evidence: `README.md`)
- Listeners → Listener authentication: can authenticate (evidence: `README.md`)
- Listener authentication → Amazon Cognito: uses (evidence: `README.md`)
- Listener authentication → OIDC provider: supports (evidence: `README.md`)
- Security groups → AWS: creates rules (evidence: `README.md`)
- Access logs → S3 log bucket: writes logs (evidence: `README.md`)
- ALB / NLB → Access logs: configures (evidence: `README.md`)
