Beispiel #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 {}
Beispiel #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 {}
Beispiel #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)
Beispiel #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)
Beispiel #5
0
 def setup_pxe(self):
     # hook for subclasses
     bmm_api.clear_pxe(self.machine.device_name)
Beispiel #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)
Beispiel #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)
Beispiel #8
0
 def setup_pxe(self):
     # hook for subclasses
     bmm_api.clear_pxe(self.machine.device_name)
Beispiel #9
0
 def POST(self, device_name):
     api.clear_pxe(device_name)
     return {}
Beispiel #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)
Beispiel #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)
Beispiel #12
0
 def POST(self, device_name):
     api.clear_pxe(device_name)
     return {}