mc_remote_pillar / masterless pillar management

The idea is to have masterless managed tenants, where the pillar is remotely generated on a central box and replicated onto final destinations via ssh+rsync.

From this central box:

  • We autodiscover the ids of the boxes to manage by calling all discovered *.get_masterless_makinastates_hosts functions and execute them. Those functions should return minions ids to act on. Remember not to rely on pillar, as the pillar may not be fully populated here !
  • From then, we execute in parrallel for each host:
    • We locally generate all pillars and dump them to a file
    • We then replicate the pillars to all the online boxes
      • We may rollback the previous pillar in case of errors

To customize the pillar configuration, you can

  • add static pillar
  • add an ext_pillar that generates pillar entries depending on the minion id

But you won’t have access to remote box grains as we won’t use either classical MQ salt or salt+ssh, so don’t use pillar grains matching !

exception mc_states.modules.mc_remote_pillar.AnsibleInventoryIncomplete

.

mc_states.modules.mc_remote_pillar.get_pillar(minion='*', skipped=None, saltenv='base', **kwargs)

Returns the compiled pillar either of a specific minion or just the global available pillars. This function assumes that no minion has the id *.