Skip to content

Commit

Permalink
Merge pull request #18366 from thatch45/saltfile_parser
Browse files Browse the repository at this point in the history
Get non standard saltfile opts into opts
  • Loading branch information
thatch45 committed Nov 21, 2014
2 parents be35e1c + 1bfc9c6 commit b1e2d28
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions salt/utils/parsers.py
Original file line number Diff line number Diff line change
Expand Up @@ -293,6 +293,8 @@ def process_saltfile(self):
saltfile = os.path.join(os.getcwd(), 'Saltfile')
if os.path.isfile(saltfile):
self.options.saltfile = saltfile
else:
saltfile = self.options.saltfile

if not self.options.saltfile:
# There's still no valid Saltfile? No need to continue...
Expand Down Expand Up @@ -372,6 +374,10 @@ def process_saltfile(self):
option.dest,
cli_config[option.dest])

# Any left over value in the saltfile can now be safely added
for key in cli_config:
setattr(self.options, key, cli_config[key])


class HardCrashMixin(object):
__metaclass__ = MixInMeta
Expand Down Expand Up @@ -2168,6 +2174,12 @@ def _mixin_setup(self):
'time to manage connections, the more running processes the '
'faster communication should be, default is %default'
)
self.add_option(
'--extra-filerefs',
dest='extra_filerefs',
default=None,
help='Pass in extra files to include in the state tarball'
)
self.add_option(
'-v', '--verbose',
default=False,
Expand Down

0 comments on commit b1e2d28

Please sign in to comment.