# deenanath486/child-parent-modules architecture

> Architecture diagram of the GitHub repository deenanath486/child-parent-modules, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-30). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/deenanath486/child-parent-modules
- Repository: https://github.com/deenanath486/child-parent-modules

## Overview

This Terraform landing zone configures dev, preprod, and prod Azure environments. An operator selects an environment’s tfvars file and runs Terraform from the parent module; the parent passes map-based inputs to reusable child modules for resource groups, networking, compute, security, and access services. The README documents these module roles and the for_each pattern, but no Terraform source excerpts were supplied, so internal resource-level dependencies are not shown.

Main entry points: [`azure-landing-zone/parent-module`](https://github.com/deenanath486/child-parent-modules/tree/main/azure-landing-zone/parent-module) (Parent module), [`azure-landing-zone/environments/dev/dev.tfvars`](https://github.com/deenanath486/child-parent-modules/blob/main/azure-landing-zone/environments/dev/dev.tfvars) (Dev variables), [`azure-landing-zone/environments/preprod/preprod.tfvars`](https://github.com/deenanath486/child-parent-modules/blob/main/azure-landing-zone/environments/preprod/preprod.tfvars) (PreProd variables), [`azure-landing-zone/environments/prod/prod.tfvars`](https://github.com/deenanath486/child-parent-modules/blob/main/azure-landing-zone/environments/prod/prod.tfvars) (Prod variables)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_configuration["Environment configuration"]
  node_dev["Dev variables<br/>[dev.tfvars]"]
  node_preprod["PreProd variables<br/>[preprod.tfvars]"]
  node_prod["Prod variables<br/>[prod.tfvars]"]
end

subgraph group_orchestration["Terraform orchestration"]
  node_parent["Parent module"]
end

subgraph group_networking["Network modules"]
  node_vnet_subnet["VNet and subnets"]
  node_nsg["Network security groups"]
  node_route_tables["Route tables"]
  node_public_ip["Public IP"]
end

subgraph group_platform["Platform modules"]
  node_resource_groups["Resource groups"]
  node_nic_vm["NICs and VMs"]
  node_key_vault["Key Vault"]
  node_bastion["Bastion"]
end

node_operator(("Terraform operator"))
node_azure[("Azure resources")]

node_operator -->|"runs plan/apply"| node_parent
node_operator -->|"selects variables"| node_dev
node_operator -->|"selects variables"| node_preprod
node_operator -->|"selects variables"| node_prod
node_dev -->|"provides inputs"| node_parent
node_preprod -->|"provides inputs"| node_parent
node_prod -->|"provides inputs"| node_parent
node_parent -->|"calls module"| node_resource_groups
node_parent -->|"calls module"| node_vnet_subnet
node_parent -->|"calls module"| node_nsg
node_parent -->|"calls module"| node_route_tables
node_parent -->|"calls module"| node_public_ip
node_parent -->|"calls module"| node_nic_vm
node_parent -->|"calls module"| node_key_vault
node_parent -->|"calls module"| node_bastion
node_parent -->|"applies configuration"| node_azure

click node_dev "https://github.com/deenanath486/child-parent-modules/blob/main/azure-landing-zone/environments/dev/dev.tfvars"
click node_preprod "https://github.com/deenanath486/child-parent-modules/blob/main/azure-landing-zone/environments/preprod/preprod.tfvars"
click node_prod "https://github.com/deenanath486/child-parent-modules/blob/main/azure-landing-zone/environments/prod/prod.tfvars"
click node_parent "https://github.com/deenanath486/child-parent-modules/tree/main/azure-landing-zone/parent-module"
click node_resource_groups "https://github.com/deenanath486/child-parent-modules/tree/main/azure-landing-zone/child-modules"
click node_vnet_subnet "https://github.com/deenanath486/child-parent-modules/tree/main/azure-landing-zone/child-modules"
click node_nsg "https://github.com/deenanath486/child-parent-modules/tree/main/azure-landing-zone/child-modules"
click node_route_tables "https://github.com/deenanath486/child-parent-modules/tree/main/azure-landing-zone/child-modules"
click node_public_ip "https://github.com/deenanath486/child-parent-modules/tree/main/azure-landing-zone/child-modules"
click node_nic_vm "https://github.com/deenanath486/child-parent-modules/tree/main/azure-landing-zone/child-modules"
click node_key_vault "https://github.com/deenanath486/child-parent-modules/tree/main/azure-landing-zone/child-modules"
click node_bastion "https://github.com/deenanath486/child-parent-modules/tree/main/azure-landing-zone/child-modules"

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_dev,node_preprod,node_prod toneBlue
class node_parent,node_azure toneAmber
class node_vnet_subnet,node_nsg,node_route_tables,node_public_ip toneMint
class node_resource_groups,node_nic_vm,node_key_vault,node_bastion toneRose
class node_operator toneIndigo
```

## Components

### Environment configuration

- [Dev variables](https://github.com/deenanath486/child-parent-modules/blob/main/azure-landing-zone/environments/dev/dev.tfvars): `azure-landing-zone/environments/dev/dev.tfvars`
- [PreProd variables](https://github.com/deenanath486/child-parent-modules/blob/main/azure-landing-zone/environments/preprod/preprod.tfvars): `azure-landing-zone/environments/preprod/preprod.tfvars`
- [Prod variables](https://github.com/deenanath486/child-parent-modules/blob/main/azure-landing-zone/environments/prod/prod.tfvars): `azure-landing-zone/environments/prod/prod.tfvars`

### Terraform orchestration

- [Parent module](https://github.com/deenanath486/child-parent-modules/tree/main/azure-landing-zone/parent-module): `azure-landing-zone/parent-module`

### Network modules

- [VNet and subnets](https://github.com/deenanath486/child-parent-modules/tree/main/azure-landing-zone/child-modules): `azure-landing-zone/child-modules`
- [Network security groups](https://github.com/deenanath486/child-parent-modules/tree/main/azure-landing-zone/child-modules): `azure-landing-zone/child-modules`
- [Route tables](https://github.com/deenanath486/child-parent-modules/tree/main/azure-landing-zone/child-modules): `azure-landing-zone/child-modules`
- [Public IP](https://github.com/deenanath486/child-parent-modules/tree/main/azure-landing-zone/child-modules): `azure-landing-zone/child-modules`

### Platform modules

- [Resource groups](https://github.com/deenanath486/child-parent-modules/tree/main/azure-landing-zone/child-modules): `azure-landing-zone/child-modules`
- [NICs and VMs](https://github.com/deenanath486/child-parent-modules/tree/main/azure-landing-zone/child-modules): `azure-landing-zone/child-modules`
- [Key Vault](https://github.com/deenanath486/child-parent-modules/tree/main/azure-landing-zone/child-modules): `azure-landing-zone/child-modules`
- [Bastion](https://github.com/deenanath486/child-parent-modules/tree/main/azure-landing-zone/child-modules): `azure-landing-zone/child-modules`

### Other components

- **Terraform operator**
- **Azure resources**

## Connections

- Terraform operator → Parent module: runs plan/apply (evidence: `README.md`)
- Terraform operator → Dev variables: selects variables (evidence: `README.md`)
- Terraform operator → PreProd variables: selects variables (evidence: `README.md`)
- Terraform operator → Prod variables: selects variables (evidence: `README.md`)
- Dev variables → Parent module: provides inputs (evidence: `README.md`)
- PreProd variables → Parent module: provides inputs (evidence: `README.md`)
- Prod variables → Parent module: provides inputs (evidence: `README.md`)
- Parent module → Resource groups: calls module (evidence: `README.md`)
- Parent module → VNet and subnets: calls module (evidence: `README.md`)
- Parent module → Network security groups: calls module (evidence: `README.md`)
- Parent module → Route tables: calls module (evidence: `README.md`)
- Parent module → Public IP: calls module (evidence: `README.md`)
- Parent module → NICs and VMs: calls module (evidence: `README.md`)
- Parent module → Key Vault: calls module (evidence: `README.md`)
- Parent module → Bastion: calls module (evidence: `README.md`)
- Parent module → Azure resources: applies configuration (evidence: `README.md`)
