Skip to content

Instantly share code, notes, and snippets.

@coryodaniel
Last active August 9, 2017 17:42
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save coryodaniel/ea677c686393304ac95aa5b19e54876a to your computer and use it in GitHub Desktop.
Save coryodaniel/ea677c686393304ac95aa5b19e54876a to your computer and use it in GitHub Desktop.
Kube Terminology Cheatsheet
  • Nodes - Server, laptop, EC2 Instance, droplet. Whatever can host a docker container. They run your pods.
  • Pods - Group of 1 or more docker containers that should be run together. E.g.: an ‘app’ pod may be composed of a NGiNX server, rails app, and a memcached instance.
    • stateless
    • base unit of containerized workloads
    • shared networking space / IP / Port space
    • communicate via localhost
    • share volumes
    • should rarely be created manually
    • kinda feels like a docker-compose file
  • Services - By default, pods are not exposed outside of your cluster. Services expose pods to the public internet.
    • Can span multiple nodes
  • Controllers - Controllers control the lifecycle of pods. Novel name huh?
    • ReplicaSets - ensures that a specified number of pod "replicas" are running at any given time
      • stateless
      • A template for pod creation with minimum and maximum number of pods to run
      • Configure autoscaling of pods based on resource usage
      • Previous were called 'ReplicationController'
      • Generally shouldn't be created by hand, should be managed via a deployment.
      • Updating a ReplicaSet is not atomic, if you close your laptop or lose network connectivity replicas can have a mix of states
      • imperative rollouts
    • Deployments - manage rollouts of changes to replicasets
      • stateless
      • declarative rollouts
      • Creates ReplicaSets to perform rolling updates of changes
      • Deployments are atomic if you close your laptop or lose network connectivity the deployment either gets POSTed successfully to Kubernetes API server (in which case it works server side, or it doesn't) in which case all your replicas are still on the old version.
      • Canary Deployments
    • StatefulSets - provides a unique identity to pods; for stateful applications
      • stateful, obvi
      • Useful when matching one of these requirements:
        • Stable, unique network identifiers.
        • Stable, persistent storage.
        • Ordered, graceful deployment and scaling.
        • Ordered, graceful deletion and termination.
    • Jobs - pod that runs to completion
    • DaemonSets - ensure all (or some) nodes are running a particular pod
      • good for logging services and things that need to be run as a daemon on multiple nodes
    • Namespaces - named scopes for a team or a project
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment