Hacker News new | ask | show | jobs
by aaronbrethorst 2 days ago
The knowledge is in the YAML

Exactly why I hate CloudFormation, K8S, GitHub Actions, etc. yaml is a terrible format for the knowledge encoded in these artifacts.

1 comments

There are compile-to-yaml config languages
Any good ones people would recommend?
In my experience I tried a few and kept returning to just Typescript with a good YAML serializer library. Most of what you need in YAML programming is "Typed JSON" and Typescript is an excellent "Typed JSON" and "Typed JSON modularization and merger tool". Then just a little bit of glue code to pass your finished "Typed JSON" into a YAML serializer, depending on any "complex" YAML features you might need.
Not a bad solution at all. It does require some discipline to write deterministic templates etc. though.