mirror of
https://github.com/retspen/webvirtcloud
synced 2026-12-03 17:36:05 +00:00
feat(vmbackups): delete a backup; the Backups page
Backups in the menu now opens a page of every backup, newest first, filtered by VM name, target and state; a removed VM's backups are marked. Each backup, there and on the VM's Backups tab, has a Delete button (also DELETE /api/v1/backups/<uuid>/, 202 with the job). The backup.delete job holds the backup and its target. Through the first of the target's computes that reaches its pool, it marks the backup deleting, removes the manifest first, so the target no longer holds a complete backup, then every other file named from the backup's UUID (also those a failed backup left), then the row. Recovery runs the same steps again. A backup being made is refused: its job is cancelled instead. States and consistency are shown in the reader's language.
This commit is contained in:
parent
f4559acbc7
commit
7227867d78
17 changed files with 607 additions and 117 deletions
|
|
@ -400,7 +400,7 @@ class BackupTabTests(PageControls, TransactionTestCase):
|
|||
self.controls(admin)
|
||||
page = lxml_html.fromstring(self.last_page)
|
||||
self.assertIn("ctl-vm has TPM state", page.xpath("string(//div[@id='backups'])"))
|
||||
self.assertFalse(page.xpath("//div[@id='backups']//form"))
|
||||
self.assertFalse(page.xpath("//div[@id='backups']//form[contains(@action, '/create/')]"))
|
||||
|
||||
def test_owners_have_no_backups_tab(self):
|
||||
self.controls(self.user("tab-owner", owner={"is_change": True}))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue