Beispiel #1
0
    def rebootMachine(self, waitSeconds=3):
        self._isRebootTriggered = True
        System.setRegistryValue(System.HKEY_LOCAL_MACHINE,
                                "SOFTWARE\\opsi.org\\winst", "RebootRequested",
                                0)

        # Running in thread to avoid failure of reboot (device not ready)
        RebootThread().start()
Beispiel #2
0
 def clearShutdownRequest(self):
     System.setRegistryValue(System.HKEY_LOCAL_MACHINE,
                             "SOFTWARE\\opsi.org\\winst",
                             "ShutdownRequested", 0)