docs(link): sidecar never reads shard files; everything goes over the bridge #420
@@ -58,7 +58,7 @@ Only the sidecar is exposed, and only to your website.
|
||||
| The sidecar on the **same host** as the shard | The shard connects to `127.0.0.1:7788`. Splitting them is not supported — the loopback socket *is* the trust boundary for inbound commands. |
|
||||
| Admin access to your Runic Gateway site | The last step is pasting four values into Admin → Shard (uo-link). |
|
||||
| `libgdiplus` *(Linux hosts only)* | Only needed for **artwork**. ServUO runs under Mono on Linux, and Mono's `System.Drawing` — which the shard uses to decode sprites out of your UO client — is a thin layer over this library. Without it the site's creature portraits and item pictures stay empty; names and the spawn atlas are unaffected. `sudo apt-get install libgdiplus` (or `dnf install libgdiplus`); `doctor` checks for it. **Windows hosts need nothing.** See [`../link/SHARD_PREREQS.md`](../link/SHARD_PREREQS.md). |
|
||||
| **ServUO can read its UO client files** *(Linux hosts only)* | The shard reads clilocs and art straight out of your UO client and serves them over the bridge, so the account **ServUO runs as** must have **read and traverse** access to the client data directory (`Cliloc.enu`, `art*.mul`, `anim*.mul`, …). Usually automatic — the shard owns its own tree — but on Linux it bites when those files are owned by a different account, or ServUO runs under a locked-down service user or a systemd sandbox. Fix: run ServUO as the user that owns the client files, or grant that user access (`chmod`/`setfacl` read + traverse — traverse means `+x` on every parent directory). Symptom: cliloc or art imports come back "not found" or empty though the file is present. **Windows hosts need nothing.** See [`../link/SHARD_PREREQS.md`](../link/SHARD_PREREQS.md). |
|
||||
| **ServUO can read its UO client files** *(Linux hosts only)* | The shard reads clilocs and art straight out of your UO client and serves them over the bridge, so the account **ServUO runs as** must have **read and traverse** access to the client data directory (`Cliloc.enu`, `art*.mul`, `anim*.mul`, …). Usually automatic — the shard owns its own tree — but on Linux it bites when those files are owned by a different account, or ServUO runs under a locked-down service user or a systemd sandbox. Fix: run ServUO as the user that owns the client files, or grant that user access (`chmod`/`setfacl` read + traverse — traverse means `+x` on every parent directory). Symptom: cliloc or art imports come back "not found" or empty though the file is present. Only ServUO's account needs this access. The sidecar's `runicgateway` user needs none, because the sidecar never reads shard files. **Windows hosts need nothing.** See [`../link/SHARD_PREREQS.md`](../link/SHARD_PREREQS.md). |
|
||||
|
||||
**Back up first.** The overlay overwrites `Scripts/Scripts.csproj` (a stock file), and the patch
|
||||
tier edits stock sources. A copy of `Scripts/` and `Config/` before you start costs nothing.
|
||||
@@ -790,6 +790,10 @@ sudo systemctl enable --now runicgateway-link
|
||||
systemctl status runicgateway-link
|
||||
```
|
||||
|
||||
The `runicgateway` user needs nothing under the shard's own directory. Leave the shard tree
|
||||
private to the account ServUO runs as (`drwxr-x---` is fine). The sidecar never reads shard files;
|
||||
everything it serves comes over the bridge ([`../link/PLAN.md`](../link/PLAN.md) §2).
|
||||
|
||||
**Windows** (elevated PowerShell) — binary under `%ProgramFiles%`, data under `%ProgramData%`:
|
||||
|
||||
```powershell
|
||||
|
||||
@@ -57,6 +57,7 @@ Non-negotiable rules, all of which the measurements support:
|
||||
- **Inbound commands marshal back via `Timer.DelayCall(TimeSpan.Zero, ...)`**, which is lock-protected and cross-thread safe (`Server/Timer.cs:243-251`). The read thread touches no `World`/`Mobile`/`Item` API.
|
||||
- **Bound the outbound queue** (drop-oldest + a dropped counter). A stalled sidecar must never OOM the shard.
|
||||
- **Never block or throw inside an EventSink handler.** Several are veto hooks sitting in a transaction path.
|
||||
- **Everything goes over the bridge; the sidecar never reads shard files.** The shard (as the account ServUO runs as) reads its own data and client files — `DataPath.cfg`, `Cliloc.enu`, `art*.mul`, saves — and serves anything the website needs as a bridge message (`cliloc.table`, the asset families). The sidecar reads only its own config and database. So the sidecar's service user needs **no** access to the shard tree, and on Linux it normally has none: a `drwxr-x--- servuo servuo` shard root is the intended state, not a gap to grant around. A feature that seems to need a shard file in the sidecar is a new command or event instead.
|
||||
|
||||
---
|
||||
|
||||
|
||||
Reference in New Issue
Block a user