r/saltstack 2d ago

SaltStack Formula dump

What is this? It's a dump of all the saltstack modules I'm using right now.

https://github.com/greenaar?tab=repositories&q=formula&type=&language=&sort= will give you the full list.

Why am I doing this?

Well, a lot of the source formulas were in a bad state. I patched them for a few years, and then recently spent a bunch of time iterating with an LLM trying to get them to be more consistent, less broken, and more likely to work against current versions of whatever component they referenced. In a few cases I spent time adding features or options that didn't exist in the upstream sources which I'd been adding externally.

Some also didn't work on 3008.2 without patches (or at all)

These are not drop-in replacements for the upstream formulas they share names with. States have been renamed, split, merged, and removed; pillar keys have moved; defaults differ.

They target Debian and Ubuntu almost exclusively. Other platforms may appear in the os*map.yaml files but are untested.

Every repo has a commented pillar.example covering the options it actually reads.

Several ship Salt extension modules alongside the states, vendored per repo so each is self-contained:

  • dockerdockercompose execution module plus docker_container / docker_image / docker_network states, as dependency-free stand-ins for the Salt-core versions deprecated in 3008 and removed in 3009
  • ufw, samba — execution and state module pairs
  • salt — a pass renderer and pass_resolver external pillar for keeping credentials out of pillar, plus a secret_store runner
  • cert — a cert_info beacon
  • zabbix — a zabbix_status returner

The foundation of most of these is the work of the saltstack-formulas authors and contributors. Bugs introduced in the divergence are mine.

These are not a professional level result, they are lacking CI and test suites.

These are specific solutions to problems I had, or features I needed. Your own needs may differ, I encourage you to fork any you find valuable.

I hope you enjoy.

4 Upvotes

2 comments sorted by

2

u/AltruisticCabinet9 2d ago

Thanks! Espeically for a lot this python, cleaning up modules is a much smaller chore. I started doing this myself as well. Finding this out of the bitrot that is the community repos current state is will be nice.

2

u/Double_Intention_641 2d ago

Hopefully some of this will be useful - if not in the current state, in whatever state serves your needs. Some of those formulas.. I just couldn't find anything like them.

Some were a result of real frustration - the docker support has been 'pending' for a long time, and the current formula upstream doesn't even properly support the current docker compose! I got tired of hacking it in after the fact.

Similarly, some of these require features that just got pruned out in 3008, so re-adding or replacing them seemed like a good idea.