hardkubectl

Validate a manifest against the live API server without creating the resource

command

kubectl create -f FILE --dry-run=server -o yaml

also accepted

kubectl create -f FILE --dry-run=serverkubectl create -f

Command breakdown

Part of the Kubernetes CLI (kubectl) — Resource Operations category.

kubectlcreate-fFILE--dry-run=server-oyaml
FlagPurpose
-fBoolean flag
--dry-runSet to: server
-oBoolean flag

Test your recall — not just your reading.

Practice with interactive quiz →