mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
When running osquery commands through cmd.run we should pass python_shell=True to ensure everything is formatted right. #42873
This commit is contained in:
parent
a537197030
commit
5ac41f496d
1 changed files with 1 additions and 1 deletions
|
@ -56,7 +56,7 @@ def _osquery(sql, format='json'):
|
|||
}
|
||||
|
||||
cmd = 'osqueryi --json "{0}"'.format(sql)
|
||||
res = __salt__['cmd.run_all'](cmd)
|
||||
res = __salt__['cmd.run_all'](cmd, python_shell=True)
|
||||
if res['retcode'] == 0:
|
||||
ret['data'] = json.loads(res['stdout'])
|
||||
else:
|
||||
|
|
Loading…
Add table
Reference in a new issue