183 lines
10 KiB
XML
183 lines
10 KiB
XML
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 900 700" font-family="Arial, sans-serif">
|
|
<defs>
|
|
<linearGradient id="k8sGrad" x1="0%" y1="0%" x2="0%" y2="100%">
|
|
<stop offset="0%" style="stop-color:#326ce5;stop-opacity:1" />
|
|
<stop offset="100%" style="stop-color:#1d4ed8;stop-opacity:1" />
|
|
</linearGradient>
|
|
<linearGradient id="ingressGrad" x1="0%" y1="0%" x2="0%" y2="100%">
|
|
<stop offset="0%" style="stop-color:#6366f1;stop-opacity:1" />
|
|
<stop offset="100%" style="stop-color:#4f46e5;stop-opacity:1" />
|
|
</linearGradient>
|
|
<linearGradient id="deployGrad" x1="0%" y1="0%" x2="0%" y2="100%">
|
|
<stop offset="0%" style="stop-color:#10b981;stop-opacity:1" />
|
|
<stop offset="100%" style="stop-color:#059669;stop-opacity:1" />
|
|
</linearGradient>
|
|
<linearGradient id="podGrad" x1="0%" y1="0%" x2="0%" y2="100%">
|
|
<stop offset="0%" style="stop-color:#34d399;stop-opacity:1" />
|
|
<stop offset="100%" style="stop-color:#10b981;stop-opacity:1" />
|
|
</linearGradient>
|
|
<linearGradient id="statefulGrad" x1="0%" y1="0%" x2="0%" y2="100%">
|
|
<stop offset="0%" style="stop-color:#f59e0b;stop-opacity:1" />
|
|
<stop offset="100%" style="stop-color:#d97706;stop-opacity:1" />
|
|
</linearGradient>
|
|
<linearGradient id="externalGrad" x1="0%" y1="0%" x2="0%" y2="100%">
|
|
<stop offset="0%" style="stop-color:#94a3b8;stop-opacity:1" />
|
|
<stop offset="100%" style="stop-color:#64748b;stop-opacity:1" />
|
|
</linearGradient>
|
|
<filter id="shadowK" x="-20%" y="-20%" width="140%" height="140%">
|
|
<feDropShadow dx="2" dy="2" stdDeviation="3" flood-opacity="0.3"/>
|
|
</filter>
|
|
</defs>
|
|
|
|
<!-- Title -->
|
|
<text x="450" y="28" text-anchor="middle" font-size="20" font-weight="bold" fill="#333">
|
|
CaStAD Kubernetes Architecture
|
|
</text>
|
|
|
|
<!-- Main K8s Cluster Box -->
|
|
<rect x="30" y="45" width="840" height="590" rx="15" fill="url(#k8sGrad)" filter="url(#shadowK)" opacity="0.1"/>
|
|
<rect x="30" y="45" width="840" height="590" rx="15" fill="none" stroke="url(#k8sGrad)" stroke-width="3"/>
|
|
|
|
<!-- K8s Logo and Label -->
|
|
<text x="450" y="75" text-anchor="middle" font-size="16" font-weight="bold" fill="#326ce5">Kubernetes Cluster</text>
|
|
|
|
<!-- Ingress Controller -->
|
|
<rect x="250" y="95" width="400" height="55" rx="10" fill="url(#ingressGrad)" filter="url(#shadowK)"/>
|
|
<text x="450" y="120" text-anchor="middle" font-size="13" font-weight="bold" fill="white">Ingress Controller</text>
|
|
<text x="450" y="138" text-anchor="middle" font-size="10" fill="rgba(255,255,255,0.9)">nginx-ingress / Traefik</text>
|
|
|
|
<!-- Arrow from Ingress -->
|
|
<path d="M 450 150 L 450 175" stroke="#666" stroke-width="2"/>
|
|
|
|
<!-- Deployments Section -->
|
|
<rect x="50" y="175" width="800" height="280" rx="10" fill="rgba(16,185,129,0.1)" stroke="#10b981" stroke-width="1" stroke-dasharray="5,5"/>
|
|
<text x="450" y="195" text-anchor="middle" font-size="12" font-weight="bold" fill="#059669">Deployments (Auto-Scaling with HPA)</text>
|
|
|
|
<!-- API Deployment -->
|
|
<rect x="70" y="210" width="250" height="110" rx="8" fill="url(#deployGrad)" filter="url(#shadowK)"/>
|
|
<text x="195" y="232" text-anchor="middle" font-size="12" font-weight="bold" fill="white">API Deployment</text>
|
|
<text x="195" y="248" text-anchor="middle" font-size="10" fill="rgba(255,255,255,0.9)">HPA: 2-10 pods</text>
|
|
|
|
<!-- API Pods -->
|
|
<g transform="translate(85, 260)">
|
|
<rect x="0" y="0" width="40" height="45" rx="5" fill="url(#podGrad)"/>
|
|
<text x="20" y="28" text-anchor="middle" font-size="9" fill="white">Pod</text>
|
|
</g>
|
|
<g transform="translate(130, 260)">
|
|
<rect x="0" y="0" width="40" height="45" rx="5" fill="url(#podGrad)"/>
|
|
<text x="20" y="28" text-anchor="middle" font-size="9" fill="white">Pod</text>
|
|
</g>
|
|
<g transform="translate(175, 260)">
|
|
<rect x="0" y="0" width="40" height="45" rx="5" fill="url(#podGrad)"/>
|
|
<text x="20" y="28" text-anchor="middle" font-size="9" fill="white">Pod</text>
|
|
</g>
|
|
<g transform="translate(220, 260)">
|
|
<rect x="0" y="0" width="40" height="45" rx="5" fill="#d1d5db"/>
|
|
<text x="20" y="28" text-anchor="middle" font-size="9" fill="#666">...</text>
|
|
</g>
|
|
|
|
<!-- Render Worker Deployment -->
|
|
<rect x="340" y="210" width="250" height="110" rx="8" fill="url(#deployGrad)" filter="url(#shadowK)"/>
|
|
<text x="465" y="232" text-anchor="middle" font-size="12" font-weight="bold" fill="white">Render Worker</text>
|
|
<text x="465" y="248" text-anchor="middle" font-size="10" fill="rgba(255,255,255,0.9)">HPA: 3-20 pods (GPU nodes)</text>
|
|
|
|
<!-- Render Pods -->
|
|
<g transform="translate(355, 260)">
|
|
<rect x="0" y="0" width="40" height="45" rx="5" fill="url(#podGrad)"/>
|
|
<text x="20" y="28" text-anchor="middle" font-size="9" fill="white">Pod</text>
|
|
</g>
|
|
<g transform="translate(400, 260)">
|
|
<rect x="0" y="0" width="40" height="45" rx="5" fill="url(#podGrad)"/>
|
|
<text x="20" y="28" text-anchor="middle" font-size="9" fill="white">Pod</text>
|
|
</g>
|
|
<g transform="translate(445, 260)">
|
|
<rect x="0" y="0" width="40" height="45" rx="5" fill="url(#podGrad)"/>
|
|
<text x="20" y="28" text-anchor="middle" font-size="9" fill="white">Pod</text>
|
|
</g>
|
|
<g transform="translate(490, 260)">
|
|
<rect x="0" y="0" width="40" height="45" rx="5" fill="#d1d5db"/>
|
|
<text x="20" y="28" text-anchor="middle" font-size="9" fill="#666">...</text>
|
|
</g>
|
|
|
|
<!-- Upload Worker Deployment -->
|
|
<rect x="610" y="210" width="220" height="110" rx="8" fill="url(#deployGrad)" filter="url(#shadowK)"/>
|
|
<text x="720" y="232" text-anchor="middle" font-size="12" font-weight="bold" fill="white">Upload Worker</text>
|
|
<text x="720" y="248" text-anchor="middle" font-size="10" fill="rgba(255,255,255,0.9)">HPA: 2-5 pods</text>
|
|
|
|
<!-- Upload Pods -->
|
|
<g transform="translate(640, 260)">
|
|
<rect x="0" y="0" width="40" height="45" rx="5" fill="url(#podGrad)"/>
|
|
<text x="20" y="28" text-anchor="middle" font-size="9" fill="white">Pod</text>
|
|
</g>
|
|
<g transform="translate(685, 260)">
|
|
<rect x="0" y="0" width="40" height="45" rx="5" fill="url(#podGrad)"/>
|
|
<text x="20" y="28" text-anchor="middle" font-size="9" fill="white">Pod</text>
|
|
</g>
|
|
<g transform="translate(730, 260)">
|
|
<rect x="0" y="0" width="40" height="45" rx="5" fill="#d1d5db"/>
|
|
<text x="20" y="28" text-anchor="middle" font-size="9" fill="#666">...</text>
|
|
</g>
|
|
|
|
<!-- Scheduler Deployment -->
|
|
<rect x="70" y="335" width="250" height="70" rx="8" fill="url(#deployGrad)" filter="url(#shadowK)"/>
|
|
<text x="195" y="362" text-anchor="middle" font-size="12" font-weight="bold" fill="white">Scheduler (CronJob)</text>
|
|
<text x="195" y="382" text-anchor="middle" font-size="10" fill="rgba(255,255,255,0.9)">Weekly Auto-Generation</text>
|
|
|
|
<!-- Monitoring Deployment -->
|
|
<rect x="340" y="335" width="250" height="70" rx="8" fill="url(#deployGrad)" filter="url(#shadowK)"/>
|
|
<text x="465" y="362" text-anchor="middle" font-size="12" font-weight="bold" fill="white">Monitoring Stack</text>
|
|
<text x="465" y="382" text-anchor="middle" font-size="10" fill="rgba(255,255,255,0.9)">Prometheus + Grafana</text>
|
|
|
|
<!-- StatefulSets Section -->
|
|
<rect x="50" y="460" width="800" height="95" rx="10" fill="rgba(245,158,11,0.1)" stroke="#f59e0b" stroke-width="1" stroke-dasharray="5,5"/>
|
|
<text x="450" y="480" text-anchor="middle" font-size="12" font-weight="bold" fill="#d97706">StatefulSets (Persistent Data)</text>
|
|
|
|
<!-- PostgreSQL StatefulSet -->
|
|
<rect x="100" y="495" width="300" height="50" rx="8" fill="url(#statefulGrad)" filter="url(#shadowK)"/>
|
|
<text x="250" y="520" text-anchor="middle" font-size="12" font-weight="bold" fill="white">PostgreSQL (Primary + Replicas)</text>
|
|
<text x="250" y="538" text-anchor="middle" font-size="10" fill="rgba(255,255,255,0.9)">PersistentVolumeClaim</text>
|
|
|
|
<!-- Redis StatefulSet -->
|
|
<rect x="500" y="495" width="300" height="50" rx="8" fill="url(#statefulGrad)" filter="url(#shadowK)"/>
|
|
<text x="650" y="520" text-anchor="middle" font-size="12" font-weight="bold" fill="white">Redis Cluster (3-node)</text>
|
|
<text x="650" y="538" text-anchor="middle" font-size="10" fill="rgba(255,255,255,0.9)">PersistentVolumeClaim</text>
|
|
|
|
<!-- External Services Section -->
|
|
<rect x="50" y="565" width="800" height="60" rx="10" fill="rgba(148,163,184,0.1)" stroke="#94a3b8" stroke-width="1" stroke-dasharray="5,5"/>
|
|
<text x="450" y="585" text-anchor="middle" font-size="12" font-weight="bold" fill="#64748b">External Services</text>
|
|
|
|
<!-- External Service Icons -->
|
|
<rect x="90" y="595" width="100" height="25" rx="5" fill="url(#externalGrad)"/>
|
|
<text x="140" y="612" text-anchor="middle" font-size="10" fill="white">AWS S3</text>
|
|
|
|
<rect x="220" y="595" width="100" height="25" rx="5" fill="url(#externalGrad)"/>
|
|
<text x="270" y="612" text-anchor="middle" font-size="10" fill="white">Gemini API</text>
|
|
|
|
<rect x="350" y="595" width="100" height="25" rx="5" fill="url(#externalGrad)"/>
|
|
<text x="400" y="612" text-anchor="middle" font-size="10" fill="white">Suno API</text>
|
|
|
|
<rect x="480" y="595" width="100" height="25" rx="5" fill="url(#externalGrad)"/>
|
|
<text x="530" y="612" text-anchor="middle" font-size="10" fill="white">YouTube API</text>
|
|
|
|
<rect x="610" y="595" width="100" height="25" rx="5" fill="url(#externalGrad)"/>
|
|
<text x="660" y="612" text-anchor="middle" font-size="10" fill="white">Instagram</text>
|
|
|
|
<rect x="740" y="595" width="100" height="25" rx="5" fill="url(#externalGrad)"/>
|
|
<text x="790" y="612" text-anchor="middle" font-size="10" fill="white">TikTok</text>
|
|
|
|
<!-- Legend -->
|
|
<rect x="30" y="650" width="840" height="40" rx="5" fill="#f8f9fa" stroke="#e9ecef"/>
|
|
<rect x="60" y="663" width="30" height="15" rx="3" fill="url(#ingressGrad)"/>
|
|
<text x="100" y="675" font-size="10" fill="#666">Ingress</text>
|
|
<rect x="170" y="663" width="30" height="15" rx="3" fill="url(#deployGrad)"/>
|
|
<text x="210" y="675" font-size="10" fill="#666">Deployment</text>
|
|
<rect x="300" y="663" width="30" height="15" rx="3" fill="url(#podGrad)"/>
|
|
<text x="340" y="675" font-size="10" fill="#666">Pod</text>
|
|
<rect x="400" y="663" width="30" height="15" rx="3" fill="url(#statefulGrad)"/>
|
|
<text x="440" y="675" font-size="10" fill="#666">StatefulSet</text>
|
|
<rect x="530" y="663" width="30" height="15" rx="3" fill="url(#externalGrad)"/>
|
|
<text x="570" y="675" font-size="10" fill="#666">External</text>
|
|
|
|
<!-- HPA indicator -->
|
|
<text x="700" y="675" font-size="10" fill="#666">HPA = Horizontal Pod Autoscaler</text>
|
|
</svg> |