@underpostnet/cyberia 3.3.73 → 3.3.77
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/.env.example +17 -5
- package/.github/workflows/coverall.cyberia.ci.yml +10 -0
- package/.github/workflows/docker-image.cyberia-client.ci.yml +1 -1
- package/.github/workflows/docker-image.cyberia-client.dev.ci.yml +1 -1
- package/.github/workflows/docker-image.cyberia-server.ci.yml +1 -1
- package/.github/workflows/docker-image.cyberia-server.dev.ci.yml +1 -1
- package/.github/workflows/docker-image.engine-cyberia.ci.yml +1 -1
- package/.github/workflows/docker-image.engine-cyberia.dev.ci.yml +1 -1
- package/.github/workflows/engine-cyberia.ci.yml +1 -1
- package/.github/workflows/publish.cyberia.ci.yml +44 -0
- package/AGENTS.md +61 -12
- package/CHANGELOG.md +159 -161
- package/CLI-HELP.md +20 -13
- package/Dockerfile +1 -1
- package/Dockerfile.dev +1 -1
- package/Dockerfile.test +2 -2
- package/README.md +28 -28
- package/bin/build.js +96 -21
- package/bin/cyberia.js +1247 -1373
- package/bin/index.js +1247 -1373
- package/compose.env +17 -5
- package/conf.js +7 -4
- package/deploy/cyberia-client/deploy.sh +10 -11
- package/deploy/cyberia-client/package.sh +0 -1
- package/deploy/cyberia-client/state.sh +3 -2
- package/deploy/cyberia-server/deploy.sh +10 -11
- package/deploy/cyberia-server/package.sh +0 -1
- package/deploy/cyberia-server/state.sh +3 -2
- package/deploy/dd-cyberia/deploy.sh +5 -5
- package/deploy/dd-cyberia/init.sh +15 -14
- package/deploy/dd-cyberia/package.sh +0 -1
- package/deploy/dd-cyberia/state.sh +2 -2
- package/deploy/dd-cyberia/sync-deploy.sh +139 -75
- package/deploy/lib/config.sh +29 -0
- package/deploy/lib/github-actions-logging.sh +92 -76
- package/deploy/lib/host.sh +28 -19
- package/deploy/lib/state.sh +4 -1
- package/deploy/pwa-microservices-template/deploy.sh +10 -8
- package/deploy/release/deploy.sh +0 -2
- package/deployment.yaml +1 -1
- package/docker-compose.yml +23 -17
- package/docs/coverage/cyberia/api/cyberia-instance/cyberia-fallback-capture.js.html +1591 -0
- package/docs/coverage/cyberia/api/cyberia-instance/index.html +116 -0
- package/docs/coverage/cyberia/api/cyberia-server-defaults/cyberia-server-defaults.js.html +4138 -0
- package/docs/coverage/cyberia/api/cyberia-server-defaults/index.html +116 -0
- package/docs/coverage/cyberia/api/object-layer/index.html +116 -0
- package/docs/coverage/cyberia/api/object-layer/object-layer.model.js.html +1393 -0
- package/docs/coverage/cyberia/base.css +362 -0
- package/docs/coverage/cyberia/block-navigation.js +82 -0
- package/docs/coverage/cyberia/favicon.png +0 -0
- package/docs/coverage/cyberia/index.html +161 -0
- package/docs/coverage/cyberia/prettify.css +101 -0
- package/docs/coverage/cyberia/prettify.js +937 -0
- package/docs/coverage/cyberia/projects/cyberia/atlas-sprite-sheet-generator.js.html +1315 -0
- package/docs/coverage/cyberia/projects/cyberia/index.html +176 -0
- package/docs/coverage/cyberia/projects/cyberia/instance-backup.js.html +715 -0
- package/docs/coverage/cyberia/projects/cyberia/instance-data.js.html +2182 -0
- package/docs/coverage/cyberia/projects/cyberia/shape-generator.js.html +3265 -0
- package/docs/coverage/cyberia/projects/cyberia/stat-balance.js.html +328 -0
- package/docs/coverage/cyberia/sort-arrow-sprite.png +0 -0
- package/docs/coverage/cyberia/sorter.js +205 -0
- package/hardhat/package-lock.json +2 -2
- package/hardhat/package.json +1 -1
- package/manifests/cronjobs/dd-cron/dd-cron-backup.yaml +1 -1
- package/manifests/cronjobs/dd-cron/dd-cron-vultr.yaml +1 -1
- package/manifests/deployment/dd-cyberia-development/deployment.yaml +1 -1
- package/manifests/deployment/dd-default-development/deployment.yaml +2 -2
- package/manifests/deployment/mongo-express/deployment.yaml +46 -27
- package/manifests/deployment/mongo-express/kustomization.yaml +9 -0
- package/manifests/deployment/mongo-express/mongo-express-nodeport.yaml +18 -0
- package/manifests/deployment/mongo-express/service.yaml +16 -0
- package/manifests/deployment/mongo-express-no-auth/disable-mongodb-auth.yaml +16 -0
- package/manifests/deployment/mongo-express-no-auth/kustomization.yaml +16 -0
- package/package.json +19 -17
- package/scripts/test-monitor.sh +3 -3
- package/src/api/atlas-sprite-sheet/atlas-sprite-sheet.controller.js +14 -9
- package/src/api/atlas-sprite-sheet/atlas-sprite-sheet.model.js +36 -5
- package/src/api/atlas-sprite-sheet/atlas-sprite-sheet.router.js +5 -0
- package/src/api/atlas-sprite-sheet/atlas-sprite-sheet.service.js +88 -184
- package/src/api/cyberia-action/cyberia-action.router.js +2 -2
- package/src/api/cyberia-action/cyberia-action.service.js +3 -4
- package/src/api/cyberia-audio/cyberia-audio.controller.js +6 -0
- package/src/api/cyberia-audio/cyberia-audio.model.js +61 -0
- package/src/api/cyberia-audio/cyberia-audio.router.js +21 -0
- package/src/api/cyberia-audio/cyberia-audio.service.js +220 -0
- package/src/api/cyberia-client-hints/cyberia-client-hints.controller.js +1 -3
- package/src/api/cyberia-client-hints/cyberia-client-hints.model.js +10 -19
- package/src/api/cyberia-client-hints/cyberia-client-hints.router.js +12 -34
- package/src/api/cyberia-client-hints/cyberia-client-hints.service.js +15 -32
- package/src/api/cyberia-dialogue/cyberia-dialogue.model.js +1 -1
- package/src/api/cyberia-dialogue/cyberia-dialogue.router.js +1 -1
- package/src/api/cyberia-entity/cyberia-entity.model.js +2 -0
- package/src/api/cyberia-entity/cyberia-entity.service.js +1 -1
- package/src/api/cyberia-entity-type-default/cyberia-entity-type-default.controller.js +8 -2
- package/src/api/cyberia-entity-type-default/cyberia-entity-type-default.model.js +31 -20
- package/src/api/cyberia-entity-type-default/cyberia-entity-type-default.router.js +16 -1
- package/src/api/cyberia-entity-type-default/cyberia-entity-type-default.service.js +466 -3
- package/src/api/cyberia-instance/cyberia-fallback-capture.js +87 -51
- package/src/api/cyberia-instance/cyberia-fallback-world.js +21 -40
- package/src/api/cyberia-instance/cyberia-instance-boot.service.js +5 -5
- package/src/api/cyberia-instance/cyberia-instance-items.js +98 -0
- package/src/api/cyberia-instance/cyberia-instance-map.service.js +34 -141
- package/src/api/cyberia-instance/cyberia-instance.controller.js +1 -4
- package/src/api/cyberia-instance/cyberia-instance.model.js +0 -14
- package/src/api/cyberia-instance/cyberia-instance.router.js +3 -16
- package/src/api/cyberia-instance/cyberia-instance.service.js +3 -43
- package/src/api/cyberia-instance/cyberia-world-generator.js +8 -13
- package/src/api/cyberia-instance-conf/cyberia-instance-conf.model.js +49 -75
- package/src/api/cyberia-instance-conf/cyberia-instance-conf.service.js +74 -1
- package/src/api/cyberia-map/cyberia-map.service.js +6 -2
- package/src/api/cyberia-map-audio-conf/cyberia-map-audio-conf.controller.js +31 -0
- package/src/api/cyberia-map-audio-conf/cyberia-map-audio-conf.model.js +56 -0
- package/src/api/cyberia-map-audio-conf/cyberia-map-audio-conf.router.js +33 -0
- package/src/api/cyberia-map-audio-conf/cyberia-map-audio-conf.service.js +189 -0
- package/src/api/cyberia-quest/cyberia-quest.router.js +3 -3
- package/src/api/cyberia-quest/cyberia-quest.service.js +3 -3
- package/src/api/cyberia-quest-progress/cyberia-quest-progress.model.js +1 -1
- package/src/api/cyberia-server-defaults/cyberia-server-defaults.js +403 -188
- package/src/api/cyberia-skill/cyberia-skill.model.js +6 -6
- package/src/api/file/file.ref.js +153 -0
- package/src/api/file/file.ref.json +11 -2
- package/src/api/object-layer/object-layer.model.js +47 -12
- package/src/api/object-layer/object-layer.router.js +10 -3
- package/src/api/object-layer/object-layer.service.js +113 -120
- package/src/cli/app.js +12 -1
- package/src/cli/client.js +2 -2
- package/src/cli/cluster.js +80 -18
- package/src/cli/deploy.js +215 -34
- package/src/cli/docker-compose.js +1 -1
- package/src/cli/fs-selection.js +115 -0
- package/src/cli/fs.js +158 -342
- package/src/cli/index.js +22 -10
- package/src/cli/release.js +3 -1
- package/src/cli/repository.js +35 -9
- package/src/cli/run.js +80 -199
- package/src/cli/test.js +4 -0
- package/src/cli/wireguard.js +32 -31
- package/src/client/components/core/Badge.js +0 -1
- package/src/client/components/core/CssCore.js +8 -1
- package/src/client/components/core/Docs.js +77 -100
- package/src/client/components/core/Modal.js +77 -23
- package/src/client/components/core/ToolTip.js +15 -0
- package/src/client/components/cryptokoyn/AppShellCryptokoyn.js +0 -2
- package/src/client/components/cyberia/ActionEngineCyberia.js +12 -36
- package/src/client/components/cyberia/EntityEngineCyberia.js +492 -121
- package/src/client/components/cyberia/InstanceEngineCyberia.js +129 -160
- package/src/client/components/cyberia/InstanceSelectionView.js +7 -1
- package/src/client/components/cyberia/MapEngineCyberia.js +175 -69
- package/src/client/components/cyberia/ObjectLayerEngine.js +1011 -97
- package/src/client/components/cyberia/ObjectLayerEngineModal.js +81 -155
- package/src/client/components/cyberia/ObjectLayerEngineViewer.js +113 -98
- package/src/client/components/cyberia/SharedDefaultsCyberia.js +215 -56
- package/src/client/components/cyberia-portal/AppShellCyberiaPortal.js +0 -34
- package/src/client/components/cyberia-portal/CssCyberiaPortal.js +1 -1
- package/src/client/components/cyberia-portal/MainBodyCyberiaPortal.js +712 -76
- package/src/client/components/cyberia-portal/RouterCyberiaPortal.js +0 -4
- package/src/client/components/cyberia-portal/TranslateCyberiaPortal.js +0 -4
- package/src/client/components/default/AppShellDefault.js +1 -4
- package/src/client/components/itemledger/AppShellItemledger.js +0 -2
- package/src/client/components/underpost/AppShellUnderpost.js +1 -1
- package/src/client/public/cyberia-docs/ARCHITECTURE.md +15 -15
- package/src/client/public/cyberia-docs/CYBERIA-CLI.md +280 -24
- package/src/client/public/cyberia-docs/CYBERIA-CLIENT.md +51 -29
- package/src/client/public/cyberia-docs/CYBERIA-SAGA.md +52 -53
- package/src/client/public/cyberia-docs/CYBERIA-SERVER.md +16 -11
- package/src/client/public/cyberia-docs/CYBERIA.md +28 -28
- package/src/client/public/cyberia-docs/ENTITY-PROFILE.md +11 -5
- package/src/client/public/cyberia-docs/ROADMAP.md +1 -1
- package/src/client/public/cyberia-docs/STATS-PROGRESSION.md +217 -0
- package/src/client/public/cyberia-docs/WHITE-PAPER.md +20 -12
- package/src/client/services/cyberia-audio/cyberia-audio.service.js +99 -0
- package/src/client/services/cyberia-entity-type-default/cyberia-entity-type-default.service.js +38 -0
- package/src/client/services/cyberia-instance/cyberia-instance.management.js +5 -4
- package/src/client/services/cyberia-instance/cyberia-instance.service.js +0 -40
- package/src/client/services/cyberia-map/cyberia-map.management.js +5 -4
- package/src/client/services/cyberia-map-audio-conf/cyberia-map-audio-conf.service.js +138 -0
- package/src/client/services/object-layer/object-layer.management.js +6 -10
- package/src/client/services/object-layer/object-layer.service.js +3 -1
- package/src/client/ssr/views/Cyberia404.js +3 -3
- package/src/client-builder/client-build-docs.js +52 -52
- package/src/client-builder/client-build.js +67 -44
- package/src/client-builder/client-bundle.js +347 -0
- package/src/db/mongo/MongoExpress.js +187 -0
- package/src/grpc/cyberia/grpc-server.js +5 -7
- package/src/index.js +1 -1
- package/src/projects/cyberia/atlas-sprite-sheet-generator.js +143 -146
- package/src/projects/cyberia/atlas-sprite-sheet-store.js +391 -0
- package/src/projects/cyberia/besu-genesis-generator.js +5 -14
- package/src/projects/cyberia/boot-contract-fixtures.js +32 -0
- package/src/projects/cyberia/catalog-cyberia.js +3 -2
- package/src/projects/cyberia/gemini-client.js +3 -3
- package/src/projects/cyberia/generate-saga.js +4 -11
- package/src/projects/cyberia/hot-reload-trigger.js +17 -28
- package/src/projects/cyberia/instance-backup.js +210 -0
- package/src/projects/cyberia/instance-data.js +177 -257
- package/src/projects/cyberia/map-preview-generator.js +32 -68
- package/src/projects/cyberia/object-layer.js +152 -319
- package/src/projects/cyberia/seed-audio.js +139 -0
- package/src/projects/cyberia/semantic-layer-generator-skin.js +2 -8
- package/src/projects/cyberia/semantic-layer-generator.js +2 -18
- package/src/projects/cyberia/stat-balance.js +81 -0
- package/src/projects/cyberia/stat-commands.js +23 -0
- package/src/projects/cyberia/stat-contract-generator.js +101 -0
- package/src/runtime/cyberia-client/Dockerfile +8 -4
- package/src/runtime/cyberia-client/Dockerfile.dev +5 -2
- package/src/runtime/cyberia-server/Dockerfile +9 -2
- package/src/runtime/cyberia-server/Dockerfile.dev +8 -1
- package/src/runtime/engine-cyberia/Dockerfile +1 -1
- package/src/runtime/engine-cyberia/Dockerfile.dev +1 -1
- package/src/runtime/engine-cyberia/Dockerfile.test +2 -2
- package/src/runtime/engine-cyberia/compose.env +17 -5
- package/src/runtime/engine-cyberia/docker-compose.yml +23 -17
- package/src/server/build/coverage.js +113 -42
- package/src/server/build/package.js +55 -12
- package/src/server/build/testing.js +59 -9
- package/src/server/network/middlewares.js +8 -2
- package/src/server/network/underpost-gateway.js +113 -14
- package/src/server/ops/logger.js +70 -35
- package/src/server/runtime/conf.js +40 -9
- package/src/server/runtime/start.js +11 -2
- package/src/server/storage/data-query.js +16 -0
- package/src/server/storage/downloader.js +62 -14
- package/src/server/storage/zip.js +153 -0
- package/test/integration/app/cyberia/atlas-sprite-sheet-store.test.js +402 -0
- package/test/integration/app/cyberia/atlas-sprite-sheet.test.js +86 -0
- package/test/integration/app/cyberia/cyberia-cli-plain-reads.test.js +34 -0
- package/test/integration/app/cyberia/cyberia-entity-type-default.test.js +842 -0
- package/test/integration/app/cyberia/cyberia-instance-conf-coerce.test.js +53 -0
- package/test/integration/app/cyberia/cyberia-instance-conf-defaults.test.js +16 -22
- package/test/integration/app/cyberia/cyberia-instance-items.test.js +90 -0
- package/test/integration/app/cyberia/cyberia-load.test.js +6 -7
- package/test/integration/app/cyberia/cyberia-map-audio-conf.test.js +256 -0
- package/test/integration/app/cyberia/cyberia-stats.test.js +150 -0
- package/test/integration/app/cyberia/fallback-world-capture.test.js +87 -2
- package/test/integration/app/cyberia/object-layer-item-selection.test.js +56 -0
- package/test/integration/app/cyberia/object-layer-natural-key.test.js +32 -0
- package/test/integration/app/cyberia/seed-audio.test.js +275 -0
- package/test/integration/infra/2-network/wireguard-cli.test.js +33 -9
- package/test/integration/infra/2-network/wireguard-edge.test.js +58 -18
- package/test/integration/infra/3-cluster/mongo-express-deploy.test.js +156 -0
- package/test/integration/infra/4-ingress/api-cross-origin.test.js +79 -0
- package/test/integration/infra/4-ingress/underpost-ingress.test.js +1 -1
- package/test/unit/catalog.test.js +13 -2
- package/test/unit/client-build-docs.test.js +97 -70
- package/test/unit/client-bundle.test.js +313 -0
- package/test/unit/conf-resolution.test.js +58 -7
- package/test/unit/coverage-artifact.test.js +120 -29
- package/test/unit/cyberia/instance-backup.test.js +183 -0
- package/test/unit/cyberia/instance-data.test.js +314 -0
- package/test/unit/cyberia/instance-object-layer-items.test.js +46 -0
- package/test/unit/cyberia/publish-workflow.test.js +22 -0
- package/test/unit/cyberia/stat-balance.test.js +69 -0
- package/test/unit/deploy-legacy-gateway-sweep.test.js +63 -0
- package/test/unit/deploy-log-table.test.js +76 -5
- package/test/unit/downloader-integrity.test.js +98 -0
- package/test/unit/file-reference-registry.test.js +141 -0
- package/test/unit/fs-storage-paths.test.js +596 -0
- package/test/unit/gateway-pod-fetch.test.js +95 -0
- package/test/unit/letsencrypt-issuer.test.js +101 -0
- package/test/unit/logger-redaction.test.js +29 -0
- package/test/unit/package.test.js +70 -16
- package/test/unit/prepare-host.test.js +84 -1
- package/test/unit/release-bump.test.js +3 -1
- package/test/unit/start-options.test.js +12 -0
- package/test/unit/test-tiers.test.js +27 -0
- package/test/unit/zip-archive.test.js +142 -0
- package/vitest.config.js +11 -3
- package/src/api/cyberia-instance/cyberia-fallback-default-items.js +0 -63
- package/src/client/components/cyberia/FallbackWorldEngineCyberia.js +0 -368
|
@@ -1,37 +1,20 @@
|
|
|
1
1
|
# Logging helpers for deploy/<deploy-id>/*.sh. Sourced, never executed directly.
|
|
2
2
|
#
|
|
3
|
-
#
|
|
4
|
-
#
|
|
5
|
-
#
|
|
6
|
-
#
|
|
7
|
-
#
|
|
3
|
+
# Environment read by these helpers, and nothing else:
|
|
4
|
+
# RUN_QUIET_DEBUG Stream every line verbatim: no table, no folding, no dropped traces. For an
|
|
5
|
+
# operator watching a step over SSH who needs the run itself, not a report of
|
|
6
|
+
# it. Wins over the two below, which each hide part of the stream by design.
|
|
7
|
+
# RUN_QUIET_CI Marks stdout as a GitHub Actions log, which folds monitor frames into
|
|
8
|
+
# collapsed sections. The CD workflows export it on the far side of the SSH
|
|
9
|
+
# hop because GITHUB_ACTIONS is runner-local and does not travel; a remote
|
|
10
|
+
# deploy has no other way to know. `underpost state publish` reads the same
|
|
11
|
+
# pair to choose workflow commands over JSON.
|
|
12
|
+
# RUN_QUIET_PLAIN No colour, no cursor motion, no folding: frames stream as they arrive.
|
|
13
|
+
# NO_COLOR Colour off, the usual convention. Everything else is unaffected.
|
|
8
14
|
#
|
|
9
|
-
#
|
|
10
|
-
#
|
|
11
|
-
|
|
12
|
-
#
|
|
13
|
-
# run_quiet hides normal output and returns the command's exit status so
|
|
14
|
-
# `set -e` stops the deployment. Lines matching `patterns` that parse as a
|
|
15
|
-
# deployment pod report are folded into a table — one row per pod, three columns
|
|
16
|
-
# wide — instead of being streamed; the monitor's raw `deploy-monitor` JSON emits
|
|
17
|
-
# are consumed into that table's cells rather than printed. The monitor
|
|
18
|
-
# iteration and its clock are per frame, not per pod, so they title the table
|
|
19
|
-
# rather than repeating down a column of every row. Anything else within
|
|
20
|
-
# `lines_after` lines of a match scrolls above the table. On failure it keeps
|
|
21
|
-
# two temp files and prints their paths in red instead of their contents: the
|
|
22
|
-
# error trace and the full unfiltered log up to the error. The trace is stderr
|
|
23
|
-
# plus the failing tail of the merged log, because the engine CLI reports through
|
|
24
|
-
# its logger and that writes to stdout — stderr alone routinely holds nothing but
|
|
25
|
-
# git progress output.
|
|
26
|
-
#
|
|
27
|
-
# The table renders three ways, because a log viewer is not a terminal:
|
|
28
|
-
# - terminal: redrawn in place, cursor relative, one frame at a time
|
|
29
|
-
# - CI (GITHUB_ACTIONS/RUN_QUIET_CI): no cursor addressing exists there, so the
|
|
30
|
-
# changed rows stream inside a collapsed `::group::` and the final table is
|
|
31
|
-
# printed after it, expanded
|
|
32
|
-
# - anywhere else: changed rows appended
|
|
33
|
-
# Colour is ANSI SGR only and is emitted in all three (GitHub renders SGR in
|
|
34
|
-
# step logs); NO_COLOR or RUN_QUIET_PLAIN turns it off.
|
|
15
|
+
# Whatever the rendering, the parsing behind it is the same: a step that reports a fatal runtime
|
|
16
|
+
# status fails, including one that exits 0, and including in debug mode.
|
|
17
|
+
|
|
35
18
|
|
|
36
19
|
if [ -n "${NO_COLOR:-}${RUN_QUIET_PLAIN:-}" ]; then
|
|
37
20
|
RUN_QUIET_RED=''
|
|
@@ -41,8 +24,8 @@ else
|
|
|
41
24
|
RUN_QUIET_RESET=$'\033[0m'
|
|
42
25
|
fi
|
|
43
26
|
|
|
44
|
-
|
|
45
|
-
RUN_QUIET_NODE_TAG=${
|
|
27
|
+
RUN_QUIET_NODE_TAG=$(hostname 2>/dev/null | tr '[:upper:]' '[:lower:]')
|
|
28
|
+
RUN_QUIET_NODE_TAG=${RUN_QUIET_NODE_TAG:+ [$RUN_QUIET_NODE_TAG]}
|
|
46
29
|
|
|
47
30
|
# The report pattern and the passthrough window describe the deployment log
|
|
48
31
|
# format, not any one step, so they are declared once here instead of being
|
|
@@ -68,27 +51,37 @@ run_quiet() {
|
|
|
68
51
|
local patterns="$2"
|
|
69
52
|
local lines_after="$3"
|
|
70
53
|
shift 3
|
|
71
|
-
|
|
54
|
+
|
|
72
55
|
local debug_log
|
|
73
56
|
local error_log
|
|
74
57
|
local fail_flag
|
|
75
58
|
local fatal
|
|
76
|
-
local reason
|
|
77
59
|
local fifo_dir
|
|
78
60
|
local filter_pid
|
|
79
61
|
local stderr_pid
|
|
80
62
|
local color=0
|
|
63
|
+
local debug=0
|
|
81
64
|
local groups=0
|
|
82
65
|
local redraw=0
|
|
83
66
|
local width=0
|
|
84
67
|
local rows=0
|
|
85
68
|
local status=0
|
|
86
|
-
|
|
69
|
+
|
|
87
70
|
echo "$RUN_QUIET_NODE_TAG $(date -Is) ▶ $label"
|
|
88
|
-
|
|
71
|
+
|
|
72
|
+
# How a step renders is decided by what its destination can do, not by preference, and the
|
|
73
|
+
# three renderings are mutually exclusive:
|
|
74
|
+
# debug an operator watching over SSH — nothing filtered, folded or overwritten
|
|
75
|
+
# redraw a terminal — one live region, rewritten in place
|
|
76
|
+
# groups a GitHub Actions log — no cursor motion, so frames fold into a collapsed section
|
|
77
|
+
# With none of them the frames simply stream. RUN_QUIET_DEBUG is resolved first because it
|
|
78
|
+
# is the operator asking to see the stream itself, which neither of the others can show: a
|
|
79
|
+
# live region overwrites what came before, and a collapsed section hides it.
|
|
80
|
+
[ -z "${RUN_QUIET_DEBUG:-}" ] || debug=1
|
|
81
|
+
|
|
89
82
|
[ -n "${NO_COLOR:-}${RUN_QUIET_PLAIN:-}" ] || color=1
|
|
90
|
-
|
|
91
|
-
if [ -t 1 ] && [ "${TERM:-dumb}" != dumb ] && [ -z "${RUN_QUIET_PLAIN:-}" ]; then
|
|
83
|
+
|
|
84
|
+
if [ "$debug" -eq 0 ] && [ -t 1 ] && [ "${TERM:-dumb}" != dumb ] && [ -z "${RUN_QUIET_PLAIN:-}" ]; then
|
|
92
85
|
redraw=1
|
|
93
86
|
width=${COLUMNS:-0}
|
|
94
87
|
[ "$width" -gt 0 ] 2>/dev/null || width=$(tput cols 2>/dev/null || echo 0)
|
|
@@ -98,18 +91,22 @@ run_quiet() {
|
|
|
98
91
|
# addresses the table no longer matches the lines it printed.
|
|
99
92
|
[ "$width" -ge 20 ] || redraw=0
|
|
100
93
|
fi
|
|
101
|
-
|
|
102
|
-
|
|
94
|
+
|
|
95
|
+
# GITHUB_ACTIONS exists on a runner but is not carried across the SSH hop a remote deploy runs
|
|
96
|
+
# over, so RUN_QUIET_CI — which the workflows export on the far side — is what actually marks
|
|
97
|
+
# a step whose stdout a GitHub log will render.
|
|
98
|
+
if [ "$debug" -eq 0 ] && [ "$redraw" -eq 0 ] && [ -z "${RUN_QUIET_PLAIN:-}" ] &&
|
|
99
|
+
[ -n "${GITHUB_ACTIONS:-}${RUN_QUIET_CI:-}" ]; then
|
|
103
100
|
groups=1
|
|
104
101
|
fi
|
|
105
|
-
|
|
102
|
+
|
|
106
103
|
debug_log=$(mktemp --suffix=.debug.log)
|
|
107
104
|
error_log=$(mktemp --suffix=.error.log)
|
|
108
105
|
fail_flag=$(mktemp --suffix=.fatal)
|
|
109
106
|
: >"$fail_flag"
|
|
110
107
|
fifo_dir=$(mktemp -d)
|
|
111
108
|
mkfifo "$fifo_dir/merged" "$fifo_dir/stderr"
|
|
112
|
-
|
|
109
|
+
|
|
113
110
|
# The filter reads the live stream rather than the finished log: a deployment
|
|
114
111
|
# monitor prints its report for minutes before exiting, so a pass over the
|
|
115
112
|
# completed file would show nothing until then. fflush defeats awk's block
|
|
@@ -133,6 +130,7 @@ run_quiet() {
|
|
|
133
130
|
-v debug_log="$debug_log" \
|
|
134
131
|
-v redraw="$redraw" \
|
|
135
132
|
-v color="$color" \
|
|
133
|
+
-v debug="$debug" \
|
|
136
134
|
-v groups="$groups" \
|
|
137
135
|
-v label="$label" \
|
|
138
136
|
-v width="$width" \
|
|
@@ -422,7 +420,31 @@ run_quiet() {
|
|
|
422
420
|
# actually moved; the iteration count alone is not a change. The title is
|
|
423
421
|
# reprinted whenever a later iteration is the one moving rows, so a
|
|
424
422
|
# streamed row is still dated without carrying its own clock column.
|
|
423
|
+
# The parsing every rendering shares: it advances the monitor'"'"'s event state machine,
|
|
424
|
+
# records what each pod reported, and latches a fatal runtime status. What a line *is*
|
|
425
|
+
# cannot depend on how the run is being displayed, so this answers only that, and the
|
|
426
|
+
# caller decides what to show.
|
|
427
|
+
function track(line) {
|
|
428
|
+
if (in_json) {
|
|
429
|
+
if (line ~ json_close) {
|
|
430
|
+
in_json = 0
|
|
431
|
+
apply_event()
|
|
432
|
+
} else {
|
|
433
|
+
if (json_value("phase") != "") event_phase = json_value("phase")
|
|
434
|
+
if (json_value("state") != "") event_state = json_value("state")
|
|
435
|
+
if (json_value("status") != "") event_status = json_value("status")
|
|
436
|
+
}
|
|
437
|
+
return "event"
|
|
438
|
+
}
|
|
439
|
+
if (line ~ json_open) {
|
|
440
|
+
in_json = 1
|
|
441
|
+
event_phase = event_state = event_status = ""
|
|
442
|
+
return "event"
|
|
443
|
+
}
|
|
444
|
+
return read_pod_line(line) ? "pod" : "other"
|
|
445
|
+
}
|
|
425
446
|
function append_row(pod, cells) {
|
|
447
|
+
if (debug) return
|
|
426
448
|
cells = pod "|" k8s_cell(pod) "|" runtime_cell(pod)
|
|
427
449
|
if (cells == last_row[pod]) return
|
|
428
450
|
last_row[pod] = cells
|
|
@@ -456,34 +478,30 @@ run_quiet() {
|
|
|
456
478
|
if ($0 !~ /"timestamp"/ && match(strip($0), clock)) last_time = substr(strip($0), RSTART, RLENGTH)
|
|
457
479
|
}
|
|
458
480
|
{
|
|
481
|
+
# DEBUG streams the step verbatim: no table, no group, no passthrough window, and no
|
|
482
|
+
# dropped stack traces — a CI transcript withholds those because it is published,
|
|
483
|
+
# which is not true of the session an operator opened to audit this run. Tracking
|
|
484
|
+
# still runs, so a fatal runtime status latches here exactly as in every other mode
|
|
485
|
+
# and a step that reports one still fails.
|
|
486
|
+
if (debug) {
|
|
487
|
+
track($0)
|
|
488
|
+
put($0)
|
|
489
|
+
next
|
|
490
|
+
}
|
|
459
491
|
if (!handed_off && $0 !~ pattern && ready_pending()) hand_off()
|
|
460
492
|
if (handed_off) {
|
|
461
493
|
if ($0 !~ pattern) next
|
|
462
494
|
reset_table()
|
|
463
495
|
}
|
|
496
|
+
line_kind = track($0)
|
|
464
497
|
# The monitor JSON is state already carried by the table cells: it is
|
|
465
498
|
# consumed here and never reaches the terminal.
|
|
466
|
-
if (
|
|
467
|
-
if ($0 ~ json_close) {
|
|
468
|
-
in_json = 0
|
|
469
|
-
apply_event()
|
|
470
|
-
} else {
|
|
471
|
-
if (json_value("phase") != "") event_phase = json_value("phase")
|
|
472
|
-
if (json_value("state") != "") event_state = json_value("state")
|
|
473
|
-
if (json_value("status") != "") event_status = json_value("status")
|
|
474
|
-
}
|
|
499
|
+
if (line_kind == "event") {
|
|
475
500
|
if (remaining > 0) remaining--
|
|
476
501
|
last_pod_line = 0
|
|
477
502
|
next
|
|
478
503
|
}
|
|
479
|
-
if (
|
|
480
|
-
in_json = 1
|
|
481
|
-
event_phase = event_state = event_status = ""
|
|
482
|
-
if (remaining > 0) remaining--
|
|
483
|
-
last_pod_line = 0
|
|
484
|
-
next
|
|
485
|
-
}
|
|
486
|
-
if (read_pod_line($0)) {
|
|
504
|
+
if (line_kind == "pod") {
|
|
487
505
|
# Pod reports arrive back to back, one per pod, once per monitor
|
|
488
506
|
# iteration: the first of a run opens a new cycle.
|
|
489
507
|
if (!last_pod_line) cycles++
|
|
@@ -511,27 +529,27 @@ run_quiet() {
|
|
|
511
529
|
}
|
|
512
530
|
}
|
|
513
531
|
END {
|
|
514
|
-
if (!handed_off && ready_pending()) hand_off()
|
|
532
|
+
if (!debug && !handed_off && ready_pending()) hand_off()
|
|
515
533
|
close_group()
|
|
516
534
|
}
|
|
517
535
|
' <"$fifo_dir/merged" &
|
|
518
536
|
filter_pid=$!
|
|
519
|
-
|
|
537
|
+
|
|
520
538
|
# stderr is duplicated: on its own for the native error and stack trace, and
|
|
521
539
|
# into the merged stream so both the debug log and the filter see it in
|
|
522
540
|
# chronological order with stdout.
|
|
523
541
|
tee -a "$error_log" <"$fifo_dir/stderr" >"$fifo_dir/merged" &
|
|
524
542
|
stderr_pid=$!
|
|
525
|
-
|
|
543
|
+
|
|
526
544
|
"$@" >"$fifo_dir/merged" 2>"$fifo_dir/stderr" || status=$?
|
|
527
|
-
|
|
545
|
+
|
|
528
546
|
# Drain both readers before the paths are printed, or the trace can still be
|
|
529
547
|
# in flight. Bounded: a command that leaks a child holding a stream open must
|
|
530
548
|
# not hang the deployment, and by then everything read has been written.
|
|
531
549
|
run_quiet_drain "$stderr_pid"
|
|
532
550
|
run_quiet_drain "$filter_pid"
|
|
533
551
|
rm -rf "$fifo_dir"
|
|
534
|
-
|
|
552
|
+
|
|
535
553
|
# A deployment can fail without the command failing. The in-pod lifecycle latches
|
|
536
554
|
# `container-status=error` and deliberately does not crash the container, so a step that
|
|
537
555
|
# reported a fatal runtime state can still exit 0 — and a green step here is a green
|
|
@@ -541,23 +559,21 @@ run_quiet() {
|
|
|
541
559
|
rm -f "$fail_flag"
|
|
542
560
|
if [ "$status" -eq 0 ] && [ -n "$fatal" ]; then
|
|
543
561
|
status=1
|
|
544
|
-
printf '
|
|
545
|
-
|
|
562
|
+
printf -- '--- fatal runtime latch ---\n%s\n' "$fatal" >>"$error_log"
|
|
563
|
+
printf '%s✖ %s reported a fatal runtime state but exited 0%s\n' \
|
|
564
|
+
"$RUN_QUIET_RED" "$label" "$RUN_QUIET_RESET" >&2
|
|
546
565
|
fi
|
|
547
|
-
|
|
566
|
+
|
|
548
567
|
if [ "$status" -ne 0 ]; then
|
|
549
568
|
run_quiet_error_trace "$debug_log" "$error_log"
|
|
550
|
-
# One line of why, never the trace: the filter drops trace lines from the window.
|
|
551
|
-
reason=$(grep -a -m1 -E '^[A-Za-z]*Error: |reported runtime status=' "$debug_log" 2>/dev/null | head -1) || true
|
|
552
569
|
printf '%s✖ %s failed (exit %s)%s\n' "$RUN_QUIET_RED" "$label" "$status" "$RUN_QUIET_RESET" >&2
|
|
553
|
-
[ -n "$reason" ] && printf '%s reason: %s%s\n' "$RUN_QUIET_RED" "$reason" "$RUN_QUIET_RESET" >&2
|
|
554
570
|
printf '%s error trace: %s\n debug log: %s%s\n' \
|
|
555
571
|
"$RUN_QUIET_RED" "$error_log" "$debug_log" "$RUN_QUIET_RESET" >&2
|
|
556
572
|
return "$status"
|
|
557
573
|
fi
|
|
558
|
-
|
|
574
|
+
|
|
559
575
|
rm -f "$debug_log" "$error_log"
|
|
560
|
-
|
|
576
|
+
|
|
561
577
|
return "$status"
|
|
562
578
|
}
|
|
563
579
|
|
|
@@ -570,13 +586,13 @@ run_quiet_error_trace() {
|
|
|
570
586
|
local error_log="$2"
|
|
571
587
|
local tail_lines="${3:-40}"
|
|
572
588
|
local first
|
|
573
|
-
|
|
589
|
+
|
|
574
590
|
# grep exits 1 when it matches nothing, and every deploy script runs under `set -e` with
|
|
575
591
|
# `pipefail`: unguarded, a failing step whose log carries no marker aborted this function
|
|
576
592
|
# before run_quiet could print the exit code and the two log paths, and the tail fallback
|
|
577
593
|
# below was unreachable. The no-match case is the fallback's trigger, not an error.
|
|
578
594
|
first=$(grep -a -n -m1 -E 'Error:|Error \[|^[[:space:]]+at |✖' "$debug_log" 2>/dev/null | cut -d: -f1) || true
|
|
579
|
-
|
|
595
|
+
|
|
580
596
|
printf -- '--- error trace (from merged log) ---\n' >>"$error_log"
|
|
581
597
|
if [ -n "$first" ]; then
|
|
582
598
|
tail -n "+$first" "$debug_log" >>"$error_log"
|
|
@@ -587,7 +603,7 @@ run_quiet_error_trace() {
|
|
|
587
603
|
|
|
588
604
|
run_quiet_drain() {
|
|
589
605
|
local pid="$1"
|
|
590
|
-
|
|
606
|
+
|
|
591
607
|
timeout 10 tail --pid="$pid" -f /dev/null 2>/dev/null || true
|
|
592
608
|
kill "$pid" 2>/dev/null || true
|
|
593
609
|
wait "$pid" 2>/dev/null || true
|
package/deploy/lib/host.sh
CHANGED
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
# Host preparation for deploy/<deploy-id>/*.sh. Sourced, never executed directly.
|
|
2
2
|
# Requires lib/github-actions-logging.sh for deploy_step.
|
|
3
3
|
|
|
4
|
+
LIB_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
|
5
|
+
source "$LIB_DIR/config.sh"
|
|
6
|
+
|
|
4
7
|
# The host configuration store, if this node has one.
|
|
5
8
|
#
|
|
6
9
|
# Every step below drives the CLI through `sudo`, so the store the CLI writes is root's, not the
|
|
@@ -82,21 +85,24 @@ deploy_id_from_repo() {
|
|
|
82
85
|
#
|
|
83
86
|
# Usage: install_deploy_dependencies <engine-root> [deploy-id]
|
|
84
87
|
install_deploy_dependencies() {
|
|
85
|
-
local engine_root="${1
|
|
88
|
+
local engine_root="${1:-$ENGINE_ROOT}"
|
|
86
89
|
local deploy_id="$2"
|
|
87
90
|
local manifest="engine-private/conf/$deploy_id/package.json"
|
|
88
91
|
|
|
89
92
|
if [ -n "$deploy_id" ] && [ -f "$engine_root/$manifest" ]; then
|
|
90
93
|
deploy_step "Install dependencies ($deploy_id)" \
|
|
91
|
-
|
|
94
|
+
sudo -n -- /bin/bash -lc "cd $engine_root && cp -a ./$manifest ./package.json && npm install"
|
|
92
95
|
else
|
|
93
96
|
deploy_step "Install dependencies" \
|
|
94
|
-
|
|
97
|
+
sudo -n -- /bin/bash -lc "cd $engine_root && npm install"
|
|
95
98
|
fi
|
|
96
99
|
|
|
100
|
+
# The global `underpost` is a symlink onto this checkout's entrypoint, so the link is only
|
|
101
|
+
# usable while that file carries its executable mode. The mode is tracked in git; the chmod
|
|
102
|
+
# is what carries a checkout that predates it, which is every node still to be synced.
|
|
97
103
|
deploy_step "Link underpost CLI" \
|
|
98
|
-
|
|
99
|
-
|
|
104
|
+
sudo -n -- /bin/bash -lc \
|
|
105
|
+
"cd $engine_root && chmod +x ./bin/index.js && npm link --force && test -x ./bin/index.js && test \"\$(readlink -f \"\$(command -v underpost)\")\" = \"\$(readlink -f ./bin/index.js)\""
|
|
100
106
|
}
|
|
101
107
|
|
|
102
108
|
# Brings a node to the state every deploy assumes: the engine source at HEAD, its dependencies
|
|
@@ -109,21 +115,21 @@ install_deploy_dependencies() {
|
|
|
109
115
|
# installed again after it, because the pull resets the checkout to its remote and takes
|
|
110
116
|
# `package.json` with it.
|
|
111
117
|
prepare_host() {
|
|
112
|
-
local engine_root="${1
|
|
118
|
+
local engine_root="${1:-$ENGINE_ROOT}"
|
|
113
119
|
local src_repo="${2:-$ENGINE_SRC_REPO}"
|
|
114
120
|
local src_private_repo="${3:-$ENGINE_SRC_PRIVATE_REPO}"
|
|
115
121
|
local deploy_id="${4:-$(deploy_id_from_repo "$src_repo")}"
|
|
116
|
-
|
|
122
|
+
|
|
117
123
|
install_deploy_dependencies "$engine_root" "$deploy_id"
|
|
118
|
-
|
|
124
|
+
|
|
119
125
|
deploy_step "Pull repository" \
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
126
|
+
sudo -n -- /bin/bash -lc \
|
|
127
|
+
"cd $engine_root && node bin run pull $src_repo${src_private_repo:+ --repo-engine-private $src_private_repo}"
|
|
128
|
+
|
|
123
129
|
install_deploy_dependencies "$engine_root" "$deploy_id"
|
|
124
|
-
|
|
130
|
+
|
|
125
131
|
deploy_step "Load host config" \
|
|
126
|
-
|
|
132
|
+
sudo -n -- /bin/bash -lc "cd $engine_root && node bin host load"
|
|
127
133
|
}
|
|
128
134
|
|
|
129
135
|
# Whether a tracked path carries uncommitted changes, as `1` or empty.
|
|
@@ -136,10 +142,10 @@ prepare_host() {
|
|
|
136
142
|
# Usage: has_changes <path> [engine-root]
|
|
137
143
|
has_changes() {
|
|
138
144
|
local path="$1"
|
|
139
|
-
local engine_root="${2:-$
|
|
140
|
-
|
|
145
|
+
local engine_root="${2:-$ENGINE_ROOT}"
|
|
146
|
+
|
|
141
147
|
sudo -n -- /bin/bash -lc \
|
|
142
|
-
|
|
148
|
+
"cd $engine_root && node bin cmt $path --has-changes" | tr -d '\n'
|
|
143
149
|
}
|
|
144
150
|
|
|
145
151
|
# The in-pod bootstrap, emitted as a `--cmd` payload (comma-separated: `underpost deploy`
|
|
@@ -163,13 +169,16 @@ has_changes() {
|
|
|
163
169
|
# `install` hook installs global tooling and `npm link` publishes the CLI there, and both write
|
|
164
170
|
# a tree the image left owned by root.
|
|
165
171
|
#
|
|
172
|
+
# The paths below are the container's, fixed by the image layout, and deliberately not
|
|
173
|
+
# `$ENGINE_ROOT`: that one names the checkout on the host running this script.
|
|
174
|
+
#
|
|
166
175
|
# Usage: pod_bootstrap_cmd <deploy-id> [env] [owner/repo]
|
|
167
176
|
pod_bootstrap_cmd() {
|
|
168
177
|
local deploy_id="$1"
|
|
169
178
|
local env="${2:-production}"
|
|
170
|
-
local repo="${3:-underpostnet/engine
|
|
179
|
+
local repo="${3:-underpostnet/engine-${deploy_id#dd-}}"
|
|
171
180
|
local name="${repo##*/}"
|
|
172
|
-
|
|
181
|
+
|
|
173
182
|
printf '%s' "cd /home/dd, \
|
|
174
183
|
underpost clone ${repo}, \
|
|
175
184
|
mkdir -p /home/dd/engine, \
|
|
@@ -181,5 +190,5 @@ sudo chown -R \$(id -u):\$(id -g) \$(npm prefix -g)/lib/node_modules \$(npm pref
|
|
|
181
190
|
npm install, \
|
|
182
191
|
npm link --force, \
|
|
183
192
|
test \"\$(readlink -f \"\$(command -v underpost)\")\" = \"\$(readlink -f ./bin/index.js)\", \
|
|
184
|
-
|
|
193
|
+
underpost state set container-status ${deploy_id}-${env}-build-deployment"
|
|
185
194
|
}
|
package/deploy/lib/state.sh
CHANGED
|
@@ -3,6 +3,9 @@
|
|
|
3
3
|
# The one source of streamed state for every context. Nothing here is conditional on GitHub
|
|
4
4
|
# Actions: annotations are just the rendering the state domain picks when it detects a workflow.
|
|
5
5
|
|
|
6
|
+
LIB_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
|
7
|
+
source "$LIB_DIR/config.sh"
|
|
8
|
+
|
|
6
9
|
STATE_ENV="${STATE_ENV:-production}"
|
|
7
10
|
STATE_NAMESPACE="${STATE_NAMESPACE:-default}"
|
|
8
11
|
STATE_STREAM="${STATE_STREAM:-1}"
|
|
@@ -18,7 +21,7 @@ STATE_WATCH="${STATE_WATCH:-2}"
|
|
|
18
21
|
#
|
|
19
22
|
# Usage: stream_state <engine-root> [deploy-id] [instance-id]
|
|
20
23
|
stream_state() {
|
|
21
|
-
local engine_root="${1
|
|
24
|
+
local engine_root="${1:-$ENGINE_ROOT}"
|
|
22
25
|
local deploy_id="${2:-$(basename "$(cd "$(dirname "${BASH_SOURCE[1]}")" && pwd)")}"
|
|
23
26
|
local instance_id="${3:-}"
|
|
24
27
|
local args="deploy-id=${deploy_id}"
|
|
@@ -9,6 +9,8 @@ source "$SCRIPT_DIR/../lib/github-actions-logging.sh"
|
|
|
9
9
|
# grandparent rather than a fixed remote path.
|
|
10
10
|
REPO_ROOT="$(cd "$SCRIPT_DIR/../.." && pwd)"
|
|
11
11
|
|
|
12
|
+
DEPLOY_ID=dd-github-pages
|
|
13
|
+
|
|
12
14
|
main() {
|
|
13
15
|
deploy_start "Starting github pages deploy"
|
|
14
16
|
|
|
@@ -29,17 +31,17 @@ main() {
|
|
|
29
31
|
deploy_step "Install dependencies" \
|
|
30
32
|
npm install
|
|
31
33
|
|
|
32
|
-
deploy_step "Build
|
|
33
|
-
node bin new --default-conf --conf-workflow-id
|
|
34
|
+
deploy_step "Build $DEPLOY_ID configuration" \
|
|
35
|
+
node bin new --default-conf --conf-workflow-id $DEPLOY_ID
|
|
34
36
|
|
|
35
|
-
deploy_step "Create
|
|
36
|
-
node bin new --deploy-id
|
|
37
|
+
deploy_step "Create $DEPLOY_ID deployment" \
|
|
38
|
+
node bin new --deploy-id $DEPLOY_ID
|
|
37
39
|
|
|
38
|
-
deploy_step "Load
|
|
39
|
-
node bin app load --env production --args deploy-id
|
|
40
|
+
deploy_step "Load $DEPLOY_ID production environment" \
|
|
41
|
+
node bin app load --env production --args deploy-id=$DEPLOY_ID
|
|
40
42
|
|
|
41
|
-
deploy_step "Build
|
|
42
|
-
env NODE_ENV=production node bin client
|
|
43
|
+
deploy_step "Build $DEPLOY_ID client" \
|
|
44
|
+
env NODE_ENV=production node bin client $DEPLOY_ID '' underpostnet.github.io /pwa-microservices-template-ghpkg
|
|
43
45
|
}
|
|
44
46
|
|
|
45
47
|
main "$@"
|
package/deploy/release/deploy.sh
CHANGED
package/deployment.yaml
CHANGED
package/docker-compose.yml
CHANGED
|
@@ -135,7 +135,7 @@ services:
|
|
|
135
135
|
# server starts but rejects connections until seeded). Serves REST/WS on 4005
|
|
136
136
|
# and the engine gRPC data service on 50051.
|
|
137
137
|
engine-cyberia-runtime:
|
|
138
|
-
image: ${ENGINE_CYBERIA_IMAGE:-underpost/engine-cyberia-dev}:${ENGINE_CYBERIA_TAG:-v3.3.
|
|
138
|
+
image: ${ENGINE_CYBERIA_IMAGE:-underpost/engine-cyberia-dev}:${ENGINE_CYBERIA_TAG:-v3.3.77}
|
|
139
139
|
container_name: dd-cyberia-engine
|
|
140
140
|
command:
|
|
141
141
|
- /bin/sh
|
|
@@ -190,14 +190,16 @@ services:
|
|
|
190
190
|
# gateway on host port 8081, so one port can route every instance path.
|
|
191
191
|
|
|
192
192
|
cyberia-server-runtime:
|
|
193
|
-
image: ${CYBERIA_SERVER_IMAGE:-underpost/cyberia-server-dev}:${CYBERIA_SERVER_TAG:-v3.3.
|
|
193
|
+
image: ${CYBERIA_SERVER_IMAGE:-underpost/cyberia-server-dev}:${CYBERIA_SERVER_TAG:-v3.3.77}
|
|
194
194
|
container_name: dd-cyberia-server
|
|
195
195
|
environment:
|
|
196
196
|
INSTANCE_CODE: amethyst-strata-expansion
|
|
197
197
|
CYBERIA_BASE_PATH: /
|
|
198
|
-
|
|
198
|
+
CYBERIA_PUBLIC_URL: ${CYBERIA_SERVER_PUBLIC_ORIGIN:-http://localhost:8081}
|
|
199
|
+
CYBERIA_SERVER_API_KEY: ${CYBERIA_SERVER_API_KEY:-}
|
|
200
|
+
CYBERIA_DATA_SERVER_URL: ${CYBERIA_DATA_SERVER_URL:-http://engine-cyberia}
|
|
199
201
|
ENGINE_PUBLIC_URL: ${ENGINE_PUBLIC_URL:-http://localhost:4005}
|
|
200
|
-
|
|
202
|
+
CYBERIA_DATA_SERVER_GRPC: ${CYBERIA_DATA_SERVER_GRPC:-engine-cyberia-runtime:50051}
|
|
201
203
|
ENGINE_GRPC_RELOAD_INTERVAL_SEC: ${ENGINE_GRPC_RELOAD_INTERVAL_SEC:-300}
|
|
202
204
|
STATIC_DIR: ${CYBERIA_SERVER_STATIC_DIR:-/home/dd/engine/cyberia-server/public}
|
|
203
205
|
APP_ENV: ${CYBERIA_SERVER_APP_ENV:-development}
|
|
@@ -226,14 +228,16 @@ services:
|
|
|
226
228
|
restart: unless-stopped
|
|
227
229
|
|
|
228
230
|
cyberia-server-forest:
|
|
229
|
-
image: ${CYBERIA_SERVER_IMAGE:-underpost/cyberia-server-dev}:${CYBERIA_SERVER_TAG:-v3.3.
|
|
231
|
+
image: ${CYBERIA_SERVER_IMAGE:-underpost/cyberia-server-dev}:${CYBERIA_SERVER_TAG:-v3.3.77}
|
|
230
232
|
container_name: dd-cyberia-server-forest
|
|
231
233
|
environment:
|
|
232
234
|
INSTANCE_CODE: FOREST
|
|
233
235
|
CYBERIA_BASE_PATH: /FOREST
|
|
234
|
-
|
|
236
|
+
CYBERIA_PUBLIC_URL: ${CYBERIA_SERVER_PUBLIC_ORIGIN:-http://localhost:8081}/FOREST
|
|
237
|
+
CYBERIA_SERVER_API_KEY: ${CYBERIA_SERVER_API_KEY:-}
|
|
238
|
+
CYBERIA_DATA_SERVER_URL: ${CYBERIA_DATA_SERVER_URL:-http://engine-cyberia}
|
|
235
239
|
ENGINE_PUBLIC_URL: ${ENGINE_PUBLIC_URL:-http://localhost:4005}
|
|
236
|
-
|
|
240
|
+
CYBERIA_DATA_SERVER_GRPC: ${CYBERIA_DATA_SERVER_GRPC:-engine-cyberia-runtime:50051}
|
|
237
241
|
ENGINE_GRPC_RELOAD_INTERVAL_SEC: ${ENGINE_GRPC_RELOAD_INTERVAL_SEC:-300}
|
|
238
242
|
STATIC_DIR: ${CYBERIA_SERVER_STATIC_DIR:-/home/dd/engine/cyberia-server/public}
|
|
239
243
|
APP_ENV: ${CYBERIA_SERVER_APP_ENV:-development}
|
|
@@ -262,14 +266,16 @@ services:
|
|
|
262
266
|
restart: unless-stopped
|
|
263
267
|
|
|
264
268
|
cyberia-server-test:
|
|
265
|
-
image: ${CYBERIA_SERVER_IMAGE:-underpost/cyberia-server-dev}:${CYBERIA_SERVER_TAG:-v3.3.
|
|
269
|
+
image: ${CYBERIA_SERVER_IMAGE:-underpost/cyberia-server-dev}:${CYBERIA_SERVER_TAG:-v3.3.77}
|
|
266
270
|
container_name: dd-cyberia-server-test
|
|
267
271
|
environment:
|
|
268
272
|
INSTANCE_CODE: TEST
|
|
269
273
|
CYBERIA_BASE_PATH: /TEST
|
|
270
|
-
|
|
274
|
+
CYBERIA_PUBLIC_URL: ${CYBERIA_SERVER_PUBLIC_ORIGIN:-http://localhost:8081}/TEST
|
|
275
|
+
CYBERIA_SERVER_API_KEY: ${CYBERIA_SERVER_API_KEY:-}
|
|
276
|
+
CYBERIA_DATA_SERVER_URL: ${CYBERIA_DATA_SERVER_URL:-http://engine-cyberia}
|
|
271
277
|
ENGINE_PUBLIC_URL: ${ENGINE_PUBLIC_URL:-http://localhost:4005}
|
|
272
|
-
|
|
278
|
+
CYBERIA_DATA_SERVER_GRPC: ${CYBERIA_DATA_SERVER_GRPC:-engine-cyberia-runtime:50051}
|
|
273
279
|
ENGINE_GRPC_RELOAD_INTERVAL_SEC: ${ENGINE_GRPC_RELOAD_INTERVAL_SEC:-300}
|
|
274
280
|
STATIC_DIR: ${CYBERIA_SERVER_STATIC_DIR:-/home/dd/engine/cyberia-server/public}
|
|
275
281
|
APP_ENV: ${CYBERIA_SERVER_APP_ENV:-development}
|
|
@@ -299,7 +305,7 @@ services:
|
|
|
299
305
|
|
|
300
306
|
# === Tier 4: presentation, one per variant ===============================
|
|
301
307
|
# One WASM bundle serves every variant; the instance is resolved from the URL
|
|
302
|
-
# sub-path (
|
|
308
|
+
# sub-path (wasm-driver injects CYBERIA_BASE_PATH / _WS_ORIGIN /
|
|
303
309
|
# _ENGINE_API_ORIGIN / _DEFAULT_INSTANCE). Each client waits ONLY for its own
|
|
304
310
|
# server, so the three
|
|
305
311
|
# server->client pipelines advance independently (in parallel) once the shared
|
|
@@ -309,7 +315,7 @@ services:
|
|
|
309
315
|
# cyberia-server-test -> cyberia-client-test
|
|
310
316
|
|
|
311
317
|
cyberia-client-runtime:
|
|
312
|
-
image: ${CYBERIA_CLIENT_IMAGE:-underpost/cyberia-client-dev}:${CYBERIA_CLIENT_TAG:-v3.3.
|
|
318
|
+
image: ${CYBERIA_CLIENT_IMAGE:-underpost/cyberia-client-dev}:${CYBERIA_CLIENT_TAG:-v3.3.77}
|
|
313
319
|
container_name: dd-cyberia-client
|
|
314
320
|
environment:
|
|
315
321
|
CYBERIA_PORT: '8081'
|
|
@@ -317,7 +323,7 @@ services:
|
|
|
317
323
|
CYBERIA_BASE_PATH: /
|
|
318
324
|
CYBERIA_DEFAULT_INSTANCE: ${CYBERIA_DEFAULT_INSTANCE:-amethyst-strata-expansion}
|
|
319
325
|
CYBERIA_WS_ORIGIN: ${CYBERIA_WS_ORIGIN:-ws://localhost:8081}
|
|
320
|
-
|
|
326
|
+
CYBERIA_DATA_SERVER_URL: ${CYBERIA_CLIENT_DATA_SERVER_URL:-http://localhost}
|
|
321
327
|
networks:
|
|
322
328
|
- dd-cyberia-internal
|
|
323
329
|
expose:
|
|
@@ -334,7 +340,7 @@ services:
|
|
|
334
340
|
restart: unless-stopped
|
|
335
341
|
|
|
336
342
|
cyberia-client-forest:
|
|
337
|
-
image: ${CYBERIA_CLIENT_IMAGE:-underpost/cyberia-client-dev}:${CYBERIA_CLIENT_TAG:-v3.3.
|
|
343
|
+
image: ${CYBERIA_CLIENT_IMAGE:-underpost/cyberia-client-dev}:${CYBERIA_CLIENT_TAG:-v3.3.77}
|
|
338
344
|
container_name: dd-cyberia-client-forest
|
|
339
345
|
environment:
|
|
340
346
|
CYBERIA_PORT: '8081'
|
|
@@ -342,7 +348,7 @@ services:
|
|
|
342
348
|
CYBERIA_BASE_PATH: /FOREST
|
|
343
349
|
CYBERIA_DEFAULT_INSTANCE: ${CYBERIA_DEFAULT_INSTANCE:-amethyst-strata-expansion}
|
|
344
350
|
CYBERIA_WS_ORIGIN: ${CYBERIA_WS_ORIGIN:-ws://localhost:8081}
|
|
345
|
-
|
|
351
|
+
CYBERIA_DATA_SERVER_URL: ${CYBERIA_CLIENT_DATA_SERVER_URL:-http://localhost}
|
|
346
352
|
networks:
|
|
347
353
|
- dd-cyberia-internal
|
|
348
354
|
expose:
|
|
@@ -359,7 +365,7 @@ services:
|
|
|
359
365
|
restart: unless-stopped
|
|
360
366
|
|
|
361
367
|
cyberia-client-test:
|
|
362
|
-
image: ${CYBERIA_CLIENT_IMAGE:-underpost/cyberia-client-dev}:${CYBERIA_CLIENT_TAG:-v3.3.
|
|
368
|
+
image: ${CYBERIA_CLIENT_IMAGE:-underpost/cyberia-client-dev}:${CYBERIA_CLIENT_TAG:-v3.3.77}
|
|
363
369
|
container_name: dd-cyberia-client-test
|
|
364
370
|
environment:
|
|
365
371
|
CYBERIA_PORT: '8081'
|
|
@@ -367,7 +373,7 @@ services:
|
|
|
367
373
|
CYBERIA_BASE_PATH: /TEST
|
|
368
374
|
CYBERIA_DEFAULT_INSTANCE: ${CYBERIA_DEFAULT_INSTANCE:-amethyst-strata-expansion}
|
|
369
375
|
CYBERIA_WS_ORIGIN: ${CYBERIA_WS_ORIGIN:-ws://localhost:8081}
|
|
370
|
-
|
|
376
|
+
CYBERIA_DATA_SERVER_URL: ${CYBERIA_CLIENT_DATA_SERVER_URL:-http://localhost}
|
|
371
377
|
networks:
|
|
372
378
|
- dd-cyberia-internal
|
|
373
379
|
expose:
|