concept

Startup readiness and liveness

Choose Kubernetes startup, readiness and liveness probes, understand their different failure actions, and diagnose application health with offline examples.

Formal Syntax & Structure

kubernetes syntaxkubernetes
Startup readiness and liveness

Working Example

Example Snippetkubernetes
apiVersion: v1kind: Podmetadata:  name: catalog-health  namespace: book-labspec:  containers:    - name: catalog      image: registry.invalid/bytemind/catalog:demo      ports:        - name: http          containerPort: 8080      resources:        requests:          cpu: 250m          memory: 128Mi        limits:          cpu: 500m          memory: 256Mi      startupProbe:        httpGet:          path: /started          port: http        periodSeconds: 5        failureThreshold: 12        timeoutSeconds: 2      readinessProbe:        httpGet:          path: /ready          port: http        periodSeconds: 5        failureThreshold: 2        timeoutSeconds: 2      livenessProbe:        httpGet:          path: /live          port: http        periodSeconds: 10        failureThreshold: 3        timeoutSeconds: 2
Kubernetes Reference