Post #2087452
2026-03-31 08:41 UTC
@jwalzer @hikhvar @anton @falk_ @netzwerkgoettin
https://blog.koehntopp.info/2016/09/01/be-simple-be-boring-be-obvious/
It is impossible to do complicated things in Ansible. At some point, if Ansible is not sufficient, you need to stop ansibilizing and switch to Python. That’s a good point to raise the issue with the team and asking around what’s actually the problem and how an Ansible extension written in Python is going to make this better.
and
We also looked at our YAML shovels and asked ourselves what they are good for. We found that they are overgeneralised solutions for our problems. We do not need to be able to write any conceivable Apache config from our config management code, we only need to be able to write our Apache config from it.
and
Feature development is about generalisation, avoiding limits, delaying decisions and being more flexible.
Infrastructure development is about being concrete, making decisions, setting limits and being obvious.
Nimm nicht die Rolle aus Puppet Forge oder Ansible Galaxy.
Sie tut nicht das was Du willst.
Sie tut außerdem nicht NUR das was Du willst.
Lies die Rolle aus Forge oder Galaxy. Dann schmeiß sie weg und schreibe eine eigene. Schreibe nur das hin, was Du brauchst. Nicht, was Du denkst, das Du brauchen wirst, YAGNI.
Wenn es so kompliziert ist, daß es Tests braucht, ist es nicht für Puppet oder Ansible. Mach was anderes.
Wir haben https://blog.koehntopp.info/2022/12/12/ansible-list-crossproduct/ in Ansible nativ machen können (genauer in Jinja2), aber das war falsch. Wir haben es dann in Python gemacht, und das hat viel weniger weh getan.
Wenn Du programmieren mußt, dann verwende wenigstens eine Programmiersprache.
Replies (0)
No replies.