CK.IV · CKAD practice question

A container image has default user UID 0. If you set securityContext.runAsNonRoot: true on the container without setting runAsUser to a non-zero UID, what happens?

Choose one answer
Check answer and explanation

Correct answer: Kubelet rejects starting the container because the resolved user ID is 0

Explanation

runAsNonRoot: true requires the effective UID to be non-zero; if the image defaults to UID 0 and no non-zero runAsUser is set, kubelet refuses to start the container.

Common trap

runAsNonRoot: true requires the effective UID to be non-zero; if the image defaults to UID 0 and no non-zero runAsUser is set, kubelet refuses to start the container.

Source: Original unofficial practice; not an official CKAD exam item
Checked against the cited text on 2026-11-30.

Report an error in this question