Skip to content

Commit 494d6f5

Browse files
committed
Remove invalid container PATH lookup
1 parent d6de03a commit 494d6f5

File tree

1 file changed

+1
-11
lines changed

1 file changed

+1
-11
lines changed

archinstall/lib/boot.py

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
from types import TracebackType
55
from typing import ClassVar, Self
66

7-
from archinstall.lib.command import SysCommand, SysCommandWorker, locate_binary
7+
from archinstall.lib.command import SysCommand, SysCommandWorker
88
from archinstall.lib.exceptions import SysCallError
99
from archinstall.lib.output import error
1010

@@ -105,17 +105,7 @@ def is_alive(self) -> bool:
105105
return self.session.is_alive()
106106

107107
def SysCommand(self, cmd: list[str], *args, **kwargs) -> SysCommand: # type: ignore[no-untyped-def]
108-
if cmd[0][0] != '/' and cmd[0][:2] != './':
109-
# This check is also done in SysCommand & SysCommandWorker.
110-
# However, that check is done for `machinectl` and not for our chroot command.
111-
# So this wrapper for SysCommand will do this additionally.
112-
113-
cmd[0] = locate_binary(cmd[0])
114-
115108
return SysCommand(['systemd-run', f'--machine={self.container_name}', '--pty', *cmd], *args, **kwargs)
116109

117110
def SysCommandWorker(self, cmd: list[str], *args, **kwargs) -> SysCommandWorker: # type: ignore[no-untyped-def]
118-
if cmd[0][0] != '/' and cmd[0][:2] != './':
119-
cmd[0] = locate_binary(cmd[0])
120-
121111
return SysCommandWorker(['systemd-run', f'--machine={self.container_name}', '--pty', *cmd], *args, **kwargs)

0 commit comments

Comments
 (0)