
Shared EKS App-Team Baseline
- Mark Kendall
- Dec 22, 2025
- 2 min read
owned).
š§ Shared EKS App-Team Baseline
Purpose
Define the minimum, compliant, repeatable deployment pattern for application teams deploying into a shared EKS cluster where:
Namespaces are platform-owned
Storage is platform-controlled
App teams only deploy namespaced resources
1ļøā£ Ownership & Responsibility Model
Platform / Cloud Team (NOT App Team)
Owns:
EKS cluster
Namespaces
RBAC
StorageClasses / EBS CSI
Ingress / API Gateway
Kafka / MSK
MongoDB (if shared)
Application Team (This Repo)
Owns:
Deployments / StatefulSets
Services
ConfigMaps / Secrets
Kustomize overlays
Runtime configuration (DNS, env vars)
š« App teams never create namespaces
2ļøā£ Required Repository Structure (Minimum)
k8s/
Ā base/
Ā Ā deployment.yaml
Ā Ā service.yaml
Ā Ā statefulset.yaml Ā # only if app-owned state
Ā Ā kustomization.yaml
Ā overlays/
Ā Ā shared/
Ā Ā Ā kustomization.yaml Ā # ā namespace set here
3ļøā£ Namespace Handling (MANDATORY RULE)
ā What app teams must NOT do
kind: Namespace
No namespace.yaml.
No metadata.namespace in resource files.
ā Correct Pattern (Kustomize Injection)
# k8s/overlays/shared/kustomization.yaml
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: zsp Ā # provided by Cloud team
resources:
Ā - ../../base
Kustomize injects the namespace at render time.
Kubernetes will NOT create it.
4ļøā£ Service DNS Convention (Critical)
All in-cluster communication must use Kubernetes DNS:
<service-name>.<namespace>.svc.cluster.local
Example (MongoDB)
mongodb-app.zsp.svc.cluster.local
š« Never hardcode old or assumed namespaces
š« Never use IPs
š« Never rely on default namespace
5ļøā£ Application Configuration Pattern (RECOMMENDED)
const mongoService = "mongodb-app";
const mongoNamespace = process.env.K8S_NAMESPACE || "zsp";
export const MONGO_URL =
Ā `mongodb://${mongoService}.${mongoNamespace}.svc.cluster.local:27017/TMF622v401`;
ā Namespace configurable
ā Code environment-agnostic
ā Safe across dev / test / prod
6ļøā£ Storage Rules (Stateful Workloads)
If your app uses:
MongoDB
PostgreSQL
Kafka
Any PVC
Then:
ā StatefulSet + PVC is allowed only if platform enables storage
ā Do not assume EBS / StorageClass exists
ā Do not create StorageClasses
ā Do not create PVs manually unless approved
If pods are Pending due to PVC:
ā” This is a Platform issue, not an App issue
7ļøā£ Pre-Deploy Checklist (App Team)
Before applying manifests:
kubectl get ns <namespace>
kubectl auth can-i create pods -n <namespace>
kubectl auth can-i create services -n <namespace>
kubectl auth can-i create pvc -n <namespace>
If any fail ā stop and escalate
8ļøā£ Safe Deploy Commands
Render first (always)
kubectl kustomize k8s/overlays/shared
Verify:
All resources show namespace: zsp
No Namespace object exists
Apply
kubectl apply -k k8s/overlays/shared
9ļøā£ Common Failure ā Correct Owner
Symptom
Owner
Pods Pending (PVC)
Platform
Namespace not found
Platform
RBAC forbidden
Platform
DNS not resolving
App (wrong namespace)
Service not found
App
CrashLoopBackOff
App
š One Rule to Remember
Platform creates namespaces.
App teams deploy into them.
Kustomize injects them.
DNS must match them.
š Optional: Add This to Every Repo README
This service is deployed into a shared EKS cluster.
Namespaces, storage, and ingress are platform-owned.
This repo uses Kustomize namespace injection and must not
create Kubernetes Namespace resources.
ā Result
Zero namespace conflicts
No RBAC fights
Predictable DNS
Easy audits
Repeatable across all TMF services

Comments