mirror of
https://github.com/valitydev/salt.git
synced 2024-11-07 08:58:59 +00:00
Add --skip-grains option to salt-run
This will allow the user to skip grains generation and save the 2+ seconds it takes to generate grains for each call to `salt-run`. Grains are not commonly used in runners. Signed-off-by: Sergey Kizunov <sergey.kizunov@ni.com>
This commit is contained in:
parent
1f460da589
commit
a0b4af4e73
@ -2782,6 +2782,12 @@ class SaltRunOptionParser(six.with_metaclass(OptionParserMeta,
|
|||||||
action='store_true',
|
action='store_true',
|
||||||
help=('Start the runner operation and immediately return control.')
|
help=('Start the runner operation and immediately return control.')
|
||||||
)
|
)
|
||||||
|
self.add_option(
|
||||||
|
'--skip-grains',
|
||||||
|
default=False,
|
||||||
|
action='store_true',
|
||||||
|
help=('Do not load grains.')
|
||||||
|
)
|
||||||
group = self.output_options_group = optparse.OptionGroup(
|
group = self.output_options_group = optparse.OptionGroup(
|
||||||
self, 'Output Options', 'Configure your preferred output format.'
|
self, 'Output Options', 'Configure your preferred output format.'
|
||||||
)
|
)
|
||||||
|
Loading…
Reference in New Issue
Block a user