Extract YAML fields with yq.
Section: Go Templates, Custom Columns, and jq-Friendly Patterns
Search YAML output
bash
bash
kubectl get deployment web -n payments -o yaml | yq '.spec.template.spec.containers[].image'Explanation
Extract YAML fields with yq.
Learn the surrounding workflow
Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.
Related commands
Same sheet · prioritizing Go Templates, Custom Columns, and jq-Friendly Patterns