<p>We have an http livenessProbe setup</p>

<pre><code>  livenessProbe:
    httpGet:
      path: /admin
      port: http
    initialDelaySeconds: 180
    periodSeconds: 20
</code></pre>

<p>but why in the description the connection is via https</p>

<pre><code>Liveness probe failed: Get https://10.11.1.7:80/admin: net/http: request canceled while waiting for connection (Client.Timeout exceeded while awaiting headers)
</code></pre>

deemaxx
<p>Kubernetes is doing exactly what you are asking, probing the http url but your application pod web server is redirecting it to https, that is causing the error.</p>

<p>You can either fix that in pod or use <a href="https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/#define-a-tcp-liveness-probe" rel="nofollow noreferrer">TCP probe</a></p>

<pre><code>apiVersion: v1
kind: Pod
metadata:
  name: goproxy
  labels:
    app: goproxy
spec:
  containers:
  - name: goproxy
    image: k8s.gcr.io/goproxy:0.1
    ports:
    - containerPort: 8080
    readinessProbe:
      tcpSocket:
        port: 8080
      initialDelaySeconds: 5
      periodSeconds: 10
    livenessProbe:
      tcpSocket:
        port: 8080
      initialDelaySeconds: 15
      periodSeconds: 20
</code></pre>
