Completed
Pull Request — master (#543)
by
unknown
03:20 queued 51s
created

DeleteVMAction   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 8
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
dl 0
loc 8
rs 10
c 0
b 0
f 0
wmc 1
1
from lib.action import PyraxBaseAction
2
3
__all__ = [
4
    'DeleteVMAction'
5
]
6
7
8
class DeleteVMAction(PyraxBaseAction):
9
    def run(self, vm_id):
10
        cs = self.pyrax.cloudservers
11
12
        server = cs.servers.get(vm_id)
13
        server.delete()
14
15
        return True
16