mirror of
https://github.com/valitydev/salt.git
synced 2024-11-08 17:33:54 +00:00
Use the shell grain as the default
This commit is contained in:
parent
7332af22a9
commit
6f74470dce
@ -42,7 +42,7 @@ def wait(name,
|
||||
cwd='/root',
|
||||
user=None,
|
||||
group=None,
|
||||
shell='/bin/sh'):
|
||||
shell=None):
|
||||
'''
|
||||
Run the given command only if the watch statement calls it
|
||||
|
||||
@ -82,7 +82,7 @@ def run(name,
|
||||
cwd='/root',
|
||||
user=None,
|
||||
group=None,
|
||||
shell='/bin/sh',
|
||||
shell=None,
|
||||
env=()):
|
||||
'''
|
||||
Run a command if certain circumstances are met
|
||||
@ -110,7 +110,7 @@ def run(name,
|
||||
The group context to run the command as
|
||||
|
||||
shell
|
||||
The shell to use for execution, defaults to /bin/sh
|
||||
The shell to use for execution, defaults to the shell grain
|
||||
'''
|
||||
ret = {'name': name,
|
||||
'changes': {},
|
||||
@ -146,7 +146,7 @@ def run(name,
|
||||
|
||||
cmd_kwargs = {'cwd': cwd,
|
||||
'runas': user,
|
||||
'shell': shell,
|
||||
'shell': shell or __grains__['shell'],
|
||||
'env': env}
|
||||
|
||||
if onlyif:
|
||||
|
Loading…
Reference in New Issue
Block a user