I'm curious about KYAML and whether it's being utilized in real-world scenarios today. I understand that it improves upon previous YAML versions used in Kubernetes by being less sensitive to whitespace, which is a huge plus. Most examples I've seen focus on Kubernetes abstractions like pods and services. But does KYAML also extend to other Kubernetes tools like Cilium or Falco, which also use YAML for defining policies? It might be an obvious answer of 'no', but I'm really wondering if anyone is currently benefiting from KYAML when writing policies in Kubernetes.
5 Answers
I think the primary issue many have with KYAML is that it feels like a solution to problems that don't occur often. I've personally run into these YAML quirks maybe once in a decade, if that. Moreover, I think it introduces new complications. I'd suggest if folks really feel pressured by YAML's syntax, a well-configured linter could help keep things clean without needing to switch to KYAML.
KYAML is basically just a stricter way to format YAML; JSON is actually still considered valid YAML too. Personally, I really prefer the traditional multiline strings of regular YAML over the KYAML format. Mostly, I tend to use kubectl to edit YAML, so I don't see a huge need for KYAML yet. It might be good for templating stuff with Helm to keep things neat, but I haven't come across it widely used in practice yet. Everyone has their own preferences, so it’ll be interesting to see how it evolves.
I’m not exactly the audience for KYAML, but I think it’s a neat approach! I’d love to see any tools that help enforce this format, like a linter or a VSCode extension. If anyone knows of any handy tools, that would be awesome. Also, I feel like a lot of these complaints boil down to just personal preferences on how we want to write our configuration files!
Honestly, I have yet to see the big differences between KYAML and JSONC. I’ve managed just fine with regular YAML. Sure, there are some intricate parts, but I think that’s just part of the learning curve. A good linter could fix a lot of perceived issues. Besides, everyone seems to have their own complaints about YAML, but I suspect a lot of those boils down to personal organization and formatting.
As the author of KCL, I'm not sure how well KYAML could be integrated for direct support. It's a specific style of YAML, really just enforcing format more than functionality. If someone wants to work with KYAML, maybe they could reprocess KCL's outputs into that format if necessary, although I haven't actively seen a demand for it. It's mainly just an opinionated formatting style.

Related Questions
How To: Running Codex CLI on Windows with Azure OpenAI
Set Wordpress Featured Image Using Javascript
How To Fix PHP Random Being The Same
Why no WebP Support with Wordpress
Replace Wordpress Cron With Linux Cron
Customize Yoast Canonical URL Programmatically