machine: use direct systemctl commands for reboot/shutdown

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
This commit is contained in:
Eric Callahan 2023-01-16 12:42:21 -05:00
parent a154c5fa51
commit db81607370
No known key found for this signature in database
GPG Key ID: 5A1EB336DFB4C71B
1 changed files with 2 additions and 2 deletions

View File

@ -780,10 +780,10 @@ class BaseProvider:
return await machine.exec_sudo_command(command)
async def shutdown(self) -> None:
await self._exec_sudo_command(f"shutdown now")
await self._exec_sudo_command("systemctl halt")
async def reboot(self) -> None:
await self._exec_sudo_command(f"shutdown -r now")
await self._exec_sudo_command("systemctl reboot")
async def do_service_action(self,
action: str,