Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Set Sail with Kubernetes

Set Sail with Kubernetes

Intro to Kubernetes deck presented to the Alamo Tech Collective in San Antonio, June 2025

Avatar for Hart Hoover

Hart Hoover

June 14, 2025
Tweet

More Decks by Hart Hoover

Other Decks in Technology

Transcript

  1. $kubectl auth whoami Hart Hoover I work at Cisco, by

    way of Isovalent, makers of Cilium and Tetragon Formerly CoreOS, Heptio/VMware, Rackspace, Kong #GirlDad who loves tacos and coffee, perhaps too much https://harthoover.com
  2. Agenda • WTF is Kubernetes? • Pods • More Pods

    • Config Data • Gateways • I want to run it • Services
  3. History Lesson dotCloud joins YCombinator 2010 dotCloud ➡ Docker, Inc

    in 2013 EC2 just started supporting custom kernels Linux 3.0 was not out yet Terraform did not exist Go 1.0 had not been released “Config Management” was mostly Bash OpsCode wasn’t Chef, Inc. Netflix Engineering was blogging about building AMIs
  4. History Lesson Google open-sourced Kubernetes on June 6, 2014 Docker

    Swarm was released Oct 2014 CNCF was founded in 2015, Kubernetes was its first project
  5. WTF is Kubernetes? Kubernetes is a Greek word that means

    “helmsman” or “pilot” Kubernetes is an open source container orchestration engine for automating deployment, scaling, and management of containerized applications.
  6. WTF does Kubernetes Do? Abstracts underlying hardware of nodes and

    provides a uniform interface for container (and now VM!) workloads to be both deployed and consume the shared pool of resources.
  7. WTF does Kubernetes Do? Kubernetes… Autoscales workloads Manages Deployments Runs

    Stateful and Stateless Apps Has built-in Service Discovery Supports third party applications
  8. WTF does Kubernetes Look Like? etcd (Data Store) API Server

    Scheduler Controller Manager You (kubectl) Node1 Network Plugin Kubelet Container Runtime OS Node2 Network Plugin Kubelet Container Runtime OS NodeN Network Plugin Kubelet Container Runtime OS Controllers Nodes Kube-Proxy Kube-Proxy Kube-Proxy
  9. WTF does Kubernetes Look Like? etcd (Data Store) API Server

    Scheduler Controller Manager Controllers
  10. WTF does Kubernetes Look Like? Node1 Network Plugin Kubelet Container

    Runtime OS Node2 Network Plugin Kubelet Container Runtime OS NodeN Network Plugin Kubelet Container Runtime OS Nodes Kube-Proxy Kube-Proxy Kube-Proxy
  11. WTF does Kubernetes Look Like? Node1 Kubelet Node2 Kubelet NodeN

    Kubelet Nodes Kube-Proxy Kube-Proxy Kube-Proxy
  12. WTF does Kubernetes Look Like? etcd (Data Store) API Server

    Scheduler Controller Manager You (kubectl) Node1 Network Plugin Kubelet Container Runtime OS Node2 Network Plugin Kubelet Container Runtime OS NodeN Network Plugin Kubelet Container Runtime OS Controllers Nodes Kube-Proxy Kube-Proxy Kube-Proxy
  13. Pods apiVersion: v1 kind: Pod metadata: name: nginx spec: containers:

    - name: nginx image: nginx:1.14.2 ports: - containerPort: 80
  14. Pod Templates apiVersion: batch/v1 kind: Job metadata: name: hello spec:

    template: # This is the pod template spec: containers: - name: hello image: busybox:1.28 command: ['sh', '-c', 'echo "Hello, Kubernetes!" && sleep 3600'] restartPolicy: OnFailure # The pod template ends here
  15. Deployments and ReplicaSets apiVersion: apps/v1 kind: Deployment metadata: name: nginx-deployment

    labels: app: nginx spec: replicas: 3 selector: matchLabels: app: nginx template: metadata: labels: app: nginx spec: containers: - name: nginx image: nginx:1.14.2 ports: - containerPort: 80
  16. Deployments and ReplicaSets apiVersion: apps/v1 kind: Deployment metadata: name: nginx-deployment

    labels: app: nginx spec: replicas: 3 selector: matchLabels: app: nginx template: metadata: labels: app: nginx spec: containers: - name: nginx image: nginx:1.14.2 ports: - containerPort: 80
  17. Deployments and ReplicaSets apiVersion: apps/v1 kind: Deployment metadata: name: nginx-deployment

    labels: app: nginx spec: replicas: 3 selector: matchLabels: app: nginx template: metadata: labels: app: nginx spec: containers: - name: nginx image: nginx:1.14.2 ports: - containerPort: 80
  18. Deployments and ReplicaSets apiVersion: apps/v1 kind: Deployment metadata: name: nginx-deployment

    labels: app: nginx spec: replicas: 3 selector: matchLabels: app: nginx template: metadata: labels: app: nginx spec: containers: - name: nginx image: nginx:1.14.2 ports: - containerPort: 80
  19. DaemonSets apiVersion: apps/v1 kind: DaemonSet metadata: name: fluentd spec: selector:

    matchLabels: name: fluentd template: metadata: labels: name: fluentd spec: containers: - name: fluentd-elasticsearch image: quay.io/fluentd_elasticsearch/fluentd:latest
  20. DaemonSets apiVersion: apps/v1 kind: DaemonSet metadata: name: fluentd spec: selector:

    matchLabels: name: fluentd template: metadata: labels: name: fluentd spec: containers: - name: fluentd-elasticsearch image: quay.io/fluentd_elasticsearch/fluentd:latest
  21. DaemonSets apiVersion: apps/v1 kind: DaemonSet metadata: name: fluentd spec: selector:

    matchLabels: name: fluentd template: metadata: labels: name: fluentd spec: containers: - name: fluentd-elasticsearch image: quay.io/fluentd_elasticsearch/fluentd:latest
  22. ConfigMaps and Secrets apiVersion: v1 kind: ConfigMap metadata: name: game-demo

    data: player_initial_lives: "3" ui_properties_file_name: "user-interface.properties"
  23. Using a ConfigMap apiVersion: v1 kind: Pod metadata: name: configmap-demo-pod

    spec: containers: - name: demo image: alpine command: ["sleep", "3600"] env: - name: PLAYER_INITIAL_LIVES valueFrom: configMapKeyRef: name: game-demo key: player_initial_lives - name: UI_PROPERTIES_FILE_NAME valueFrom: configMapKeyRef: name: game-demo key: ui_properties_file_name
  24. Pods apiVersion: v1 kind: Pod metadata: name: nginx spec: containers:

    - name: nginx image: nginx:1.14.2 ports: - containerPort: 80
  25. Services apiVersion: v1 kind: Service metadata: name: my-service spec: selector:

    app.kubernetes.io/name: nginx ports: - protocol: TCP port: 80 targetPort: 80
  26. Services apiVersion: v1 kind: Service metadata: name: my-service spec: selector:

    app.kubernetes.io/name: nginx ports: - protocol: TCP port: 80 targetPort: 80
  27. Services apiVersion: v1 kind: Service metadata: name: my-service spec: selector:

    app.kubernetes.io/name: nginx ports: - protocol: TCP port: 80 targetPort: 80
  28. Services apiVersion: v1 kind: Service metadata: name: my-service spec: selector:

    app.kubernetes.io/name: nginx ports: - protocol: TCP port: 80 targetPort: 80
  29. Blue/Green Deployments labels: app: myapp env: blue labels: app: myapp

    env: green selector: app: myapp env: blue v1 v2
  30. Blue/Green Deployments labels: app: myapp env: blue labels: app: myapp

    env: green selector: app: myapp env: green v1 v2
  31. Blue/Green Deployments labels: app: myapp env: blue labels: app: myapp

    env: green selector: app: myapp env: green v3 v2
  32. apiVersion: gateway.networking.k8s.io/v1 kind: Gateway metadata: name: prod-web spec: gatewayClassName: cilium

    listeners: - protocol: HTTP port: 80 name: prod-web-gw allowedRoutes: namespaces: from: Same Simple Gateway API Objects apiVersion: gateway.networking.k8s.io/v1 kind: HTTPRoute metadata: name: route spec: parentRefs: - name: prod-web rules: - backendRefs: - name: foo-svc port: 8080