# destinym01/andujar-online-iac architecture

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

- Interactive diagram: https://gitdiagram.com/destinym01/andujar-online-iac
- Repository: https://github.com/destinym01/andujar-online-iac

## Overview

Andujar Online is a Django REST API delivered as a containerized service on Azure AKS. The main request path routes user API calls to user handlers, which validate/serialize and read or write SQLite-backed user records; health and admin endpoints are additional capabilities. The README documents the CI/CD, Kubernetes, and Terraform deployment branches. Runtime source supports the API wiring; deployment relationships are based on README descriptions because those files were not sampled.

Main entry points: [`k8s/deployment.yml`](https://github.com/destinym01/andujar-online-iac/blob/main/k8s/deployment.yml) (Django deployment), [`azure-pipelines.yml`](https://github.com/destinym01/andujar-online-iac/blob/main/azure-pipelines.yml) (CI/CD pipeline), [`demo/urls.py`](https://github.com/destinym01/andujar-online-iac/blob/main/demo/urls.py) (Project routes), [`api/views.py`](https://github.com/destinym01/andujar-online-iac/blob/main/api/views.py) (User handlers)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_api["API runtime"]
  node_urls["Project routes<br/>[urls.py]"]
  node_api_routes["User routes<br/>[urls.py]"]
  node_user_views["User handlers<br/>[views.py]"]
  node_health["Health check<br/>[views.py]"]
  node_serializer["User serializer<br/>[serializers.py]"]
  node_user_model["User model<br/>[models.py]"]
  node_sqlite[("SQLite database<br/>[settings.py]")]
  node_admin["Admin panel<br/>[admin.py]"]
end

subgraph group_kube["Kubernetes runtime"]
  node_ingress["Ingress<br/>[ingress.yml]"]
  node_service["Kubernetes service<br/>[service.yml]"]
  node_deployment["Django deployment<br/>[deployment.yml]"]
  node_configmap["Runtime config<br/>[configmap.yml]"]
  node_secret["Kubernetes secret<br/>[secret.yml]"]
  node_autoscaler["Pod autoscaler<br/>[hpa.yml]"]
end

subgraph group_delivery["Image delivery"]
  node_container["API container"]
  node_pipeline["CI/CD pipeline"]
  node_registry[("Azure registry")]
end

subgraph group_azure["Azure provisioning"]
  node_terraform["Terraform config<br/>[main.tf]"]
  node_azure["Azure resources"]
end

node_client(("API client"))

node_client -->|"HTTPS requests"| node_ingress
node_ingress -->|"forwards traffic"| node_service
node_service -->|"routes requests"| node_deployment
node_deployment -->|"serves Django"| node_urls
node_urls -->|"includes API routes"| node_api_routes
node_urls -->|"dispatches health"| node_health
node_api_routes -->|"dispatches users"| node_user_views
node_user_views -->|"serializes data"| node_serializer
node_user_views -->|"queries and saves"| node_user_model
node_serializer -->|"maps fields"| node_user_model
node_user_model -->|"persists records"| node_sqlite
node_client -.->|"admin access"| node_admin
node_configmap -.->|"provides settings"| node_deployment
node_secret -.->|"provides secret"| node_deployment
node_autoscaler -->|"scales replicas"| node_deployment
node_pipeline -->|"builds image"| node_container
node_pipeline -->|"pushes image"| node_registry
node_registry -.->|"supplies image"| node_deployment
node_pipeline -->|"deploys manifests"| node_deployment
node_terraform -->|"provisions resources"| node_azure
node_azure -->|"hosts registry"| node_registry
node_azure -->|"hosts AKS"| node_deployment

click node_urls "https://github.com/destinym01/andujar-online-iac/blob/main/demo/urls.py"
click node_api_routes "https://github.com/destinym01/andujar-online-iac/blob/main/api/urls.py"
click node_user_views "https://github.com/destinym01/andujar-online-iac/blob/main/api/views.py"
click node_health "https://github.com/destinym01/andujar-online-iac/blob/main/api/views.py"
click node_serializer "https://github.com/destinym01/andujar-online-iac/blob/main/api/serializers.py"
click node_user_model "https://github.com/destinym01/andujar-online-iac/blob/main/api/models.py"
click node_sqlite "https://github.com/destinym01/andujar-online-iac/blob/main/demo/settings.py"
click node_admin "https://github.com/destinym01/andujar-online-iac/blob/main/api/admin.py"
click node_ingress "https://github.com/destinym01/andujar-online-iac/blob/main/k8s/ingress.yml"
click node_service "https://github.com/destinym01/andujar-online-iac/blob/main/k8s/service.yml"
click node_deployment "https://github.com/destinym01/andujar-online-iac/blob/main/k8s/deployment.yml"
click node_configmap "https://github.com/destinym01/andujar-online-iac/blob/main/k8s/configmap.yml"
click node_secret "https://github.com/destinym01/andujar-online-iac/blob/main/k8s/secret.yml"
click node_autoscaler "https://github.com/destinym01/andujar-online-iac/blob/main/k8s/hpa.yml"
click node_container "https://github.com/destinym01/andujar-online-iac/blob/main/Dockerfile"
click node_pipeline "https://github.com/destinym01/andujar-online-iac/blob/main/azure-pipelines.yml"
click node_terraform "https://github.com/destinym01/andujar-online-iac/blob/main/terraform/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_urls,node_api_routes,node_user_views,node_health,node_serializer,node_user_model,node_sqlite,node_admin,node_client toneBlue
class node_ingress,node_service,node_deployment,node_configmap,node_secret,node_autoscaler toneAmber
class node_container,node_pipeline,node_registry toneMint
class node_terraform,node_azure toneRose
```

## Components

### API runtime

- [Project routes](https://github.com/destinym01/andujar-online-iac/blob/main/demo/urls.py): `demo/urls.py`
- [User routes](https://github.com/destinym01/andujar-online-iac/blob/main/api/urls.py): `api/urls.py`
- [User handlers](https://github.com/destinym01/andujar-online-iac/blob/main/api/views.py): `api/views.py`
- [Health check](https://github.com/destinym01/andujar-online-iac/blob/main/api/views.py): `api/views.py`
- [User serializer](https://github.com/destinym01/andujar-online-iac/blob/main/api/serializers.py): `api/serializers.py`
- [User model](https://github.com/destinym01/andujar-online-iac/blob/main/api/models.py): `api/models.py`
- [SQLite database](https://github.com/destinym01/andujar-online-iac/blob/main/demo/settings.py): `demo/settings.py`
- [Admin panel](https://github.com/destinym01/andujar-online-iac/blob/main/api/admin.py): `api/admin.py`

### Kubernetes runtime

- [Ingress](https://github.com/destinym01/andujar-online-iac/blob/main/k8s/ingress.yml): `k8s/ingress.yml`
- [Kubernetes service](https://github.com/destinym01/andujar-online-iac/blob/main/k8s/service.yml): `k8s/service.yml`
- [Django deployment](https://github.com/destinym01/andujar-online-iac/blob/main/k8s/deployment.yml): `k8s/deployment.yml`
- [Runtime config](https://github.com/destinym01/andujar-online-iac/blob/main/k8s/configmap.yml): `k8s/configmap.yml`
- [Kubernetes secret](https://github.com/destinym01/andujar-online-iac/blob/main/k8s/secret.yml): `k8s/secret.yml`
- [Pod autoscaler](https://github.com/destinym01/andujar-online-iac/blob/main/k8s/hpa.yml): `k8s/hpa.yml`

### Image delivery

- [API container](https://github.com/destinym01/andujar-online-iac/blob/main/Dockerfile): `Dockerfile`
- [CI/CD pipeline](https://github.com/destinym01/andujar-online-iac/blob/main/azure-pipelines.yml): `azure-pipelines.yml`
- **Azure registry**

### Azure provisioning

- [Terraform config](https://github.com/destinym01/andujar-online-iac/blob/main/terraform/main.tf): `terraform/main.tf`
- **Azure resources**

### Other components

- **API client**

## Connections

- API client → Ingress: HTTPS requests
- Ingress → Kubernetes service: forwards traffic
- Kubernetes service → Django deployment: routes requests
- Django deployment → Project routes: serves Django
- Project routes → User routes: includes API routes
- Project routes → Health check: dispatches health
- User routes → User handlers: dispatches users
- User handlers → User serializer: serializes data
- User handlers → User model: queries and saves
- User serializer → User model: maps fields
- User model → SQLite database: persists records
- API client → Admin panel: admin access
- Runtime config → Django deployment: provides settings
- Kubernetes secret → Django deployment: provides secret
- Pod autoscaler → Django deployment: scales replicas
- CI/CD pipeline → API container: builds image
- CI/CD pipeline → Azure registry: pushes image
- Azure registry → Django deployment: supplies image
- CI/CD pipeline → Django deployment: deploys manifests
- Terraform config → Azure resources: provisions resources
- Azure resources → Azure registry: hosts registry
- Azure resources → Django deployment: hosts AKS
