Fixes an issue where Pagerduty states/modules couldn't find it's profile in the Pillar

The pagerduty state currently only works if the pagerduty profile is set
up in the minion config or the master config (if using the pagerduty
runner). This just makes it so it will also look in the pillar for the
specified profile name.
This commit is contained in:
Starblade42 2015-06-03 16:17:04 -06:00
parent 3ca35d1ec3
commit 2dd5904119

View file

@ -39,7 +39,7 @@ def query(method='GET', profile=None, url=None, path='api/v1',
opts = {}
if profile is not None:
creds = opts.get(profile, {})
creds = opts.get(profile, {}) or opts.get('pillar').get(profile,{})
else:
creds = {}