deluge: Enable backup/restore

Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
This commit is contained in:
Joseph Nuthalapati 2018-10-15 16:02:22 -07:00 committed by James Valleroy
parent 4c7781a34a
commit 73bfcc41f9
No known key found for this signature in database
GPG Key ID: 77C0C75E7B650808
3 changed files with 20 additions and 1 deletions

View File

@ -38,3 +38,14 @@ Scenario: Upload a torrent to deluge
When all torrents are removed from deluge
And I upload a sample torrent to deluge
Then there should be 1 torrents listed in deluge
Scenario: Backup and restore deluge
Given the deluge application is enabled
When all torrents are removed from deluge
And I upload a sample torrent to deluge
And I create a backup of the deluge app data
And I export the deluge app data backup
And all torrents are removed from deluge
And I restore the deluge app data backup
Then the deluge service should be running
And there should be 1 torrents listed in deluge

View File

@ -25,7 +25,7 @@ from plinth import action_utils, actions, frontpage
from plinth.menu import main_menu
from plinth.modules.users import register_group
from .manifest import clients
from .manifest import backup, clients
version = 2

View File

@ -18,6 +18,7 @@
from django.utils.translation import ugettext_lazy as _
from plinth.clients import validate
from plinth.modules.backups.api import validate as validate_backup
clients = validate([{
'name': _('Deluge'),
@ -27,3 +28,10 @@ clients = validate([{
'url': '/deluge'
}]
}])
backup = validate_backup({
'config': {
'directories': ['/var/lib/deluged/.config', '/var/lib/deluged/config']
},
'services': ['deluge-web']
})