<p>I'm struggling to understand the difference between Deployments and Pods in Kubernetes.</p>
<blockquote>
<p>A Deployment provides declarative updates for Pods and ReplicaSets.</p>
</blockquote>
<blockquote>
<p>Pods are the smallest deployable units of computing that you can create and manage in Kubernetes.</p>
</blockquote>
<p>It seems like <code>kind:Pod</code> can be used interchangeably <code>kind: Deployment</code> and deployments allow for <strong>Replica</strong> (which is pretty much the point of Kubernetes). Why would you ever use a Pod?</p>
<p>Can someone:</p>
<ul>
<li>Explain the <em>essential difference</em> between Pods/Deployments +</li>
<li>Describe a use case where pods are preferable over deployments?</li>
</ul>

<p>In short:</p>
<p>With Pods</p>
<ol>
<li>if it dies it dies. Period.</li>
<li>you can define only one copy of particular pod. If you need to have X copies you have to define in YAML file(s) X pods</li>
<li>usually you will never see pods created directly in production environments. Too unreliable. Why ? because of 1.</li>
</ol>
<p>With Deployment</p>
<ol>
<li>you define desired state of a pod. If pod dies (for whatever reason) then deployment creates new pod.</li>
<li>and more generic: you can define that you want to have X running replicas of the same pod. If one or more of them die(s) the Deployment creates new to match X</li>
</ol>
