Esempio n. 1
0
 def POST(self, device_name):
     args, body = templeton.handlers.get_request_parms()
     if 'pxe_config' in body:
         api.set_pxe(device_name, body['pxe_config'],
                     body.get('boot_config', ''))
     else:
         api.clear_pxe(device_name)
     # start the power cycle and ignore the result
     api.start_powercycle(device_name, lambda *args: None)
     return {}
Esempio n. 2
0
 def POST(self, device_name):
     args, body = templeton.handlers.get_request_parms()
     if 'pxe_config' in body:
         api.set_pxe(device_name, body['pxe_config'],
                 body.get('boot_config', ''))
     else:
         api.clear_pxe(device_name)
     # start the power cycle and ignore the result
     api.start_powercycle(device_name, lambda *args : None)
     return {}
Esempio n. 3
0
 def call_first():
     if new_pxe_config is None:
         bmm_api.clear_pxe(device_name)
     else:
         bmm_api.set_pxe(device_name, new_pxe_config, new_boot_config)
Esempio n. 4
0
 def on_b2g_downloading(self, args):
     self.machine.clear_counter(self.state_name)
     bmm_api.clear_pxe(self.machine.device_name)
     self.machine.goto_state(b2g_downloading)
Esempio n. 5
0
 def setup_pxe(self):
     # hook for subclasses
     bmm_api.clear_pxe(self.machine.device_name)
Esempio n. 6
0
 def call_first():
     if new_pxe_config is None:
         bmm_api.clear_pxe(device_name)
     else:
         bmm_api.set_pxe(device_name, new_pxe_config, new_boot_config)
Esempio n. 7
0
 def on_b2g_downloading(self, args):
     self.machine.clear_counter(self.state_name)
     bmm_api.clear_pxe(self.machine.device_name)
     self.machine.goto_state(b2g_downloading)
Esempio n. 8
0
 def setup_pxe(self):
     # hook for subclasses
     bmm_api.clear_pxe(self.machine.device_name)
Esempio n. 9
0
 def POST(self, device_name):
     api.clear_pxe(device_name)
     return {}
Esempio n. 10
0
 def on_self_test_running(self, args):
     self.machine.clear_counter(self.state_name)
     bmm_api.clear_pxe(self.machine.device_name)
     self.machine.goto_state(self_test_running)
Esempio n. 11
0
 def on_mobile_init_started(self, args):
     self.machine.clear_counter(self.state_name)
     bmm_api.clear_pxe(self.machine.device_name)
     self.machine.goto_state(mobile_init_started)
Esempio n. 12
0
 def POST(self, device_name):
     api.clear_pxe(device_name)
     return {}