diff options
Diffstat (limited to 'subplot/vmadm.py')
-rw-r--r-- | subplot/vmadm.py | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/subplot/vmadm.py b/subplot/vmadm.py index ae3a3a3..6997c5b 100644 --- a/subplot/vmadm.py +++ b/subplot/vmadm.py @@ -63,20 +63,21 @@ def directories_match(ctx, actual=None, expected=None): assert_eq(edata, adata) -def create_vm(ctx, filename=None): +def create_vm(ctx, config=None, filename=None): runcmd_run = globals()["runcmd_run"] runcmd_exit_code_is_zero = globals()["runcmd_exit_code_is_zero"] + ctx["config"] = config ctx["spec"] = filename - runcmd_run(ctx, ["vmadm", "new", filename]) + runcmd_run(ctx, ["vmadm", "new", "--config", config, filename]) runcmd_exit_code_is_zero(ctx) -def delete_vm(ctx, filename=None): +def delete_vm(ctx, config=None, filename=None): runcmd_run = globals()["runcmd_run"] runcmd_exit_code_is_zero = globals()["runcmd_exit_code_is_zero"] - runcmd_run(ctx, ["vmadm", "delete", ctx["spec"]]) + runcmd_run(ctx, ["vmadm", "delete", "--config", ctx["config"], ctx["spec"]]) runcmd_exit_code_is_zero(ctx) |