Question 16
Domain 1: Application Design and BuildWhich kubectl command would list Helm-related resources in all namespaces and help you identify deployments that are still pending?
Correct answer: D
Explanation
`helm list --all-namespaces --pending` lists releases across every namespace because `--all-namespaces` expands the scope beyond the current namespace. The `--pending` flag filters to releases in a pending state, which helps identify deployments that have not finished installing or upgrading.
Why each option is right or wrong
A. kubectl get all --all-namespaces
B. kubectl get secrets -A -l owner=helm
C. kubectl get deployments -A --field-selector status.phase=Pending
D. helm list --all-namespaces --pending
Helm’s `list` command supports `--all-namespaces` (`-A`) to query releases cluster-wide rather than only the current namespace, as documented in the Helm CLI reference for `helm list`. The `--pending` filter is also a valid `helm list` flag and returns releases whose status is `pending-install`, `pending-upgrade`, or `pending-rollback`, which is exactly how you surface deployments that have not completed yet.