GeezerVison is showing github.com — docs(tests): say what HOME isolation does not cover · lidge-jun/opencodex@3ab6b97
File tree
Expand file treeCollapse file tree
Open diff view settings
Expand file treeCollapse file tree
Open diff view settings
Collapse file
Copy file name to clipboardExpand all lines: tests/preload.ts +7Lines changed: 7 additions & 0 deletions | Original file line number | Diff line number | Diff line change |
|---|
|
10 | 10 | * |
11 | 11 | * Import order below is load-bearing: importing the guard captures the real home at |
12 | 12 | * module load, and that must happen BEFORE this file replaces HOME. |
| 13 | + * |
| 14 | + * What this file cannot do: HOME isolation only protects what is addressed by a path. A |
| 15 | + * service manager is addressed by a job name — `systemctl --user stop |
| 16 | + * opencodex-proxy.service` reaches the user manager that is already running, and |
| 17 | + * `launchctl bootout gui/<uid>/com.opencodex.proxy` reaches launchd — so neither cares |
| 18 | + * what HOME says. `assertLiveServiceManagerAllowed` in `src/service.ts` is the guard for |
| 19 | + * that, armed by the same flag set below. |
13 | 20 | */ |
14 | 21 | import { isTestHomeGuardArmed, protectedHomeForTests } from "../src/lib/test-home-guard"; |
15 | 22 | import { createIsolatedTestEnvironment } from "../scripts/test"; |
|