Working with dunders
For those of you not in the know, dunder refers to a variable that is preceded and succeeded by two underscores. For instance, one of the most common dunders in Salt is __opts__
, which contains the configuration for either the Master or the Minion, depending on the context. There are a number of dunders that work together to form the glue that ties all of Salt together. Let's take a look at them in turn:
__opts__
: On a Master, the__opts__
dictionary contains a composite of the information located in the Master's configuration files (normally/etc/salt/master
plus files located in the/etc/salt/master.d/
directory), along with the default values for configuration parameters not specified, plus any internal configuration that Salt generates for its own use at runtime.On a Minion,
__opts__
contains the same sort of information (but from the/etc/salt/minion
file and the/etc/salt/minion.d/
directory), when it is connected to the Master. However, when the Minion...