summaryrefslogtreecommitdiff
path: root/src/conf_mode/task_scheduler.py
diff options
context:
space:
mode:
Diffstat (limited to 'src/conf_mode/task_scheduler.py')
-rwxr-xr-xsrc/conf_mode/task_scheduler.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/conf_mode/task_scheduler.py b/src/conf_mode/task_scheduler.py
index 51d8684cb..129be5d3c 100755
--- a/src/conf_mode/task_scheduler.py
+++ b/src/conf_mode/task_scheduler.py
@@ -53,8 +53,11 @@ def make_command(executable, arguments):
else:
return("sg vyattacfg \"{0}\"".format(executable))
-def get_config():
- conf = Config()
+def get_config(config=None):
+ if config:
+ conf = config
+ else:
+ conf = Config()
conf.set_level("system task-scheduler task")
task_names = conf.list_nodes("")
tasks = []