mirror of
https://github.com/valitydev/salt.git
synced 2024-11-08 17:33:54 +00:00
Add overstate runner, ready for initial testing
This commit is contained in:
parent
1f4c168733
commit
24b802d11d
25
salt/runners/state.py
Normal file
25
salt/runners/state.py
Normal file
@ -0,0 +1,25 @@
|
||||
'''
|
||||
Execute overstate functions
|
||||
'''
|
||||
|
||||
# Import Salt libs
|
||||
import salt.overstate
|
||||
import salt.output
|
||||
|
||||
def over(env='base', os_fn=None):
|
||||
'''
|
||||
Execute an overstate sequence to orchestrate the executing of states
|
||||
over a group of systems
|
||||
'''
|
||||
overstate = salt.overstate.OverState(__opts__, env, os_fn)
|
||||
over_run = overstate.stages()
|
||||
salt.output.display_output(over_run, 'pprint', opts=__opts__)
|
||||
return over_run
|
||||
|
||||
def show_stages(env='base', os_fn=None):
|
||||
'''
|
||||
Display the stage data to be executed
|
||||
'''
|
||||
overstate = salt.overstate.OverState(__opts__, env, os_fn)
|
||||
salt.output.display_output(overstate.over, 'pprint', opts=__opts__)
|
||||
return overstate.over
|
Loading…
Reference in New Issue
Block a user