Choose a learning path

Kubernetes Production Engineering

Deployment → configuration → troubleshooting → operational verification.

Start Kubernetes guide

Platform & DevOps

Containers, CI/CD, Terraform, governance and operational practices.

See platform material

Software & AI Engineering

System design, JavaScript, AI agents and foundational concepts.

Browse topic maps

Topic maps are outlines, not published full-length lessons. Review examples and commands against your environment before using them in production.

Kubernetes: Deploy, Configure, Troubleshoot

1. Deploy an application to Kubernetes

Developer → CI build and tests → container image → Amazon ECR → Kubernetes Deployment → Service → Ingress / Load Balancer → Users.

  1. Build and test the application; create a container image.
  2. Push the versioned image to a registry such as Amazon ECR.
  3. Define a Deployment with image, replica count, resource requests and limits, and probes.
  4. Apply manifests with kubectl apply -f k8s/.
  5. Verify rollout, pods, Service endpoints, and external routing.
  6. Use rolling updates and kubectl rollout undo deployment/my-app when needed.

Note: A Service is internal by default. External access requires appropriate networking and an Ingress controller or load balancer.

2. Production troubleshooting

Start with kubectl get pods -A and kubectl describe pod <pod> -n <namespace>; inspect events before changing resources.

  • Pending: scheduling constraints, CPU/memory requests, taints, PVCs, quotas.
  • CrashLoopBackOff: previous logs, startup command, configuration, dependencies and probes.
  • ImagePullBackOff: image name/tag, registry permissions, pull secrets and network access.
  • Running but unavailable: readiness, Service selectors, EndpointSlices, ports, Ingress and DNS.
  • High resource use: metrics, limits, HPA behavior, application profiling.
  • Node or network issues: node conditions, CNI, NetworkPolicy and DNS.

After remediation: fix → verify → monitor.

3. Kubernetes YAML anatomy

Common resource fields are apiVersion, kind, metadata, and spec. A Deployment's pod template is under spec.template.

apiVersion: apps/v1
kind: Deployment
metadata:
  name: my-app
spec:
  replicas: 3
  selector:
    matchLabels:
      app: my-app
  template:
    metadata:
      labels:
        app: my-app
    spec:
      containers:
        - name: web
          image: nginx:1.27
          ports:
            - containerPort: 80
          resources:
            requests:
              cpu: 250m
              memory: 256Mi
            limits:
              memory: 512Mi

Use namespace-scoped configuration, appropriate RBAC, Secrets for sensitive values, and Kustomize or Helm for environment-specific packaging. Never commit real secret values.

4. Example EKS repository layout

k8s-project/
├── .github/workflows/ci-cd.yml
├── app/
│   ├── src/
│   └── Dockerfile
├── k8s/
│   ├── namespace/
│   ├── deployment/
│   ├── service/
│   ├── ingress/
│   ├── config/
│   └── hpa/
├── terraform/
│   ├── modules/
│   │   ├── eks/
│   │   └── vpc/
│   ├── main.tf
│   ├── variables.tf
│   └── outputs.tf
└── README.md

Separate application build, infrastructure provisioning, and Kubernetes deployment into independently reviewed CI/CD stages. Do not automatically run destructive Terraform applies or cluster mutations from untrusted pull requests.

Curated resources

External Engineering References

Explore interactive learning resources, including Protocol Explorer for network packet visualization.

Browse engineering references

Core engineering topic maps

AWS Cloud

EC2, S3, RDS, Lambda, VPC, IAM, CloudFront, Elastic Beanstalk, CloudWatch, Route 53, API Gateway, ECS, and EKS.

Study the responsibility model, networking, identity, compute choices, storage, observability and costs before combining services into architectures.

System Design

Requirements and trade-offs; modularity, scalability, reliability, latency, availability, databases, caching, load balancing, microservices, APIs, security, monitoring, fault tolerance, recovery, partitioning, messaging, distributed systems, design patterns, CI/CD, containers and cloud cost optimization.

Docker & DevOps

Containers, Dockerfiles, Engine, images, image layers, volumes, networks, registries, multi-stage builds, Compose, security, CI/CD and deployment strategies.

Build minimal images, pin dependencies, scan artifacts and avoid embedding credentials.

JavaScript

Variables, types, operators, control flow, functions, arrays, objects, DOM, events, asynchronous JavaScript, promises, modules, Fetch API, storage, classes, debugging, JSON and modern language features.

AI Engineering

AI and ML fundamentals, deep learning, NLP, computer vision, neural networks, generative AI, prompt design, cloud AI, agentic systems, AI ethics, explainability, edge AI and conversational AI.

Connect concepts to evaluation, data quality, security and operational controls.