states and functions

18 views
Skip to first unread message

William Cannon

unread,
Dec 16, 2013, 5:52:08 PM12/16/13
to salt-...@googlegroups.com
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



William Cannon

unread,
Dec 16, 2013, 5:58:45 PM12/16/13
to salt-...@googlegroups.com
ok - I needed to read a little deeper and search through these archives more.


(thanks Colton - I'm going to try what you recommended in the above)

Colton Myers

unread,
Dec 17, 2013, 1:17:49 PM12/17/13
to salt-...@googlegroups.com
Thanks for searching the archives!  Glad that helped!

--
Colton Myers


--
You received this message because you are subscribed to the Google Groups "Salt-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to salt-users+...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply all
Reply to author
Forward
0 new messages