<p>I have a pod which keeps restarting because of failed liveliness probes:</p>
<pre><code>Events:
   ... Container ... failed liveness probe, will be restarted
</code></pre>
<p>I suspect the the liveliness timeout of 1 sec is the issue here.</p>
<p>The liveliness probe is defined as follows:</p>
<pre><code>livenessProbe:
  httpGet:
    path: /health
    port: 80
    scheme: HTTP
</code></pre>
<p>Is there a way to simulate the HTTP request with <code>kubectl</code> to take a few samples on the response time?</p>
<p><code>exec</code>ing into the container and running <code>curl</code> is not an option, because the container is distroless.</p>
<p>Felix</p>

<p>You can port-forward to the container with kubectl and then try to query the health api endpoint.</p>
<p>Also, slow down your <code>livenessProbe</code> while you check that with <code>initialDelaySeconds: 120</code>  (in the <code>livenessProbe</code> object, outside the <code>httpGet</code>)</p>
<p>Like so:</p>
<pre class="lang-yaml prettyprint-override"><code>livenessProbe:
  initialDelaySeconds: 120
  httpGet:
    path: /health
    port: 80
    scheme: HTTP
</code></pre>
