This might be an easy question. But, I didn't find an answer in the docs yet.
I have a need to run a custom saltstack module whenever a particular state is applied to a minion. And, the custom saltstack module needs to run on the minion that just had a state applied.
Case one: new minion, a state.highstate run
Case two: existing minion, applying a state via state.sls
Ideally I'd love to just put a function declaration in the state sls file. Is there a way to do this? Or, do I need to use the reactor system or is there another convenient way to do the same thing?
Thanks in advance,
William