mirror of
https://github.com/usestrix/strix.git
synced 2026-11-14 09:01:25 +00:00
fix(strix/runtime/docker_client.py): Set HOME=/root when STRIX_HOST_UID is set to avoid Caido sidecar panic for system service accounts
Signed-off-by: cf3901646 <cf3901646@users.noreply.github.com>
This commit is contained in:
parent
aa2036f229
commit
42a4f6cbba
1 changed files with 7 additions and 0 deletions
|
|
@ -196,6 +196,13 @@ class StrixDockerSandboxClient(DockerSandboxClient):
|
|||
"command": ["tail", "-f", "/dev/null"],
|
||||
"environment": environment,
|
||||
}
|
||||
# Fix for system service accounts: ensure HOME is set to a writable directory
|
||||
# when STRIX_HOST_UID is set (i.e., when running as a system account).
|
||||
if environment is None:
|
||||
environment = {}
|
||||
if "STRIX_HOST_UID" in environment and environment["STRIX_HOST_UID"]:
|
||||
environment["HOME"] = "/root"
|
||||
create_kwargs["environment"] = environment
|
||||
if manifest is not None:
|
||||
docker_mounts = _build_docker_volume_mounts(
|
||||
manifest,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue