`mosaic business instances BUSINESS` reads the role instances, and `mosaic business instance add|set` writes one add or change through the broker's new human-only `instances` and `instances.set` verbs. The writer is packages/business/src/instance-settings.mjs. It takes the caller's revision, validates the next document, refuses a definition that declares credentials (organization-credentials-out-of-scope), keeps protected instances as they are, logs the human as the actor, and says when the running bus needs a restart. Neither command restarts the bus. The writer refuses the instance ids human and tester with invalid-request, because the broker refuses a business whose roles use either name when the bus starts. The Console's Settings view shows the instances and, under --send only, posts to POST /api/instances with the exact Origin and same-origin Fetch Metadata. A refusal keeps the draft. An answer without the view's shape is outcome-unknown (503). The page's public/ diff carries the decision 123 go in mos-0832. Neither verb is in ORGANIZATION_KEYS, so no agent tool reaches them. Owner Darkwing, brief in row 165 (#1662). Round 3 rebases round 2 onto4f45cadc0(row 156). The public/ +/- digest is 939ecd28...9444, unchanged at landing. Reviewers on candidate manifest e30b54da...f580: Dewey approve 29052, Filbert approve 29053. Seat run on4f45cadc0: 1436/0 singles, 37/37 mutants killed. Sage gate one8b09735a: GATE_PASSED 25/25, packages 2282/0, queue node 156/0, script selftests 422/0, 23:59:13Z to 00:05:35Z. Rebased onto50a57e454over two SESSIONS-only commits. Nothing live.
41 lines
1.9 KiB
Bash
Executable File
41 lines
1.9 KiB
Bash
Executable File
#!/usr/bin/env bash
|
|
# `mosaic launch <seat>` and `mosaic seat task <seat> <text>`: seat launch
|
|
# with registration for the control board. See packages/seat/README.md.
|
|
# `mosaic queue <verb>`: the work queue. See packages/queue/README.md.
|
|
# `mosaic business <verb>`: business files and role instances. See
|
|
# packages/business/README.md.
|
|
# `mosaic inbox|decide|tasks|agents|trail|talk|stop|launches` and
|
|
# `mosaic bus start|stop|status`: the human commands, managed sessions and
|
|
# the bus host. See packages/cli/README.md.
|
|
# This is the repository wrapper; run it by path from the checkout. A host
|
|
# may also put `mosaic` on PATH as a wrapper that runs a pinned copy's
|
|
# scripts/mosaic (scripts/stack-copy.sh wrapper, docs/TOOLS.md "Stack
|
|
# copies"). On Jason's host the estate CLI it replaced is `mosaic-old`.
|
|
# On a pinned host the human commands and --tester go through
|
|
# that `mosaic`, and from a checkout they exit 3. Queue commands stay on
|
|
# scripts/mosaic queue in the canonical checkout, because a copy refuses
|
|
# them. See packages/cli/README.md "One pinned copy".
|
|
set -euo pipefail
|
|
REPO="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
|
|
# No argument: the full-screen app on a terminal (packages/cli/README.md).
|
|
if [ $# -eq 0 ]; then
|
|
exec node "$REPO/packages/cli/src/cli.mjs"
|
|
fi
|
|
if [ "${1:-}" = queue ]; then
|
|
shift
|
|
exec node "$REPO/packages/queue/src/cli.mjs" "$@"
|
|
fi
|
|
if [ "${1:-}" = business ]; then
|
|
# Row 165 (#1662): the human's role instance commands need the human proof,
|
|
# so they run in packages/cli. validate and resolve stay in packages/business.
|
|
case "${2:-}" in
|
|
instances|instance) exec node "$REPO/packages/cli/src/cli.mjs" "$@" ;;
|
|
esac
|
|
shift
|
|
exec node "$REPO/packages/business/src/cli.mjs" "$@"
|
|
fi
|
|
case "${1:-}" in
|
|
usage|project|limits|inbox|decide|tasks|agents|trail|talk|stop|launches|bus) exec node "$REPO/packages/cli/src/cli.mjs" "$@" ;;
|
|
esac
|
|
exec node "$REPO/packages/seat/src/cli.mjs" "$@"
|