This is a collection of SaltStack States to manage your infrastructure.
All files contained in this repository are Copyright © 2014 by Eugene E. Kashpureff Jr and License granted under the WTFPL(version 2) as outlined in LICENSE.txt, unless otherwise marked.
This collection makes a few assumptions about your infrastructure:
- OS: Developed and maintained using CentOS 7.0+, compatible with Red Hat Enterprise Linux 7.0+. Other RPM-based distributions should work, including Fedora.
- Clone this repository into
/srv/salt/
. - Customize
pillar/defaults.sls
to suit your environment. - Copy
pillar/minion/example-master.sls
topillar/minion/<hostname>.sls
and customize as desired. - Install the salt-minion package. Set
id: <hostname>
in the minion config(/etc/salt/minion). - Perform a state run:
$ salt-call --file-root=/srv/salt/states/ --pillar-root=/srv/salt/pillar/ --local state.apply
- Accept the master's minion key:
$ salt-key -a <hostname> -y
- Enjoy!
- Copy
pillar/minion/example.sls
topillar/minion/<hostname>.sls
and customize as desired. - Provision the minion:
- Linode: Create the Minion from the Master:
$ salt-cloud -p <profile> <hostname>
- Other: Bootstrap the minion:
$ curl https://eugenekay.com/salt | bash
. Accept it on the Master:$ salt-key -a <hostname> -y
- Linode: Create the Minion from the Master:
- Perform a state run from the master:
salt <hostname> state.apply
- Enjoy!