cyberia 3.2.9 → 3.2.22
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/.github/workflows/engine-cyberia.cd.yml +7 -0
- package/.github/workflows/engine-cyberia.ci.yml +14 -2
- package/.github/workflows/ghpkg.ci.yml +1 -0
- package/.github/workflows/npmpkg.ci.yml +10 -5
- package/.github/workflows/pwa-microservices-template-test.ci.yml +1 -1
- package/.github/workflows/release.cd.yml +1 -0
- package/.vscode/extensions.json +9 -9
- package/.vscode/settings.json +20 -4
- package/CHANGELOG.md +363 -1
- package/CLI-HELP.md +975 -1061
- package/README.md +190 -348
- package/bin/build.js +102 -125
- package/bin/build.template.js +33 -0
- package/bin/cyberia.js +238 -56
- package/bin/deploy.js +16 -3
- package/bin/index.js +238 -56
- package/bump.config.js +26 -0
- package/conf.js +131 -24
- package/deployment.yaml +76 -2
- package/hardhat/package-lock.json +113 -144
- package/hardhat/package.json +4 -3
- package/manifests/cronjobs/dd-cron/dd-cron-backup.yaml +2 -2
- package/manifests/cronjobs/dd-cron/dd-cron-dns.yaml +1 -1
- package/manifests/deployment/dd-cyberia-development/deployment.yaml +76 -2
- package/manifests/deployment/dd-default-development/deployment.yaml +2 -2
- package/manifests/kind-config-dev.yaml +8 -0
- package/manifests/lxd/lxd-admin-profile.yaml +12 -3
- package/manifests/mongodb/pv-pvc.yaml +44 -8
- package/manifests/mongodb/statefulset.yaml +55 -68
- package/manifests/mongodb-4.4/headless-service.yaml +10 -0
- package/manifests/mongodb-4.4/kustomization.yaml +3 -1
- package/manifests/mongodb-4.4/mongodb-nodeport.yaml +17 -0
- package/manifests/mongodb-4.4/pv-pvc.yaml +10 -14
- package/manifests/mongodb-4.4/statefulset.yaml +79 -0
- package/manifests/mongodb-4.4/storage-class.yaml +9 -0
- package/manifests/valkey/statefulset.yaml +1 -1
- package/manifests/valkey/valkey-nodeport.yaml +17 -0
- package/package.json +31 -19
- package/scripts/ipxe-setup.sh +52 -49
- package/scripts/k3s-node-setup.sh +81 -46
- package/scripts/link-local-underpost-cli.sh +6 -0
- package/scripts/lxd-vm-setup.sh +193 -8
- package/scripts/maas-nat-firewalld.sh +145 -0
- package/scripts/test-monitor.sh +250 -0
- package/src/api/atlas-sprite-sheet/atlas-sprite-sheet.router.js +38 -33
- package/src/api/atlas-sprite-sheet/atlas-sprite-sheet.service.js +16 -16
- package/src/api/core/core.router.js +19 -14
- package/src/api/core/core.service.js +5 -5
- package/src/api/crypto/crypto.router.js +18 -12
- package/src/api/crypto/crypto.service.js +3 -3
- package/src/api/cyberia-action/cyberia-action.model.js +1 -1
- package/src/api/cyberia-action/cyberia-action.router.js +22 -18
- package/src/api/cyberia-action/cyberia-action.service.js +5 -5
- package/src/api/cyberia-client-hints/cyberia-client-hints.controller.js +74 -0
- package/src/api/cyberia-client-hints/cyberia-client-hints.model.js +99 -0
- package/src/api/cyberia-client-hints/cyberia-client-hints.router.js +98 -0
- package/src/api/cyberia-client-hints/cyberia-client-hints.service.js +152 -0
- package/src/api/cyberia-dialogue/cyberia-dialogue.router.js +25 -20
- package/src/api/cyberia-dialogue/cyberia-dialogue.service.js +6 -6
- package/src/api/cyberia-entity/cyberia-entity.router.js +22 -18
- package/src/api/cyberia-entity/cyberia-entity.service.js +5 -5
- package/src/api/cyberia-instance/cyberia-fallback-world.js +79 -4
- package/src/api/cyberia-instance/cyberia-instance.router.js +57 -52
- package/src/api/cyberia-instance/cyberia-instance.service.js +10 -10
- package/src/api/cyberia-instance/cyberia-world-generator.js +3 -3
- package/src/api/cyberia-instance-conf/cyberia-instance-conf.model.js +14 -48
- package/src/api/cyberia-instance-conf/cyberia-instance-conf.router.js +22 -18
- package/src/api/cyberia-instance-conf/cyberia-instance-conf.service.js +5 -5
- package/src/api/cyberia-map/cyberia-map.router.js +35 -30
- package/src/api/cyberia-map/cyberia-map.service.js +7 -7
- package/src/api/cyberia-quest/cyberia-quest.model.js +1 -1
- package/src/api/cyberia-quest/cyberia-quest.router.js +22 -18
- package/src/api/cyberia-quest/cyberia-quest.service.js +5 -5
- package/src/api/cyberia-quest-progress/cyberia-quest-progress.router.js +22 -18
- package/src/api/cyberia-quest-progress/cyberia-quest-progress.service.js +5 -5
- package/src/api/cyberia-server-defaults/cyberia-server-defaults.js +458 -0
- package/src/api/default/default.router.js +22 -18
- package/src/api/default/default.service.js +5 -5
- package/src/api/document/document.router.js +28 -23
- package/src/api/document/document.service.js +100 -23
- package/src/api/file/file.router.js +19 -13
- package/src/api/file/file.service.js +9 -7
- package/src/api/instance/instance.router.js +29 -24
- package/src/api/instance/instance.service.js +6 -6
- package/src/api/ipfs/ipfs.router.js +21 -16
- package/src/api/ipfs/ipfs.service.js +8 -8
- package/src/api/object-layer/object-layer.router.js +512 -507
- package/src/api/object-layer/object-layer.service.js +17 -14
- package/src/api/object-layer-render-frames/object-layer-render-frames.router.js +22 -18
- package/src/api/object-layer-render-frames/object-layer-render-frames.service.js +5 -5
- package/src/api/test/test.router.js +17 -12
- package/src/api/types.js +24 -0
- package/src/api/user/guest.service.js +5 -4
- package/src/api/user/user.router.js +297 -288
- package/src/api/user/user.service.js +100 -35
- package/src/cli/baremetal.js +132 -101
- package/src/cli/cluster.js +700 -232
- package/src/cli/db.js +59 -60
- package/src/cli/deploy.js +291 -294
- package/src/cli/env.js +1 -4
- package/src/cli/fs.js +13 -3
- package/src/cli/image.js +58 -4
- package/src/cli/index.js +127 -15
- package/src/cli/ipfs.js +4 -6
- package/src/cli/kubectl.js +4 -1
- package/src/cli/lxd.js +1099 -223
- package/src/cli/monitor.js +396 -9
- package/src/cli/release.js +355 -146
- package/src/cli/repository.js +169 -30
- package/src/cli/run.js +347 -117
- package/src/cli/secrets.js +11 -2
- package/src/cli/test.js +9 -3
- package/src/client/Default.index.js +9 -3
- package/src/client/components/core/Auth.js +5 -0
- package/src/client/components/core/ClientEvents.js +76 -0
- package/src/client/components/core/EventBus.js +4 -0
- package/src/client/components/core/Modal.js +82 -41
- package/src/client/components/core/PanelForm.js +14 -10
- package/src/client/components/core/Worker.js +162 -363
- package/src/client/components/cyberia/MapEngineCyberia.js +1 -1
- package/src/client/components/cyberia/SharedDefaultsCyberia.js +330 -0
- package/src/client/public/cyberia-docs/ACTION-SYSTEM.md +55 -1
- package/src/client/public/cyberia-docs/ARCHITECTURE.md +223 -361
- package/src/client/public/cyberia-docs/CYBERIA-CLI.md +114 -327
- package/src/client/public/cyberia-docs/CYBERIA-CLIENT.md +200 -222
- package/src/client/public/cyberia-docs/CYBERIA-SERVER.md +212 -185
- package/src/client/public/cyberia-docs/CYBERIA.md +259 -0
- package/src/client/public/cyberia-docs/OFF-CHAIN-ECONOMY.md +2 -2
- package/src/client/public/cyberia-docs/QUEST-SYSTEM.md +23 -1
- package/src/client/public/cyberia-docs/ROADMAP.md +1 -1
- package/src/client/public/cyberia-docs/UNDERPOST-PLATFORM.md +106 -0
- package/src/client/public/cyberia-docs/WHITE-PAPER.md +1 -1
- package/src/client/services/cyberia-client-hints/cyberia-client-hints.service.js +99 -0
- package/src/client/ssr/views/CyberiaServerMetrics.js +982 -0
- package/src/client/sw/core.sw.js +174 -112
- package/src/db/DataBaseProvider.js +115 -15
- package/src/db/mariadb/MariaDB.js +2 -1
- package/src/db/mongo/MongoBootstrap.js +657 -0
- package/src/db/mongo/MongooseDB.js +130 -21
- package/src/grpc/cyberia/grpc-server.js +25 -57
- package/src/index.js +1 -1
- package/src/runtime/cyberia-client/Dockerfile +10 -7
- package/src/runtime/cyberia-client/Dockerfile.dev +67 -0
- package/src/runtime/cyberia-server/Dockerfile +11 -6
- package/src/runtime/cyberia-server/Dockerfile.dev +47 -0
- package/src/runtime/express/Express.js +2 -2
- package/src/runtime/wp/Dockerfile +3 -3
- package/src/runtime/wp/Wp.js +8 -5
- package/src/server/auth.js +2 -2
- package/src/server/catalog-underpost.js +61 -0
- package/src/server/catalog.js +77 -0
- package/src/server/client-build-docs.js +1 -1
- package/src/server/client-build.js +94 -129
- package/src/server/conf.js +496 -135
- package/src/server/ipfs-client.js +5 -3
- package/src/server/process.js +180 -19
- package/src/server/proxy.js +9 -2
- package/src/server/runtime-status.js +235 -0
- package/src/server/runtime.js +1 -1
- package/src/server/start.js +44 -11
- package/src/server/valkey.js +2 -0
- package/src/ws/IoInterface.js +16 -16
- package/src/ws/core/channels/core.ws.chat.js +11 -11
- package/src/ws/core/channels/core.ws.mailer.js +29 -29
- package/src/ws/core/channels/core.ws.stream.js +19 -19
- package/src/ws/core/core.ws.connection.js +8 -8
- package/src/ws/core/core.ws.server.js +6 -5
- package/src/ws/default/channels/default.ws.main.js +10 -10
- package/src/ws/default/default.ws.connection.js +4 -4
- package/src/ws/default/default.ws.server.js +4 -3
- package/test/deploy-monitor.test.js +251 -0
- package/bin/file.js +0 -202
- package/bin/vs.js +0 -74
- package/bin/zed.js +0 -84
- package/manifests/deployment/dd-test-development/deployment.yaml +0 -254
- package/manifests/deployment/dd-test-development/proxy.yaml +0 -102
- package/src/api/cyberia-instance-conf/cyberia-instance-conf.defaults.js +0 -574
- package/src/client/components/cyberia-portal/CommonCyberiaPortal.js +0 -467
- package/src/client/ssr/email/DefaultRecoverEmail.js +0 -21
- package/src/client/ssr/email/DefaultVerifyEmail.js +0 -17
- package/src/client/ssr/pages/CyberiaServerMetrics.js +0 -461
- /package/src/client/ssr/{offline → views}/Maintenance.js +0 -0
- /package/src/client/ssr/{offline → views}/NoNetworkConnection.js +0 -0
- /package/src/client/ssr/{pages → views}/Test.js +0 -0
|
@@ -1,417 +1,204 @@
|
|
|
1
|
-
<p align="center">
|
|
2
|
-
<img src="https://www.cyberiaonline.com/assets/splash/apple-touch-icon-precomposed.png" alt="CYBERIA Network Object Layer Engine"/>
|
|
3
|
-
</p>
|
|
4
|
-
|
|
5
|
-
<div align="center">
|
|
6
|
-
|
|
7
|
-
### CYBERIA
|
|
8
|
-
|
|
9
|
-
**Network Object Layers**
|
|
10
|
-
|
|
11
|
-
_Stackable Rendering Layers as a Unified Tokenized Reality_
|
|
12
|
-
|
|
13
|
-
[](https://www.npmjs.org/package/cyberia)
|
|
14
|
-
|
|
15
|
-
</div>
|
|
16
|
-
|
|
17
1
|
# Cyberia CLI
|
|
18
2
|
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
## Overview
|
|
24
|
-
|
|
25
|
-
The Cyberia CLI (`cyberia`) is an extension of the **Underpost CLI** specifically for the Cyberia MMORPG ecosystem. Underpost is the end-to-end bare-metal infrastructure platform for general-purpose applications; `cyberia` extends it with tooling for the game's content pipeline, economy, and MMO engine toolchain. Unrecognized commands are transparently passed through to `underpost` for infrastructure operations.
|
|
26
|
-
|
|
27
|
-
The CLI manages:
|
|
28
|
-
|
|
29
|
-
- **Object Layer (`ol`)** — import, generate, and manage game item definitions and sprite atlases.
|
|
30
|
-
- **Instance (`instance`)** — export/import/seed game instance data (maps, entities, configs).
|
|
31
|
-
- **Chain (`chain`)** — Hyperledger Besu deployment and ERC-1155 ObjectLayerToken lifecycle.
|
|
32
|
-
- **Run-Workflow (`run-workflow`)** — execute named operational scripts (seed defaults, build manifests).
|
|
33
|
-
|
|
34
|
-
---
|
|
3
|
+
`cyberia` (`bin/cyberia.js`) is the Cyberia-specific extension layer on top of the `underpost` CLI. Use
|
|
4
|
+
it for MMO content and extension workflows; use `underpost` for the shared platform, deployment, and
|
|
5
|
+
infrastructure surface. Unrecognized commands pass through to `underpost`.
|
|
35
6
|
|
|
36
|
-
|
|
7
|
+
This page is intentionally command-first: keep it aligned with the shipped CLI surface and avoid
|
|
8
|
+
repeating architecture prose unless it changes command behavior.
|
|
37
9
|
|
|
38
10
|
```bash
|
|
39
11
|
node bin/cyberia.js <command> [subcommand] [options]
|
|
40
|
-
# or
|
|
12
|
+
# or, installed globally:
|
|
41
13
|
cyberia <command> [subcommand] [options]
|
|
42
14
|
```
|
|
43
15
|
|
|
16
|
+
| Command | Purpose |
|
|
17
|
+
| -------------- | --------------------------------------------------------------------- |
|
|
18
|
+
| `ol` | object-layer content import, procedural generation, atlas/sprite work |
|
|
19
|
+
| `instance` | export / import / drop a Cyberia instance and its related documents |
|
|
20
|
+
| `client-hints` | per-instance presentation hints (palette, camera, status icons) |
|
|
21
|
+
| `chain` | Hyperledger Besu network + ERC-1155 `ObjectLayerToken` lifecycle |
|
|
22
|
+
| `run-workflow` | named operational scripts (seed defaults, build manifests/dashboard) |
|
|
23
|
+
|
|
24
|
+
Most data commands resolve the target DB from `DEFAULT_DEPLOY_ID` / `DEFAULT_DEPLOY_HOST` /
|
|
25
|
+
`DEFAULT_DEPLOY_PATH` in the `--env-path` file (default `./.env`). `--dev` forces the deploy's
|
|
26
|
+
`.env.development` (localhost IPFS, etc.); `--mongo-host` overrides the Mongo host.
|
|
27
|
+
|
|
44
28
|
---
|
|
45
29
|
|
|
46
|
-
## `cyberia ol` —
|
|
30
|
+
## `cyberia ol` — object layer
|
|
47
31
|
|
|
48
|
-
|
|
32
|
+
Import PNG assets, generate procedural layers, build atlas sprite sheets, push to IPFS + MongoDB.
|
|
49
33
|
|
|
50
34
|
```bash
|
|
51
35
|
cyberia ol [item-id] [options]
|
|
52
36
|
```
|
|
53
37
|
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
|
57
|
-
|
|
|
58
|
-
| `--
|
|
59
|
-
| `--
|
|
60
|
-
| `--
|
|
61
|
-
| `--count <n>`
|
|
62
|
-
| `--
|
|
63
|
-
| `--frame
|
|
64
|
-
| `--
|
|
65
|
-
| `--
|
|
66
|
-
| `--
|
|
67
|
-
| `--
|
|
68
|
-
| `--show-frame [dir_frame]` | View a single frame (e.g. `08_0`; default: `08_0`) |
|
|
69
|
-
| `--drop` | Drop existing data before importing |
|
|
70
|
-
| `--client-public` | With `--drop`: also remove static client asset folders |
|
|
71
|
-
| `--git-clean` | With `--drop`: run clean on the cyberia asset directory |
|
|
72
|
-
| `--dev` | Force development env (uses `.env.development` for localhost IPFS) |
|
|
73
|
-
| `--env-path <path>` | Path to `.env` file (e.g. `./engine-private/conf/dd-cyberia/.env.development`) |
|
|
74
|
-
| `--mongo-host <host>` | MongoDB host override |
|
|
75
|
-
| `--storage-file-path <path>` | Storage filter JSON path override |
|
|
76
|
-
|
|
77
|
-
### Examples
|
|
38
|
+
| Option | Description |
|
|
39
|
+
| ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------ |
|
|
40
|
+
| `--import` | Import specific item-id(s), comma-separated, from the asset directory |
|
|
41
|
+
| `--import-types [types]` | Batch import by type (e.g. `skin,floors`) or `all` |
|
|
42
|
+
| `--generate` | Generate procedural layers from a semantic item-id (e.g. `floor-desert`) |
|
|
43
|
+
| `--count <n>` / `--density <0..1>` | Shape count multiplier (default `3`) / density (default `0.5`) |
|
|
44
|
+
| `--seed <seed>` | Deterministic seed for `--generate` (e.g. `fx-42`) |
|
|
45
|
+
| `--frame-index <n>` / `--frame-count <n>` | Start frame (default `0`) / frame count (default `1`) |
|
|
46
|
+
| `--to-atlas-sprite-sheet [dim]` | Build a consolidated atlas PNG for the item |
|
|
47
|
+
| `--show-frame [dir_frame]` | View one frame (e.g. `08_0`; default `08_0`) |
|
|
48
|
+
| `--show-atlas-sprite-sheet` | Display the atlas PNG for the item |
|
|
49
|
+
| `--drop` | Drop existing data before importing (or standalone) |
|
|
50
|
+
| `--client-public` / `--git-clean` | With `--drop`: also remove static asset folders / run clean |
|
|
51
|
+
| `--env-path <path>` · `--mongo-host <host>` · `--dev` · `--storage-file-path <path>` | env / DB / dev / filter overrides |
|
|
78
52
|
|
|
79
53
|
```bash
|
|
80
|
-
# Import
|
|
81
|
-
cyberia ol hatchet --import --env-path ./engine-private/conf/dd-cyberia/.env.development
|
|
54
|
+
# Import specific items
|
|
55
|
+
cyberia ol hatchet,sword --import --env-path ./engine-private/conf/dd-cyberia/.env.development
|
|
82
56
|
|
|
83
|
-
#
|
|
84
|
-
cyberia ol --import-types skin,
|
|
85
|
-
|
|
86
|
-
# Import all types
|
|
57
|
+
# Batch import by type, or everything
|
|
58
|
+
cyberia ol --import-types skin,floors
|
|
87
59
|
cyberia ol --import-types all
|
|
88
60
|
|
|
89
|
-
#
|
|
61
|
+
# Procedural generation
|
|
90
62
|
cyberia ol floor-desert --generate --seed fx-42
|
|
63
|
+
cyberia ol floor-grass --generate --frame-count 4 --count 5 --density 0.7
|
|
91
64
|
|
|
92
|
-
#
|
|
93
|
-
cyberia ol floor-grass --generate --frame-count 4 --count 5 --density 0.7
|
|
94
|
-
|
|
95
|
-
# Generate a character skin
|
|
96
|
-
cyberia ol skin-dark-001 --generate --seed my-seed
|
|
97
|
-
|
|
98
|
-
# View a specific frame of an item
|
|
99
|
-
cyberia ol hatchet --show-frame 08_0
|
|
100
|
-
|
|
101
|
-
# Rebuild atlas sprite sheet for an item
|
|
65
|
+
# Atlas / inspect
|
|
102
66
|
cyberia ol hatchet --to-atlas-sprite-sheet
|
|
67
|
+
cyberia ol hatchet --show-frame 08_0
|
|
103
68
|
|
|
104
|
-
# Drop
|
|
105
|
-
cyberia ol hatchet --drop --import
|
|
106
|
-
```
|
|
107
|
-
|
|
108
|
-
---
|
|
109
|
-
|
|
110
|
-
## Semantic Item-ID Registry
|
|
111
|
-
|
|
112
|
-
The `--generate` flag uses item-id prefixes to look up a procedural descriptor from the semantic registry.
|
|
113
|
-
|
|
114
|
-
### Floor Prefixes
|
|
115
|
-
|
|
116
|
-
| Prefix | Biome | Description |
|
|
117
|
-
| -------------- | ------ | ----------------------------------------------- |
|
|
118
|
-
| `floor-desert` | Desert | Sandy, arid tile with warm yellow/brown palette |
|
|
119
|
-
| `floor-grass` | Grass | Meadow tile with green/earth tones |
|
|
120
|
-
| `floor-water` | Water | Ocean/lake tile with blue/teal palette |
|
|
121
|
-
| `floor-stone` | Stone | Rock/cobble tile with grey palette |
|
|
122
|
-
| `floor-lava` | Lava | Magma tile with red/orange palette |
|
|
123
|
-
|
|
124
|
-
### Skin Prefixes
|
|
125
|
-
|
|
126
|
-
| Prefix | Description |
|
|
127
|
-
| -------------- | ----------------------------------------------- |
|
|
128
|
-
| `skin-random` | Fully random skin tone and hair |
|
|
129
|
-
| `skin-dark` | Dark skin tones |
|
|
130
|
-
| `skin-light` | Light / pale skin tones |
|
|
131
|
-
| `skin-vivid` | Vivid / exotic hair colours (blue, red, green…) |
|
|
132
|
-
| `skin-natural` | Natural hair colours (brown, blond, grey…) |
|
|
133
|
-
| `skin-shaved` | Shaved / bald head — no hair |
|
|
134
|
-
|
|
135
|
-
### Resource Prefixes
|
|
136
|
-
|
|
137
|
-
Resource prefixes follow the pattern `resource-{biome}-{shape}`:
|
|
138
|
-
|
|
139
|
-
| Shape Family | Description |
|
|
140
|
-
| ------------ | -------------------------------------- |
|
|
141
|
-
| `petal` | Parabolic arc shapes — coloured petals |
|
|
142
|
-
| `stone` | Hard, angular mineral shapes |
|
|
143
|
-
| `polygon` | Crystal/geometric faceted shapes |
|
|
144
|
-
| `thread` | Thin, wispy Bézier lines |
|
|
145
|
-
|
|
146
|
-
**Biomes:** `desert`, `grass`, `water`, `stone`, `lava`
|
|
147
|
-
|
|
148
|
-
**Full matrix (20 prefixes):**
|
|
149
|
-
|
|
150
|
-
```
|
|
151
|
-
resource-desert-petal resource-grass-petal resource-water-petal
|
|
152
|
-
resource-desert-stone resource-grass-stone resource-water-stone
|
|
153
|
-
resource-desert-polygon resource-grass-polygon resource-water-polygon
|
|
154
|
-
resource-desert-thread resource-grass-thread resource-water-thread
|
|
155
|
-
|
|
156
|
-
resource-stone-petal resource-lava-petal
|
|
157
|
-
resource-stone-stone resource-lava-stone
|
|
158
|
-
resource-stone-polygon resource-lava-polygon
|
|
159
|
-
resource-stone-thread resource-lava-thread
|
|
69
|
+
# Drop + re-import a single item, including static folders
|
|
70
|
+
cyberia ol hatchet --drop --client-public --import
|
|
160
71
|
```
|
|
161
72
|
|
|
162
73
|
---
|
|
163
74
|
|
|
164
|
-
## `cyberia instance` —
|
|
75
|
+
## `cyberia instance` — instance data
|
|
165
76
|
|
|
166
|
-
|
|
77
|
+
Export / import / drop a game instance and its related maps, entities, actions, quests, and object
|
|
78
|
+
layers in MongoDB.
|
|
167
79
|
|
|
168
80
|
```bash
|
|
169
81
|
cyberia instance [instance-code] [options]
|
|
170
82
|
```
|
|
171
83
|
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
|
175
|
-
|
|
|
176
|
-
| `--
|
|
177
|
-
| `--
|
|
178
|
-
| `--
|
|
179
|
-
| `--drop` | Drop all documents associated with the instance code |
|
|
180
|
-
| `--env-path <path>` | Path to `.env` file |
|
|
181
|
-
| `--mongo-host <host>` | MongoDB host override |
|
|
182
|
-
| `--dev` | Force development environment |
|
|
183
|
-
|
|
184
|
-
### Examples
|
|
84
|
+
| Option | Description |
|
|
85
|
+
| ----------------------------------------------------- | ----------------------------------------------------------------------- |
|
|
86
|
+
| `--export [path]` | Export instance and related documents to a backup directory |
|
|
87
|
+
| `--import [path]` | Import from a backup directory (upsert, preserves UUIDs) |
|
|
88
|
+
| `--conf` | With `--export`/`--import`: only `cyberia-instance.json` + `-conf.json` |
|
|
89
|
+
| `--drop` | Drop all documents associated with the instance code |
|
|
90
|
+
| `--env-path <path>` · `--mongo-host <host>` · `--dev` | env / DB / dev overrides |
|
|
185
91
|
|
|
186
92
|
```bash
|
|
187
|
-
|
|
188
|
-
cyberia instance
|
|
189
|
-
|
|
190
|
-
# Import instance from backup
|
|
191
|
-
cyberia instance cyberia-main --import ./backups/cyberia-main
|
|
192
|
-
|
|
193
|
-
# Drop instance data
|
|
194
|
-
cyberia instance cyberia-main --drop
|
|
93
|
+
cyberia instance FOREST --export ./backups/FOREST
|
|
94
|
+
cyberia instance FOREST --import ./backups/FOREST
|
|
95
|
+
cyberia instance FOREST --drop
|
|
195
96
|
```
|
|
196
97
|
|
|
197
98
|
---
|
|
198
99
|
|
|
199
|
-
## `cyberia
|
|
200
|
-
|
|
201
|
-
Full lifecycle management for the Hyperledger Besu network and `ObjectLayerToken` ERC-1155 contract.
|
|
202
|
-
|
|
203
|
-
### Network Commands
|
|
100
|
+
## `cyberia client-hints` — presentation hints
|
|
204
101
|
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
Deploy a new Hyperledger Besu IBFT2 network to Kubernetes:
|
|
208
|
-
|
|
209
|
-
```bash
|
|
210
|
-
cyberia chain deploy [options]
|
|
211
|
-
```
|
|
212
|
-
|
|
213
|
-
| Option | Default | Description |
|
|
214
|
-
| ------------------------ | -------------------------- | ----------------------------------------- |
|
|
215
|
-
| `--validators <n>` | `4` | Number of IBFT2 validators |
|
|
216
|
-
| `--chain-id <id>` | `777771` | EVM chain ID |
|
|
217
|
-
| `--block-period <s>` | `5` | IBFT2 block period in seconds |
|
|
218
|
-
| `--epoch-length <n>` | `30000` | IBFT2 epoch length |
|
|
219
|
-
| `--besu-image <img>` | `hyperledger/besu:24.12.1` | Besu container image |
|
|
220
|
-
| `--node-port-rpc <port>` | `30545` | Kubernetes NodePort for JSON-RPC |
|
|
221
|
-
| `--node-port-ws <port>` | `30546` | Kubernetes NodePort for WebSocket |
|
|
222
|
-
| `--namespace <ns>` | `besu` | Kubernetes namespace |
|
|
223
|
-
| `--pull-image` | — | Pull Besu images before deploying |
|
|
224
|
-
| `--skip-generate` | — | Use existing `manifests/besu/` as-is |
|
|
225
|
-
| `--skip-wait` | — | Skip waiting for validators to be Running |
|
|
226
|
-
|
|
227
|
-
#### `cyberia chain remove`
|
|
228
|
-
|
|
229
|
-
Remove the Besu network from Kubernetes:
|
|
102
|
+
Manage the per-instance `CyberiaClientHints` document (palette, camera, status icons, interpolation).
|
|
103
|
+
These are presentation overrides only — never an instance or server identifier.
|
|
230
104
|
|
|
231
105
|
```bash
|
|
232
|
-
cyberia
|
|
106
|
+
cyberia client-hints [instance-code] [options]
|
|
233
107
|
```
|
|
234
108
|
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
109
|
+
| Option | Description |
|
|
110
|
+
| ----------------------------------------------------- | ----------------------------------------------- |
|
|
111
|
+
| `--seed-defaults` | Upsert canonical presentation-hint defaults |
|
|
112
|
+
| `--export [path]` | Export the hints document to JSON |
|
|
113
|
+
| `--import [path]` | Upsert hints from a JSON file |
|
|
114
|
+
| `--drop` | Remove the hints document for the instance code |
|
|
115
|
+
| `--env-path <path>` · `--mongo-host <host>` · `--dev` | env / DB / dev overrides |
|
|
238
116
|
|
|
239
117
|
```bash
|
|
240
|
-
cyberia
|
|
118
|
+
cyberia client-hints cyberia-main --seed-defaults
|
|
119
|
+
cyberia client-hints cyberia-main --export ./client-hints-cyberia-main.json
|
|
241
120
|
```
|
|
242
121
|
|
|
243
122
|
---
|
|
244
123
|
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
#### `cyberia chain compile`
|
|
248
|
-
|
|
249
|
-
Compile the Solidity contracts:
|
|
250
|
-
|
|
251
|
-
```bash
|
|
252
|
-
cyberia chain compile
|
|
253
|
-
```
|
|
124
|
+
## `cyberia chain` — Besu + ObjectLayerToken
|
|
254
125
|
|
|
255
|
-
|
|
126
|
+
Hyperledger Besu IBFT2 network and ERC-1155 `ObjectLayerToken` (CKY) lifecycle.
|
|
256
127
|
|
|
257
|
-
|
|
128
|
+
### Network
|
|
258
129
|
|
|
259
130
|
```bash
|
|
260
|
-
cyberia chain deploy
|
|
131
|
+
cyberia chain deploy [options] # deploy IBFT2 network to Kubernetes
|
|
132
|
+
cyberia chain generate-manifests [opts] # generate manifests without deploying (same options)
|
|
133
|
+
cyberia chain remove [--namespace besu] [--clean-keys] [--clean-manifests]
|
|
261
134
|
```
|
|
262
135
|
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
136
|
+
Key `deploy` options: `--validators <n>` (4) · `--chain-id <id>` (777771) · `--block-period <s>` (5) ·
|
|
137
|
+
`--epoch-length <n>` (30000) · `--besu-image <img>` · `--node-port-rpc <port>` (30545) ·
|
|
138
|
+
`--node-port-ws <port>` (30546) · `--namespace <ns>` (besu) · `--pull-image` · `--skip-generate` ·
|
|
139
|
+
`--skip-wait`.
|
|
266
140
|
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
Run the Hardhat contract test suite:
|
|
141
|
+
### Contract
|
|
270
142
|
|
|
271
143
|
```bash
|
|
144
|
+
cyberia chain compile
|
|
272
145
|
cyberia chain test
|
|
146
|
+
cyberia chain deploy-contract --network besu-k8s # deploys ObjectLayerToken, mints initial CKY
|
|
273
147
|
```
|
|
274
148
|
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
### Key Management
|
|
278
|
-
|
|
279
|
-
#### `cyberia chain key-gen`
|
|
280
|
-
|
|
281
|
-
Generate a new secp256k1 Ethereum key pair for the coinbase deployer account:
|
|
282
|
-
|
|
283
|
-
```bash
|
|
284
|
-
cyberia chain key-gen
|
|
285
|
-
# Output: address + private key + key file written to engine-private/
|
|
286
|
-
```
|
|
287
|
-
|
|
288
|
-
#### `cyberia chain set-coinbase`
|
|
289
|
-
|
|
290
|
-
Set the active coinbase key used for contract deployment and minting:
|
|
149
|
+
### Keys
|
|
291
150
|
|
|
292
151
|
```bash
|
|
152
|
+
cyberia chain key-gen # new secp256k1 deployer key
|
|
293
153
|
cyberia chain set-coinbase --private-key 0xYOUR_KEY
|
|
294
154
|
cyberia chain set-coinbase --from-file ./engine-private/eth-networks/besu/<address>.key.json
|
|
295
155
|
```
|
|
296
156
|
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
### Token Commands
|
|
300
|
-
|
|
301
|
-
#### `cyberia chain register`
|
|
302
|
-
|
|
303
|
-
Register a single Object Layer item on-chain:
|
|
304
|
-
|
|
305
|
-
```bash
|
|
306
|
-
cyberia chain register <item-id> [options]
|
|
307
|
-
```
|
|
308
|
-
|
|
309
|
-
| Option | Default | Description |
|
|
310
|
-
| ---------------------- | ---------- | ----------------------------------------------------- |
|
|
311
|
-
| `--from-db` | — | Resolve canonical IPFS CID from MongoDB (recommended) |
|
|
312
|
-
| `--metadata-cid <cid>` | `""` | Manual CID override (ignored when `--from-db` is set) |
|
|
313
|
-
| `--supply <n>` | `1` | Initial token supply (1 = NFT, >1 = semi-fungible) |
|
|
314
|
-
| `--network <name>` | `besu-k8s` | Hardhat network name |
|
|
315
|
-
| `--env-path <path>` | `./.env` | Path to `.env` file |
|
|
316
|
-
| `--mongo-host <host>` | — | MongoDB host override |
|
|
317
|
-
|
|
318
|
-
```bash
|
|
319
|
-
# Register unique NFT item (non-fungible)
|
|
320
|
-
cyberia chain register legendary-hatchet --from-db --supply 1
|
|
321
|
-
|
|
322
|
-
# Register stackable resource (semi-fungible)
|
|
323
|
-
cyberia chain register gold-ore --from-db --supply 1000000
|
|
324
|
-
```
|
|
325
|
-
|
|
326
|
-
#### `cyberia chain batch-register`
|
|
327
|
-
|
|
328
|
-
Register multiple items in a single batch transaction:
|
|
329
|
-
|
|
330
|
-
```bash
|
|
331
|
-
cyberia chain batch-register --from-db --items '[{"itemId":"wood","supply":500000},{"itemId":"stone","supply":500000}]'
|
|
332
|
-
```
|
|
333
|
-
|
|
334
|
-
#### `cyberia chain mint`
|
|
335
|
-
|
|
336
|
-
Mint additional tokens for an existing token ID:
|
|
337
|
-
|
|
338
|
-
```bash
|
|
339
|
-
cyberia chain mint --token-id 0 --to 0xABCD...1234 --amount 1000000000000000000000
|
|
340
|
-
cyberia chain mint --token-id <tokenId> --to <address> --amount <uint256>
|
|
341
|
-
```
|
|
342
|
-
|
|
343
|
-
#### `cyberia chain balance`
|
|
344
|
-
|
|
345
|
-
Query the token balance of an address:
|
|
346
|
-
|
|
347
|
-
```bash
|
|
348
|
-
cyberia chain balance --address 0xABCD...1234 --token-id 0
|
|
349
|
-
```
|
|
350
|
-
|
|
351
|
-
#### `cyberia chain transfer`
|
|
352
|
-
|
|
353
|
-
Transfer tokens between addresses:
|
|
157
|
+
### Tokens
|
|
354
158
|
|
|
355
159
|
```bash
|
|
160
|
+
cyberia chain register <item-id> --from-db --supply 1 # 1 = NFT, >1 = semi-fungible
|
|
161
|
+
cyberia chain batch-register --from-db --items '[{"itemId":"wood","supply":500000}]'
|
|
162
|
+
cyberia chain mint --token-id 0 --to 0xABCD... --amount 1000000000000000000000
|
|
356
163
|
cyberia chain transfer --from 0x... --to 0x... --token-id 0 --amount 1000
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
Burn tokens from an address:
|
|
362
|
-
|
|
363
|
-
```bash
|
|
364
|
-
cyberia chain burn --token-id 0 --amount 500 --address 0x...
|
|
365
|
-
```
|
|
366
|
-
|
|
367
|
-
#### `cyberia chain status`
|
|
368
|
-
|
|
369
|
-
Query chain and contract status:
|
|
370
|
-
|
|
371
|
-
```bash
|
|
372
|
-
cyberia chain status [--network besu-k8s]
|
|
373
|
-
# Outputs: chain ID, block number, CKY total supply, deployer address, pause state
|
|
374
|
-
```
|
|
375
|
-
|
|
376
|
-
#### `cyberia chain pause` / `cyberia chain unpause`
|
|
377
|
-
|
|
378
|
-
Emergency transfer freeze / resume (owner only):
|
|
379
|
-
|
|
380
|
-
```bash
|
|
381
|
-
cyberia chain pause [--network besu-k8s]
|
|
164
|
+
cyberia chain burn --token-id 0 --address 0x... --amount 500
|
|
165
|
+
cyberia chain balance --address 0xABCD... --token-id 0
|
|
166
|
+
cyberia chain status [--network besu-k8s] # chain id, block, supply, pause state
|
|
167
|
+
cyberia chain pause [--network besu-k8s] # owner-only transfer freeze / resume
|
|
382
168
|
cyberia chain unpause [--network besu-k8s]
|
|
383
169
|
```
|
|
384
170
|
|
|
171
|
+
`--from-db` resolves the canonical IPFS CID from MongoDB (recommended over manual `--metadata-cid`).
|
|
172
|
+
|
|
385
173
|
---
|
|
386
174
|
|
|
387
|
-
## `cyberia run-workflow` —
|
|
175
|
+
## `cyberia run-workflow` — operational scripts
|
|
388
176
|
|
|
389
|
-
|
|
177
|
+
Named scripts from the `scripts/` directory for seeding and build maintenance.
|
|
390
178
|
|
|
391
|
-
| Subcommand | Description
|
|
392
|
-
| ---------------------------- |
|
|
393
|
-
| `import-default-items` | Import
|
|
394
|
-
| `seed-skill-config` | Upsert `DefaultSkillConfig` into `
|
|
395
|
-
| `seed-dialogues` | Upsert `DefaultCyberiaDialogues`
|
|
396
|
-
| `generate-semantic-examples` | Generate procedural
|
|
397
|
-
| `build-manifest` | Build
|
|
179
|
+
| Subcommand | Description |
|
|
180
|
+
| ---------------------------- | ----------------------------------------------------------------------------------- |
|
|
181
|
+
| `import-default-items` | Import default object layers, skill config, dialogues, client-hints to Mongo |
|
|
182
|
+
| `seed-skill-config` | Upsert `DefaultSkillConfig` into a `CyberiaInstance` (`--instance-code`) |
|
|
183
|
+
| `seed-dialogues` | Upsert `DefaultCyberiaDialogues` into the `cyberia-dialogue` collection |
|
|
184
|
+
| `generate-semantic-examples` | Generate one procedural example per registered semantic prefix |
|
|
185
|
+
| `build-manifest` | Build K8s Deployment + Service manifests for mmo-client / mmo-server |
|
|
186
|
+
| `build-server-dashboard` | Build the static cyberia-server metrics/status dashboard (`--dev`, `--output-path`) |
|
|
398
187
|
|
|
399
188
|
```bash
|
|
400
189
|
cyberia run-workflow import-default-items --env-path ./engine-private/conf/dd-cyberia/.env.development
|
|
401
|
-
cyberia run-workflow seed-skill-config --
|
|
190
|
+
cyberia run-workflow seed-skill-config --instance-code default
|
|
191
|
+
cyberia run-workflow generate-semantic-examples
|
|
402
192
|
cyberia run-workflow build-manifest
|
|
193
|
+
cyberia run-workflow build-server-dashboard
|
|
403
194
|
```
|
|
404
195
|
|
|
405
196
|
---
|
|
406
197
|
|
|
407
|
-
##
|
|
408
|
-
|
|
409
|
-
The CLI respects the following environment variables (typically loaded from an `--env-path` file):
|
|
198
|
+
## Operational rules
|
|
410
199
|
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
| `MONGODB_URI` | MongoDB connection string (loaded from conf if not set directly) |
|
|
417
|
-
| `IPFS_API_URL` | IPFS API URL for pinning (e.g. `http://localhost:5001`) |
|
|
200
|
+
- Preserve public CLI entrypoints and command names unless a change is intentionally breaking.
|
|
201
|
+
- Reuse existing helpers for config loading, env resolution, path normalization, and deploy selection.
|
|
202
|
+
- Prefer one source of truth for generated manifests, deploy IDs, runtime choice, and asset metadata.
|
|
203
|
+
- Treat generated artifacts (atlases, manifests, dashboard HTML) as outputs only; never hand-edit them.
|
|
204
|
+
- `engine-private/` is a private external dependency; never assume its contents exist locally.
|