From 2de6550a70fab797c242f9355f225038691b8ad9 Mon Sep 17 00:00:00 2001
From: Simon McVittie <smcv@collabora.com>
Date: Thu, 21 Nov 2024 18:36:38 +0000
Subject: [PATCH] pv-wrap(1): Document some useful environment variables used
 in SLR

These don't actually affect the behaviour of pv-wrap, but they're
sufficiently closely-related that it makes sense to document them here.

Signed-off-by: Simon McVittie <smcv@collabora.com>
---
 pressure-vessel/wrap.1.md | 59 +++++++++++++++++++++++++++++++++++++++
 1 file changed, 59 insertions(+)

diff --git a/pressure-vessel/wrap.1.md b/pressure-vessel/wrap.1.md
index 8b8aacaa0..d187ccd09 100644
--- a/pressure-vessel/wrap.1.md
+++ b/pressure-vessel/wrap.1.md
@@ -370,6 +370,13 @@ The following environment variables (among others) are read by
 `PRESSURE_VESSEL_LOG_WITH_TIMESTAMP` (boolean)
 :   If set to 1, same as `SRT_LOG=timestamp`
 
+`PRESSURE_VESSEL_PREFIX` (path)
+:   pressure-vessel itself does not use this,
+    but the Steam Linux Runtime container runtime framework uses it to
+    locate a custom version of pressure-vessel.
+    If used, it must be set to a relocatable build of pressure-vessel,
+    so that `$PRESSURE_VESSEL_PREFIX/bin/pressure-vessel-unruntime` exists.
+
 `PRESSURE_VESSEL_REMOVE_GAME_OVERLAY` (boolean)
 :   If set to `1`, equivalent to `--remove-game-overlay`.
     If set to `0`, equivalent to `--keep-game-overlay`.
@@ -420,10 +427,28 @@ The following environment variables (among others) are read by
 :   Used to choose between logically equivalent names for the current
     working directory (see **get_current_dir_name**(3)).
 
+`SRT_LAUNCHER_SERVICE` (path)
+:   pressure-vessel itself does not use this,
+    but in the Steam Linux Runtime container runtime framework,
+    it sets an implementation of **steam-runtime-launcher-service**(1)
+    to use instead of selecting one automatically.
+
+`SRT_LAUNCHER_SERVICE_STOP_ON_EXIT` (boolean)
+:   pressure-vessel itself does not use this,
+    but in the Steam Linux Runtime container runtime framework,
+    setting it to `0` prevents the service started by
+    **STEAM_COMPAT_LAUNCHER_SERVICE** from exiting until it is specifically
+    terminated by `steam-runtime-launch-client --terminate` or a signal.
+
 `SRT_LOG`
 :   A sequence of tokens separated by colons, spaces or commas
     affecting how output is recorded. See source code for details.
 
+`SRT_LOG_ROTATION` (boolean)
+:   pressure-vessel itself does not use this,
+    but in the Steam Linux Runtime container runtime framework,
+    setting it to `0` prevents cleanup of old log files.
+
 `STEAM_COMPAT_APP_ID` (integer)
 :   Equivalent to `--steam-app-id="$STEAM_COMPAT_APP_ID"`.
 
@@ -455,6 +480,20 @@ The following environment variables (among others) are read by
     working directory is actually a subdirectory of this.
     This is made available read/write in the container.
 
+`STEAM_COMPAT_LAUNCHER_SERVICE` (token)
+:   pressure-vessel itself does not use this,
+    but in the Steam Linux Runtime container runtime framework,
+    setting it to **container-runtime** provides a D-Bus service
+    which can be used to send debugging commands into the container
+    environment.
+    In Steam Linux Runtime 1.0,
+    setting it to **scout-in-container** provides a similar D-Bus service
+    where the execution environment is compatible with Steam Runtime 1 'scout'.
+    In Proton, setting it to **proton** provides a similar D-Bus service
+    with an execution environment that is preconfigured to run Proton's
+    version of Wine.
+    See **steam-runtime-launch-client**(1) for examples of how to use this.
+
 `STEAM_COMPAT_LIBRARY_PATHS` (`:`-separated list of paths)
 :   Colon-delimited list of paths to Steam Library directories containing
     the game, the compatibility tools if any, and any other resources
@@ -508,6 +547,26 @@ The following environment variables (among others) are read by
     Steam automatically sets this when system tracing is enabled on a
     Steam Deck in developer mode.
 
+`STEAM_LINUX_RUNTIME_LOG` (boolean)
+:   pressure-vessel itself does not use this,
+    but in the Steam Linux Runtime container runtime framework,
+    setting it to `1` redirects standard output and standard error to
+    `$STEAM_LINUX_RUNTIME_LOG_DIR/slr-*.log` or
+    `$PRESSURE_VESSEL_VARIABLE_DIR/slr-*.log`,
+    while also enabling info-level logging similar to
+    `PRESSURE_VESSEL_LOG_INFO=1`.
+
+`STEAM_LINUX_RUNTIME_KEEP_LOGS` (boolean)
+:   pressure-vessel itself does not use this,
+    but in the Steam Linux Runtime container runtime framework,
+    setting it to `1` prevents cleanup of old log files.
+
+`STEAM_LINUX_RUNTIME_VERBOSE` (boolean)
+:   pressure-vessel itself does not use this,
+    but in the Steam Linux Runtime container runtime framework,
+    setting it to `1` enables debug-level messages similar to
+    `PRESSURE_VESSEL_VERBOSE=1`.
+
 `STEAM_RUNTIME` (path)
 :   **pressure-vessel-wrap** refuses to run if this environment variable
     is set. Use **pressure-vessel-unruntime**(1) instead.
-- 
GitLab