steam: Allow overriding privateTmp

Some programs use /tmp to communicate, and steam having a private tmp
causes issues with that. Allow disabling privateTmp in an override.

Things that rely on /tmp:
  - PROTON_DUMP_DEBUG_COMMANDS dumps files to /tmp, where they can't
    be retrieved because steam-run gets a different /tmp
  - I'm not sure why this is, but in my testing, running tasklist
    through proton + cmd.exe would only show running steam games
    when privateTmp was false. I wanted this to get the windows
    pid of a steam game for attaching to it with Textractor.
  - Communication between teamspeak/arma 3 as reported in
    https://github.com/NixOS/nixpkgs/issues/381923
This commit is contained in:
Cole Faust
2025-03-08 17:20:41 -08:00
parent 36fd87baa9
commit 9858b625f3
+2 -3
View File
@@ -10,11 +10,12 @@
extraBwrapArgs ? [ ], # extra arguments to pass to bubblewrap (real default is at usage site)
extraArgs ? "", # arguments to always pass to steam
extraEnv ? { }, # Environment variables to pass to Steam
privateTmp ? true, # if the steam bubblewrap should isolate /tmp
}:
let
steamEnv = { name, runScript, passthru ? {}, meta ? {} }:
buildFHSEnv {
inherit name runScript passthru meta;
inherit name runScript passthru meta privateTmp;
multiArch = true;
includeClosures = true;
@@ -105,8 +106,6 @@ let
${extraProfile}
'';
privateTmp = true;
inherit extraPreBwrapCmds;
extraBwrapArgs = [