core: add VM persistence info to qubesdb (#1101)

Fixes qubesos/qubes-issues#1101
This commit is contained in:
Marek Marczykowski-Górecki 2015-09-02 00:15:14 +02:00
parent e3ae3cdf34
commit 3beb307901

View File

@ -1020,6 +1020,10 @@ class QubesVm(object):
self.qdb.write("/name", self.name)
self.qdb.write("/qubes-vm-type", self.type)
self.qdb.write("/qubes-vm-updateable", str(self.updateable))
self.qdb.write("/qubes-vm-persistence",
"full" if self.updateable else "rw-only")
self.qdb.write("/qubes-base-template",
self.template.name if self.template else '')
if self.is_netvm():
self.qdb.write("/qubes-netvm-gateway", self.gateway)