« Phase 13 · Warmup · Track Overview
Hitchhiker's Guide — The Cloud & Infrastructure Backbone
The fast orientation. What the pieces are, what they are called, and how they fit — before the deep dive takes them apart.
Table of Contents
- 1. Don't panic: the one-paragraph version
- 2. The map
- 3. The vocabulary
- 4. The four gateways, disambiguated
- 5. GPU facts, memorized
- 6. The private-endpoint checklist
- 7. The five things that will surprise you
- 8. Reading a Terraform plan
- 9. Where the neighbouring phases connect
- 10. What to build first
1. Don't panic: the one-paragraph version
Everything here is one idea — reconciliation: read the desired state, observe reality, close the difference. Terraform runs that loop when a human asks; Kubernetes runs it continuously. On top sit three things specific to an AI platform: GPU node pools, which break every autoscaling assumption because a node takes nine minutes to serve and tensor parallelism needs all its GPUs at once; private networking, where the hard part is DNS and where a private endpoint does not close the public path; and policy-as-code at two layers, deny-by-default, failing closed. And the property that ties them together: an infrastructure claim — "no traffic leaves the region" — is only worth anything if you can prove it by searching the topology, not by reading a diagram.
2. The map
git ──► CI (OIDC, no stored creds) ──► sign + SBOM ──► registry
│
┌────────────────────────────────────────────────────────┴────────────┐
│ TERRAFORM graph ──► plan ──► apply ──► state ◄── drift check │
└────────────────────────────────┬────────────────────────────────────┘
▼
┌─────────────────────────────────────────────────────────────────────┐
│ AKS │
│ admission (Gatekeeper/Kyverno) ← signed? pinned? limits? │
│ ┌────────────┐ ┌────────────┐ ┌──────────────────┐ │
│ │ CPU pool │ │ GPU pool │ │ GPU pool (MIG) │ │
│ │ agents, │ │ tainted, │ │ 7x10GB slices │ │
│ │ gateways │ │ gang-sched │ │ small models │ │
│ └────────────┘ └────────────┘ └──────────────────┘ │
│ mesh: mTLS, ext_authz, consistent-hash LB │
└────────────────────────────┬────────────────────────────────────────┘
│ private endpoints only
┌────────────────────────────▼────────────────────────────────────────┐
│ Azure OpenAI · Key Vault · Storage · Search (public access OFF) │
└─────────────────────────────────────────────────────────────────────┘
▲ egress: no default route; a firewall with an FQDN allow-list
3. The vocabulary
| Term | Means |
|---|---|
| Reconciliation | desired vs actual, close the gap. The one idea |
| Resource graph | the DAG Terraform actually operates on |
| State | what Terraform believes exists — a third thing beside config and reality |
| Plan | a diff against state, not against reality |
ForceNew | an attribute whose change means destroy and recreate |
| Drift | state and reality disagree |
| Unmanaged | exists, and nothing owns it — the dangerous drift category |
| Taint / toleration | keeps non-GPU pods off GPU nodes |
| Gang scheduling | all-or-nothing placement; without it, deadlock |
| MIG | hardware partitioning of one GPU into isolated instances |
| Warm pool | idle nodes kept ready, because cold start is nine minutes |
| Private endpoint | a NIC in your subnet mapped to a PaaS service |
| Private DNS zone | the half that breaks; needs a VNet link |
| Peering | VNet-to-VNet; directional, and not transitive |
| UDR | user-defined route; how traffic is forced through a firewall |
| NSG | subnet/NIC firewall; first-match-by-priority |
| Service tag | a named IP set (Storage, AzureCloud) used in NSG rules |
| Workload identity federation | a k8s service-account token exchanged for an Entra token |
ext_authz | the mesh filter that calls an external PEP |
failure_mode_allow | the ext_authz setting that decides fail-open or fail-shut |
| Admission controller | validates/mutates a Kubernetes object before it is stored |
| Cosign / Notation | container image signing |
| SLSA | build-provenance framework |
4. The four gateways, disambiguated
Everything in this space is called a gateway. They are at different layers:
| Thing | Layer | Does |
|---|---|---|
| APIM / Front Door | north-south | TLS, WAF, rate limit, subscription keys, developer portal |
| Ingress / mesh gateway | cluster edge | routes external traffic into the mesh |
| Envoy sidecar | east-west | mTLS, retries, timeouts, ext_authz |
| LLM gateway | application | model routing, fallback, token accounting, semantic cache |
The last one is the one people misplace. It is an application (Phase 04), not network infrastructure, because everything it does requires understanding the content of the request — you cannot count tokens without a tokenizer or cache semantically without an embedding.
5. GPU facts, memorized
| Fact | Number | Consequence |
|---|---|---|
| Node start | 5–8 min | reactive autoscaling does not work |
| Engine warm-up | 1–3 min | ditto |
| Node to serving | ~9 min | warm pool |
| Normal node | 30–60 s | the contrast that makes the point |
| Cost | $3–40/GPU/hr | idle GPUs are the biggest line item |
MIG 1g.10gb | 7 per GPU | many small models |
MIG 7g.80gb | 1 per GPU | i.e. no partitioning |
| Tensor-parallel gang | all-or-nothing | Volcano / Kueue |
| Image size | 5–20 GB | which is most of the node start |
And the two rules that follow: taint every GPU pool, so nothing else lands there by accident; and place the largest gangs first, because fragmentation defeats a sufficient total.
6. The private-endpoint checklist
Six things, and missing any one leaves a claim false while everything works:
- The private endpoint exists, in a subnet the workload can route to.
-
A private DNS zone exists (
privatelink.<service>.<suffix>). - The zone has an A record for the service, pointing at the private IP.
- The zone is linked to every VNet that needs to resolve it. ← most-missed
-
public_network_access_enabled = falseon the service. ← second-most-missed - The NSG permits the traffic.
The fourth and fifth are the ones that produce a working system with a false residency claim, and neither is visible in an architecture diagram.
7. The five things that will surprise you
1. A private endpoint does not disable public access. Two settings, two resources. The endpoint adds a route; it removes nothing.
2. terraform plan does not diff against reality. It diffs against state. An empty plan and a
wrong estate are entirely compatible, which is why drift detection is a separate scheduled job.
3. Intra-VNet routing is implicit. So "is the private endpoint in my subnet?" is the wrong question — it only has to be somewhere in the VNet. A check that asks the narrow question produces false negatives and gets ignored.
4. NSGs are first-match-by-priority. Unlike the policy engine in Phase 09, where deny always beats allow. Here an allow at priority 100 beats a deny at 200, and the rule set means whatever the numbers say.
5. Mesh retries will double-execute your payments. The mesh does not know which calls are idempotent. Turn retries off for anything side-effecting (Phase 10).
8. Reading a Terraform plan
The two lines that matter in a fifty-resource plan:
# azurerm_kubernetes_cluster.aks must be replaced
-/+ resource "azurerm_kubernetes_cluster" "aks" {
~ location = "uaenorth" -> "uaecentral" # forces replacement ← STOP
...
}
# azurerm_storage_account.docs will be updated in-place
~ resource "azurerm_storage_account" "docs" {
~ public_network_access_enabled = false -> true ← STOP
}
# forces replacement means destroy and recreate. For a cluster that is an outage; for a
storage account it is data loss. The symbol is -/+, and the guard is prevent_destroy:
lifecycle {
prevent_destroy = true
}
The second one is not marked as dangerous by Terraform at all — it is an ordinary in-place update that reopens a service to the internet. Which is exactly why the admission gate in the lab exists: the plan cannot tell you that a change is a compliance problem, and a policy check can.
Two other plan-reading habits worth having: run terraform plan -refresh-only periodically to see
drift, and read the resource count at the top — a plan that touches forty resources when you
changed one line means a variable moved and you should stop.
9. Where the neighbouring phases connect
| Phase | Gives this phase | Takes from this phase |
|---|---|---|
| 01 — Kernel | session affinity as a requirement | consistent-hash LB in the mesh |
| 04 — LLM gateway | — | where it sits, and private endpoints to models |
| 05 — Serving | the capacity model | GPU pools, MIG, warm pools |
| 08 — Identity | no long-lived secrets | managed identity, workload identity federation |
| 09 — Control plane | the PDP | ext_authz, admission control |
| 10 — Action gateway | idempotency semantics | why mesh retries must be off |
| 11 — Guardrails | egress allow-listing | the firewall, and the proof |
| 12 — Integration | connectivity to the estate | private endpoints, peering |
| 14 — SRE | — | rollback triggered by burn rate |
| 15 — Governance | residency requirements | the reachability proof as evidence |
10. What to build first
- The landing zone and the VNet topology. Everything else assumes it, and changing a VNet's address space later is a migration.
- No default route, plus private endpoints. Start at the strictest posture and relax deliberately. "We'll lock down egress later" becomes never, because by then forty things depend on it.
- The DNS zones and their VNet links. At the same time as the endpoints, or you will ship the working-but-public configuration and not know.
- Workload identity federation, and OIDC in CI. Before any secret is stored, because removing a stored credential means rotating it everywhere it leaked to.
- Admission policies, before the first workload. Retrofitting
requests/limitsacross a running fleet is a rolling restart of everything. - The GPU pool with taints, before the first GPU workload.
- Drift detection, scheduled, once there is anything to drift from.
- The reachability check, before the first residency claim is made to anyone outside the team.