Make non-existent pillar cause warning or error
<p><strong>Is there any way to cause rendering of a salt state to output a warning or error when a requested pillar is not found?</strong></p>

<p>I'm setting up Saltstack for a system with <em>a lot</em> of components, and we use pillars to make sure different Salt states have the same values where appropriate. We also aim to keep all values that will differ from installation to installation in pillars. So there are many pillar files and the total amount of pillar variables is slightly unhinged. When we're installing this system again we'll have to make sure that all all pillars are defined and have an appropriate value. In this process it would greatly help to have warnings or errors when pillars are undefined, instead of having to grep for "None" through the entire minion, then working out where things went wrong. Is there any way to accomplish such warnings or errors?</p>

<p>We can't possibly be the only company with a complicated salt installation.</p>

<p>SOLUTION:
As linked in the approved answer, the solution is to add the following to /etc/salt/minion:</p>

<pre><code>pillar_raise_on_missing: True
PILLAR_RAISE_ON_MISSING: True
</code></pre>

<p>Remember to restart salt-minion</p>