Init containers run to completion, in order, before a Pod's app containers start
Answer: Init containers are specialized containers that run before app containers in a Pod. Add them under the initContainers field of the Pod specification. Each one must complete successfully before the next one starts.
Rules
- Init containers always run to completion.
- The next init container starts only after each one completes successfully.
- When an init container fails, the kubelet repeatedly restarts that init container until it succeeds. With a
restartPolicyof Never, Kubernetes treats the overall Pod as failed. - Regular init containers do not support the
lifecycle,livenessProbe,readinessProbe, orstartupProbefields. - The status of the init containers is returned in the
.status.initContainerStatusesfield.
Init containers support resource limits, volumes and security settings, but their resource requests and limits are handled differently from app containers.
Typical use
Init containers can contain utilities or setup scripts not present in an app image. In the docs example, the init container and the application container share a Volume in the Pod. The init container mounts it at /work-dir, writes index.html with wget, and then terminates. The nginx app container mounts the same Volume at /usr/share/nginx/html and serves the file.
Init versus sidecar
A sidecar container starts before the main application container and continues to run. An init container runs to completion during Pod initialization.
See also
Claims
- id: C1 claim: Init containers run before app containers in a Pod. source: S1 evidence: "specialized containers that run before app containers in a Pod"
- id: C2 claim: Each init container must succeed before the next starts. source: S1 evidence: "Each init container must complete successfully before the next one starts."
- id: C3 claim: Regular init containers do not support probes or lifecycle. source: S1 evidence: "do not support the lifecycle , livenessProbe , readinessProbe , or startupProbe fields"
- id: C4 claim: In the example, the init container runs to completion before the app container starts. source: S2 evidence: "The init container runs to completion before the application container starts."
Sources
- [S1] Init Containers. Kubernetes docs. https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ . License: CC-BY-4.0. Accessed 2026-11-18.
- [S2] Configure Pod Initialization (source page). kubernetes/website (GitHub). https://github.com/kubernetes/website/blob/main/content/en/docs/tasks/configure-pod-container/configure-pod-initialization.md . License: CC-BY-4.0. Accessed 2026-11-18.
License: this note is CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Summary by iinventedlight (AI-assisted). Sources: Kubernetes docs, Init Containers; kubernetes/website (GitHub), Configure Pod Initialization (source page). CC-BY-4.0 (https://raw.githubusercontent.com/kubernetes/website/main/LICENSE). Copyright The Kubernetes Authors. Text was condensed and changed from the originals.
License: CC-BY-4.0 · Summary by iinventedlight (AI-assisted). Sources: Kubernetes docs, Init Containers; kubernetes/website (GitHub), Configure Pod Initialization (source page). CC-BY-4.0 (https://raw.githubusercontent.com/kubernetes/website/main/LICENSE). Copyright The Kubernetes Authors.
Cite this
iinventedlight. 2026. "Init containers run to completion, in order, before a Pod's app containers start." iinventedlight Library, iil:note:wmsxb3c8, version of 2026-11-18. https://iinventedlight.com/library/notes/kubernetes-init-containers/. License: CC-BY-4.0.
@misc{iil_note_wmsxb3c8,
author = {{iinventedlight}},
title = {{Init containers run to completion, in order, before a Pod's app containers start}},
howpublished = {iinventedlight Library},
year = {2026},
date = {2026-11-18},
url = {https://iinventedlight.com/library/notes/kubernetes-init-containers/},
note = {Permanent ID iil:note:wmsxb3c8. License: CC-BY-4.0.},
}
Spotted a mistake? Use the MCP feedback tool or email hello@iinventedlight.com. Or Report a correction (no account needed).
For language models and agents: start at /llms.txt | /agents.md | /.well-known/agent-library.json. This page in Markdown: /library/notes/kubernetes-init-containers.md.