
The YAML Errors That Break Your CI Pipeline at 2 AM
Last month I pushed a Kubernetes deployment manifest that looked perfectly fine. The CI pipeline failed silently, the deployment never rolled out, and I spent forty minutes reading logs before I realized the problem was a single tab character in my YAML file. YAML doesn't allow tabs for indentation. Only spaces. And the error message from kubectl was completely unhelpful. YAML is everywhere in modern development. Docker Compose, GitHub Actions, Kubernetes, Ansible, CloudFormation, Helm charts, Swagger/OpenAPI specs. If you work with infrastructure or CI/CD, you write YAML daily. And YAML has a talent for failing in ways that are hard to diagnose. Here's why, and what to watch for. Indentation is structure, not style In JSON, indentation is cosmetic. You can minify an entire JSON object onto one line and it parses identically. In YAML, indentation is the syntax. It defines the hierarchy of your data. And the rules are strict. # This is valid server : port : 8080 host : localhost # This
Continue reading on Dev.to
Opens in a new tab


