Revision 5f9edd1e
b/snf-cyclades-app/synnefo/api/management/commands/network-remove.py | ||
---|---|---|
30 | 30 |
|
31 | 31 |
from django.core.management.base import BaseCommand, CommandError |
32 | 32 |
from synnefo.logic import networks |
33 |
from synnefo.management.common import get_network |
|
33 |
from synnefo.management.common import get_network, convert_api_faults
|
|
34 | 34 |
|
35 | 35 |
|
36 | 36 |
class Command(BaseCommand): |
37 | 37 |
can_import_settings = True |
38 | 38 |
help = "Remove a network from the Database, and Ganeti" |
39 | 39 |
|
40 |
@convert_api_faults |
|
40 | 41 |
def handle(self, *args, **options): |
41 | 42 |
if len(args) < 1: |
42 | 43 |
raise CommandError("Please provide a network ID") |
Also available in: Unified diff