Salt 0.17 compatibility for deployment scripts

Between an older salt release and 0.17 salt-call pillar results
were returned directly, rather than including them within a 'local'
hash. Having a 'local' hash makes peer returned pillar results and
salt master returned pillar results more consistent.

This change adds in a conditional to check if local is available
to provide backwards compatibility for our current version of salt.
After we've upgraded I'll remove it.

Change-Id: I385267b28151f476a3317f8a771dff008358e521
Merge "Salt 0.17 compatibility for deployment scripts" into production