James's Ramblings

Kubernetes: Deployments

Created: April 08, 2021

Basics

  • A deployment controller creates a ReplicaSet, which in turn creates a Pod, automatically.

  • Deployments can be updated, which creates a new ReplicaSet and a new Pod.

  • Deployment specification determines how the new objects replace the old objects.

  • kubectl apply -f FILE.yaml can be used to apply most updates.

  • kubectl edit PATH/TO/FILE can be used to edit a deployed file/resource.

  • ReplicationControllers (RC) were an older type of object that had caused problems if a client loses connectivity. Deployments are intended to fix this problem.

  • Deployments have two spec declarations - one for the ReplicaSet and on for the Pod.