How to Lint a Kubernetes Manifest
Use the Kubernetes Linter to validate manifest YAML for required fields and best-practice warnings before deploying.
Tool Used
Kubernetes Linter
Paste your manifest YAML
Paste your Kubernetes manifest into the textarea. Multiple documents separated by --- are supported, so you can lint an entire manifest file at once.
Identify the resource kind
The linter detects the kind field (Deployment, Service, ConfigMap, etc.) and applies the relevant checks for that resource type automatically.
Fix errors for missing required fields
Red error items flag missing required fields like apiVersion, kind, and metadata.name. A manifest missing any of these will be rejected by the Kubernetes API server.
Address best-practice warnings
Yellow warnings highlight issues that will not immediately break a deploy but cause problems in production: add CPU and memory resource limits to containers, and avoid the :latest image tag which prevents reliable rollbacks.
Add metadata.namespace
If no namespace is specified, resources deploy to the default namespace — a common mistake in production clusters. Add metadata.namespace to ensure resources land in the correct environment.
All done!
You are ready to use Kubernetes Linter like a pro.