mirror of
https://github.com/valitydev/salt.git
synced 2024-11-08 01:18:58 +00:00
Merge pull request #26110 from jfindlay/tar_sources
check for sources before adding them to cmd str
This commit is contained in:
commit
6d2835b464
@ -103,7 +103,9 @@ def tar(options, tarfile, sources=None, dest=None,
|
||||
cmd.extend(['-C', '{0}'.format(dest)])
|
||||
|
||||
cmd.extend(['-{0}'.format(options), '{0}'.format(tarfile)])
|
||||
cmd.extend(sources)
|
||||
|
||||
if sources:
|
||||
cmd.extend(sources)
|
||||
|
||||
return __salt__['cmd.run'](cmd,
|
||||
cwd=cwd,
|
||||
|
Loading…
Reference in New Issue
Block a user