Scott Baker | 717c19e | 2014-01-21 23:18:49 -0800 | [diff] [blame] | 1 | import os |
| 2 | import sys |
| 3 | from hpc.models import ServiceProvider, ContentProvider, CDNPrefix |
| 4 | from observer.deleter import Deleter |
| 5 | |
| 6 | # hpclibrary will be in steps/.. |
| 7 | parentdir = os.path.join(os.path.dirname(__file__),"..") |
| 8 | sys.path.insert(0,parentdir)
|
| 9 | |
| 10 | from hpclib import HpcLibrary |
| 11 | |
| 12 | class OriginServerDeleter(Deleter, HpcLibrary): |
| 13 | model='OriginServer' |
| 14 | |
| 15 | def __init__(self, **args): |
| 16 | Deleter.__init__(self, **args) |
| 17 | HpcLibrary.__init__(self) |
| 18 | |
| 19 | def call(self, pk, model_dict): |
| 20 | print "XXX delete origin server", model_dict |
| 21 | self.client.onev.Delete("OriginServer", int(model_dict["origin_server_id"])) |
| 22 | |