Simplify QubesTemplateVm class
This commit is contained in:
parent
38f3e98f36
commit
bd84ebfd8a
@ -109,21 +109,7 @@ class QubesTemplateVm(QubesVm):
|
|||||||
if dry_run:
|
if dry_run:
|
||||||
return
|
return
|
||||||
|
|
||||||
|
super(QubesTemplateVm, self).verify_files()
|
||||||
if not os.path.exists (self.dir_path):
|
|
||||||
raise QubesException (
|
|
||||||
"VM directory doesn't exist: {0}".\
|
|
||||||
format(self.dir_path))
|
|
||||||
|
|
||||||
if not os.path.exists (self.root_img):
|
|
||||||
raise QubesException (
|
|
||||||
"VM root image file doesn't exist: {0}".\
|
|
||||||
format(self.root_img))
|
|
||||||
|
|
||||||
if not os.path.exists (self.private_img):
|
|
||||||
raise QubesException (
|
|
||||||
"VM private image file doesn't exist: {0}".\
|
|
||||||
format(self.private_img))
|
|
||||||
|
|
||||||
if not os.path.exists (self.volatile_img):
|
if not os.path.exists (self.volatile_img):
|
||||||
raise QubesException (
|
raise QubesException (
|
||||||
@ -135,11 +121,6 @@ class QubesTemplateVm(QubesVm):
|
|||||||
"Clean VM volatile image file doesn't exist: {0}".\
|
"Clean VM volatile image file doesn't exist: {0}".\
|
||||||
format(self.clean_volatile_img))
|
format(self.clean_volatile_img))
|
||||||
|
|
||||||
if not os.path.exists (self.kernels_dir):
|
|
||||||
raise QubesException (
|
|
||||||
"VM's kernels directory does not exist: {0}".\
|
|
||||||
format(self.kernels_dir))
|
|
||||||
|
|
||||||
return True
|
return True
|
||||||
|
|
||||||
def reset_volatile_storage(self, verbose = False):
|
def reset_volatile_storage(self, verbose = False):
|
||||||
|
Loading…
Reference in New Issue
Block a user