Brandon Kearns
unread,May 30, 2015, 1:59:23 PM5/30/15Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Sign in to report message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to salt-...@googlegroups.com
I am pretty new to SaltStack, but so far I think it is pretty awesome/powerful stuff. The issue I have now is sort of tying everything together in a maintainable/well-structured way, so I am hoping to get some insight and/or references regarding this. Here is some background info on my environment and what I want to achieve:
I have a Web application built on a number of servers/services - 3 MongoDB servers, 2 Java application servers, 1 NodeJS server, 1 ELK log server, and 1 Nginx server - all running in a VPC on AWS. So far I am able to use salt-cloud with map/profiles/provider to successfully create all those servers, and bootstrap them as salt-minions, even receive the "created" event using reactor.
What I need is to instruct the minions to update, install packages, setup RAID arrays, and manage some config files, etc.. right after creation, but only once. If I set all of that up in state files and have my reactor "created" event call highstate on all minions then it works, but calling highstate a second time would trigger those processes again.
I am sure I am missing something fundamental here, but I guess I am just confused if I should expect to maybe handle my state files in git repo and pull a different branch of state files down after the initial run (and each time I need to manage my minions)? Do I set a file on my minions to track that the initial run has been completed (if file exists don't do XYZ)? Any help pointing me in the right direction is very much appreciated here.