I had thought that the Reactor engine could use pillar states when running states for minions. It may or may not have worked in the future. For the present, it is confirmed as not working: Pillars not available to reactor states #42762. This refers to another issue which supposedly resolves everything in v2017.7.1: Only force saltenv/pillarenv to be a string when not None #42433.
While discovering this issue, I have been thinking about ways to maintain temporary variables somewhere. I first looked at Thorium, but it doesn't seem to have a very flexible two-step look up system, as I need to access variables based upon minion_id, and service type.
The consul pillar state seems to be used only on the master, but I am thinking something should be available on the minion, or accessible from the minion. I thought of the sqlite state for this, but might be a bit heavy duty.
While researching this issue, I came across other interesting Salt articles, which I book mark here, for possible future reference:
- stretch repository is missing packages #42715: this is interesting because in order to load 2017.7.1, I would have to obtain it from the SaltStack repository (as debian doesn't have this yet), and since I run Stretch and Buster, this might cause some issues.
- SaltStack-able Microservices Architecture: Beating the challenge with SaltStack, upstart, consul, consul-template, logstash, etc. An interesting article as it introduces the concept of a jinja macro.
- Combine multiple pillar files under a single key: uses the 'multiple app needs logrotate entries' problem to introduce the concept of merge, os_family_map (which has another issue in github), and jinja 'do' statements.
- Salt consul pillar list of dicts #34458: not necessarily directly relevant, but does have a link to the YAML v1.2 Specifications.
- Using Consul as an External Pillar Source: a simple, detailed way of using Consul for pillar based data for common data as well as minion specific private data.
- Two entries here from the same blogger: Create self-managing servers with Masterless Minions and Using salt-ssh to install Salt, with a bonus reference: Getting redundancy and scalability with multiple master servers"
- Managing your computers with a Salt Master and Git.
- Some notes on using SaltStack: centers the discussion around roles.
- Using Consul as an External Pillar Source
- SaltStack orchestration with Beacons and Reactors
- Thorium and Salt API chapter extract from a book called "Mastering SaltStack".
- Network Automation at Scale: Up and Running in 60 Minutes: an excellent tutorial on orchestration at scale, from a RIPE 74 presentation.
- Salt-based secret storage solution - many of the chapters are incomplete, but this has content.