mirror of https://git.48k.eu/ogclient
poweroff: always call poweroff_oglive and _reboot_oglive
Remove leftover fallback to directly call utilities to poweroff and reboot.master
parent
bcbbe26573
commit
dbda6abd22
|
@ -225,17 +225,11 @@ class OgLiveOperations:
|
|||
|
||||
def poweroff(self):
|
||||
logging.info('Powering off client')
|
||||
if os.path.exists('/scripts/oginit'):
|
||||
self._poweroff_oglive()
|
||||
else:
|
||||
subprocess.call(['/sbin/poweroff'])
|
||||
self._poweroff_oglive()
|
||||
|
||||
def reboot(self):
|
||||
logging.info('Rebooting client')
|
||||
if os.path.exists('/scripts/oginit'):
|
||||
self._poweroff_oglive(operation='reboot')
|
||||
else:
|
||||
subprocess.call(['/sbin/reboot'])
|
||||
self._poweroff_oglive(operation='reboot')
|
||||
|
||||
def shellrun(self, request, ogRest):
|
||||
cmd = request.getrun()
|
||||
|
|
Loading…
Reference in New Issue