import database
import accounts
import controller
-import sliver_vs
-import sliver_libvirt
+import sliver_lxc
try: from bwlimit import bwmin, bwmax
except ImportError: bwmin, bwmax = 8, 1000*1000*1000
if is_system_sliver(sliver):
sliver['reservation_alive']=True
continue
-
+
# regular slivers
if not active_lease:
# with 'idle_or_shared', just let the field out, behave like a shared node
if rec['instantiation'].lower() == 'nm-controller':
rec.setdefault('type', attributes.get('type', 'controller.Controller'))
else:
- rec.setdefault('type', attributes.get('type', 'sliver.VServer'))
+ rec.setdefault('type', attributes.get('type', 'sliver.LXC'))
# set the vserver reference. If none, set to default.
rec.setdefault('vref', attributes.get('vref', 'default'))
return GetSlivers(data, fullupdate=False)
def start():
- for resname, default_amount in sliver_vs.DEFAULT_ALLOCATION.iteritems():
- DEFAULT_ALLOCATION[resname]=default_amount
+ # No default allocation values for LXC yet, think if its necessary given
+ # that they are also default allocation values in this module
+ #for resname, default_amount in sliver_vs.DEFAULT_ALLOCATION.iteritems():
+ # DEFAULT_ALLOCATION[resname]=default_amount
- #accounts.register_class(sliver_vs.Sliver_VS)
- accounts.register_class(sliver_libvirt.Sliver_LV)
+ accounts.register_class(sliver_lxc.Sliver_LXC)
accounts.register_class(controller.Controller)
database.start()
api_calls.deliver_ticket = deliver_ticket