# prithvirajmagar/mastering-kubernetes architecture

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

- Interactive diagram: https://gitdiagram.com/prithvirajmagar/mastering-kubernetes
- Repository: https://github.com/prithvirajmagar/mastering-kubernetes

## Overview

##### Project Type Analysis
This is an educational project focused on Kubernetes, structured as a progressive learning path covering various Kubernetes concepts and implementations.

##### Main Components

a) Core Infrastructure Layer:
- KOPS/EKS/Kubeadm Cluster Setup
- Node Management
- Network Policies

b) Workload Management Layer:
- Pods and ReplicaSets
- Deployments
- Services
- Jobs and CronJobs

c) Security & Access Control:
- RBAC
- Secrets Management
- ConfigMaps
- TLS/SSL

d) Storage & Persistence:
- Persistent Volumes
- PV Claims
- Storage Classes
- Dynamic Provisioning

e) Observability Stack:
- Prometheus & Grafana
- EFK Stack (Elasticsearch, Fluentd, Kibana)
- Metrics Server

f) Service Mesh Layer:
- Istio Components
- Ingress Gateway
- Virtual Services

##### Use a layered approach with clear separation
- Infrastructure Layer (Bottom)
- Platform Services (Middle)
- Application Services (Top)

##### Component Relationships

**Master Components:**
- API Server
- Controller Manager
- Scheduler
- etcd

**Worker Components:**
- kubelet
- kube-proxy
- Container Runtime

Create distinct sections for:

## Diagram (Mermaid)

```mermaid
graph TB
    subgraph Legend
        L1[Infrastructure]:::infrastructure
        L2[Security]:::security
        L3[Networking]:::networking
        L4[Storage]:::storage
        L5[Monitoring]:::monitoring
        L6[Application]:::application
    end

    subgraph "Core Infrastructure"
        K8sArch["Kubernetes Architecture"]:::infrastructure
        KOPS["KOPS Setup"]:::infrastructure
        Kubeadm["Kubeadm Setup"]:::infrastructure
        NetPol["Network Policies"]:::networking
    end

    subgraph "Workload Management"
        Pods["Pods & ReplicaSets"]:::application
        Deploy["Deployments"]:::application
        Services["Services"]:::application
        Jobs["Jobs & CronJobs"]:::application
    end

    subgraph "Security & Access Control"
        RBAC["RBAC"]:::security
        Secrets["Secrets & ConfigMaps"]:::security
        TLS["TLS & Ingress"]:::security
    end

    subgraph "Storage & Persistence"
        Storage["Storage Components"]:::storage
        StorageClass["Storage Class"]:::storage
        PV["Persistent Volumes"]:::storage
        PVC["PV Claims"]:::storage
    end

    subgraph "Observability Stack"
        Prometheus["Prometheus & Grafana"]:::monitoring
        EFK["EFK Stack"]:::monitoring
        Elastic["Elasticsearch"]:::monitoring
        Fluentd["Fluentd"]:::monitoring
        Kibana["Kibana"]:::monitoring
        Metrics["Metrics Server"]:::monitoring
    end

    subgraph "Service Mesh"
        Istio["Istio Components"]:::networking
        IngressGW["Ingress Gateway"]:::networking
        Kiali["Kiali & Jaeger"]:::monitoring
    end

    subgraph "Advanced Features"
        AdvSched["Advanced Scheduling"]:::infrastructure
        CICD["CI/CD Integration"]:::application
        AutoScale["Auto-scaling (HPA/VPA)"]:::infrastructure
    end

    %% Relationships
    K8sArch --> KOPS & Kubeadm
    KOPS & Kubeadm --> NetPol
    NetPol --> Pods
    Pods --> Deploy
    Deploy --> Services
    Services --> Jobs
    RBAC --> Secrets
    Secrets --> TLS
    Storage --> StorageClass
    StorageClass --> PV
    PV --> PVC
    Prometheus --> EFK
    EFK --> Elastic & Fluentd & Kibana
    Metrics --> AutoScale
    Istio --> IngressGW
    IngressGW --> Kiali
    AdvSched --> CICD
    CICD --> AutoScale

    %% Click Events
    click K8sArch "https://github.com/prithvirajmagar/Mastering-Kubernetes/tree/Master/Day 00 Kubernetes Intro-Architecture/"
    click KOPS "https://github.com/prithvirajmagar/Mastering-Kubernetes/tree/Master/Day 01 KOPS-Deployment/"
    click Kubeadm "https://github.com/prithvirajmagar/Mastering-Kubernetes/tree/Master/Day 17 kubeadm-kubernetes-cluster/"
    click NetPol "https://github.com/prithvirajmagar/Mastering-Kubernetes/tree/Master/Day 11 NetworkPolicies/"
    click Pods "https://github.com/prithvirajmagar/Mastering-Kubernetes/tree/Master/Day 02 PODs-ReplicaSets/"
    click Deploy "https://github.com/prithvirajmagar/Mastering-Kubernetes/tree/Master/Day 03 Deployments/"
    click Services "https://github.com/prithvirajmagar/Mastering-Kubernetes/tree/Master/Day 04 Services/"
    click Jobs "https://github.com/prithvirajmagar/Mastering-Kubernetes/tree/Master/Day 07 Sidecar-ResourceQuotas-Jobs-CronJobs/"
    click RBAC "https://github.com/prithvirajmagar/Mastering-Kubernetes/tree/Master/Day 08 RBAC-Kubeconfig_Merge/"
    click Secrets "https://github.com/prithvirajmagar/Mastering-Kubernetes/tree/Master/Day 09 Secrets-ESO-ConfigMaps/"
    click TLS "https://github.com/prithvirajmagar/Mastering-Kubernetes/tree/Master/Day 05 IngressController-TLS-RegistrySecret-Probes/"
    click Storage "https://github.com/prithvirajmagar/Mastering-Kubernetes/tree/Master/Day 10 Storage-PV-PVC-DynamicProvisioning/"
    click StorageClass "https://github.com/prithvirajmagar/Mastering-Kubernetes/blob/Master/Day 10 Storage-PV-PVC-DynamicProvisioning/7storageclass.yml"
    click PV "https://github.com/prithvirajmagar/Mastering-Kubernetes/blob/Master/Day 10 Storage-PV-PVC-DynamicProvisioning/4PV.yml"
    click PVC "https://github.com/prithvirajmagar/Mastering-Kubernetes/blob/Master/Day 10 Storage-PV-PVC-DynamicProvisioning/5pvc.yml"
    click Prometheus "https://github.com/prithvirajmagar/Mastering-Kubernetes/tree/Master/Day 14 Prometheus-Grafana-EFK/"
    click Elastic "https://github.com/prithvirajmagar/Mastering-Kubernetes/blob/Master/Day 14 Prometheus-Grafana-EFK/elasticsearch.yml"
    click Fluentd "https://github.com/prithvirajmagar/Mastering-Kubernetes/blob/Master/Day 14 Prometheus-Grafana-EFK/fluentd.yml"
    click Kibana "https://github.com/prithvirajmagar/Mastering-Kubernetes/blob/Master/Day 14 Prometheus-Grafana-EFK/kibana.yml"
    click Metrics "https://github.com/prithvirajmagar/Mastering-Kubernetes/tree/Master/Day 16 MetricsServer_VPA_HPA_Karpenter/"
    click Istio "https://github.com/prithvirajmagar/Mastering-Kubernetes/tree/Master/Day 13 Istio-ServiceMesh/"
    click IngressGW "https://github.com/prithvirajmagar/Mastering-Kubernetes/blob/Master/Day 13 Istio-ServiceMesh/1-istio-ingressgateway.yml"
    click Kiali "https://github.com/prithvirajmagar/Mastering-Kubernetes/blob/Master/Day 13 Istio-ServiceMesh/kiali-jaeger.yml"
    click AdvSched "https://github.com/prithvirajmagar/Mastering-Kubernetes/tree/Master/Day 12 AdvanceScheduling/"
    click CICD "https://github.com/prithvirajmagar/Mastering-Kubernetes/tree/Master/Day 15 AWS_EKS_Jenkins_Integration/"
    click AutoScale "https://github.com/prithvirajmagar/Mastering-Kubernetes/tree/Master/Day 16 MetricsServer_VPA_HPA_Karpenter/"

    %% Styles
    classDef infrastructure fill:#E5E5E5,stroke:#333,stroke-width:2px
    classDef security fill:#FFD6D6,stroke:#333,stroke-width:2px
    classDef networking fill:#D6E5FF,stroke:#333,stroke-width:2px
    classDef storage fill:#D6FFD6,stroke:#333,stroke-width:2px
    classDef monitoring fill:#F2D6FF,stroke:#333,stroke-width:2px
    classDef application fill:#FFE5D6,stroke:#333,stroke-width:2px
```
