@h-rig/server 0.0.6-alpha.3 → 0.0.6-alpha.31
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +23 -0
- package/dist/src/index.js +1688 -351
- package/dist/src/server-helpers/github-api-session-index.js +107 -0
- package/dist/src/server-helpers/github-auth-store.js +68 -24
- package/dist/src/server-helpers/github-project-status-sync.js +3 -0
- package/dist/src/server-helpers/github-user-namespace.js +102 -0
- package/dist/src/server-helpers/http-router.js +1040 -200
- package/dist/src/server-helpers/inspector-jobs.js +1 -12
- package/dist/src/server-helpers/issue-analysis.js +26 -10
- package/dist/src/server-helpers/pi-session-proxy.js +84 -0
- package/dist/src/server-helpers/project-registry.js +5 -0
- package/dist/src/server-helpers/run-io.js +30 -1
- package/dist/src/server-helpers/run-mutations.js +679 -123
- package/dist/src/server-helpers/run-writers.js +8 -2
- package/dist/src/server-helpers/ws-router.js +16 -6
- package/dist/src/server.js +1687 -351
- package/package.json +4 -4
package/README.md
CHANGED
|
@@ -7,6 +7,29 @@
|
|
|
7
7
|
- serve workspace snapshots and artifacts
|
|
8
8
|
- broker approvals and remote endpoint state
|
|
9
9
|
- expose websocket events for the UI
|
|
10
|
+
- isolate authenticated remote users in GitHub-user namespaces for auth state,
|
|
11
|
+
project registry records, managed checkouts, and uploaded snapshots
|
|
12
|
+
|
|
13
|
+
## Remote user namespaces
|
|
14
|
+
|
|
15
|
+
When a remote client imports a GitHub token or completes device auth, the server
|
|
16
|
+
looks up `/user` and derives the namespace from the stable GitHub numeric user id
|
|
17
|
+
(`ghu-<id>`). The login is retained as display metadata/fallback only; raw tokens
|
|
18
|
+
are never used in filesystem paths or API response metadata.
|
|
19
|
+
|
|
20
|
+
Default layout on hosted deployments:
|
|
21
|
+
|
|
22
|
+
```text
|
|
23
|
+
/srv/rig/users/ghu-123456/.rig/state/github-auth.json
|
|
24
|
+
/srv/rig/users/ghu-123456/.rig/state/projects.json
|
|
25
|
+
/srv/rig/users/ghu-123456/remote-checkouts/<owner>/<repo>
|
|
26
|
+
/srv/rig/users/ghu-123456/remote-snapshots/<owner>/<repo>/<snapshot-id>
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
`RIG_REMOTE_USER_NAMESPACE_ROOT`, `RIG_REMOTE_CHECKOUT_BASE_DIR`, and
|
|
30
|
+
`RIG_REMOTE_SNAPSHOT_BASE_DIR` can override the roots. Existing
|
|
31
|
+
`remote-checkouts/default` paths are treated as explicit/admin existing paths,
|
|
32
|
+
not as the authenticated default.
|
|
10
33
|
|
|
11
34
|
## Commands
|
|
12
35
|
|