3 ms·
> At what point do we get so deep into templates that we just admit that anything short of a programming language just isn’t expressive enough for a config file
by jacques_chester 7y ago
> At what point do we get so deep into templates that we just admit that anything short of a programming language just isn’t expressive enough for a config file?
At the point where I'm debugging configuration instead of declaring it.
There is no sweeping answer, because the scope of configuration varies according to the tool. Systems like Kubernetes or Concourse accept records rather than configuration per se. At least conceptually, these are projections of an underlying model. They are not the model itself and won't be the most compact representation.
Because they are projections, they will inevitably fail to fulfill some degree of schematic normalisation. This means repetition, which for most engineers is interpreted as "I need a loop" instead of "I need a set notation".
I prefer ytt to most alternatives I've seen because it's at least trying to avoid introducing unwanted Turing completeness. Where possible, your configuration language shouldn't be an attack vector.
I'd prefer a more relational or logical style of configuration (I expect CUE folks will be here shortly), but given the continuing efforts to disguise and hide even SQL from programmers, I'm not going to hold my breath.