Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
99 commits
Select commit Hold shift + click to select a range
26ac562
Worker tests: share the D1 and R2 fakes
teaspoonai Nov 29, 2026
bbde3ac
Worker: issue and renew engine license keys (#474)
teaspoonai Nov 29, 2026
a909f61
Docs: the license signing key, and what key issuance records (#474)
teaspoonai Nov 29, 2026
096e7f9
Docs: prod.pub's line for the online key, exactly (#474)
teaspoonai Nov 29, 2026
ef720e2
Worker: license revocations stick; the cap is atomic and indexed (#474)
teaspoonai Nov 29, 2026
f706440
Docs: license revocation and release, and rows that outlive their acc…
teaspoonai Nov 29, 2026
af339a4
Worker: a revoked key holds for its device, and keeps counting (#474)
teaspoonai Nov 29, 2026
a194be9
Docs: revoking a key holds for the device; revoked keys count (#474)
teaspoonai Nov 29, 2026
62f3f38
Worker: a revoked key of any tier bars its device (#474)
teaspoonai Nov 29, 2026
d83753d
Worker: the revoked-device bar covers appliance keys too (#474)
teaspoonai Nov 29, 2026
813fe05
Worker: renewals need the current license; a re-provisioned box keeps…
teaspoonai Nov 29, 2026
a301962
Docs: renewal after a license change, and a re-provisioned box's key …
teaspoonai Nov 29, 2026
1f1d083
Worker: an appliance key moves only to a record of the same box (#474)
teaspoonai Nov 29, 2026
08aa2ef
Docs: what a leaked FACTORY_TOKEN does to license keys, and the clean…
teaspoonai Nov 29, 2026
03d1938
Docs: the leak runbook revokes the suspect records first, and sorts k…
teaspoonai Nov 29, 2026
d1063ee
Worker tests: run the leak runbook as RELEASING.md writes it (#474)
teaspoonai Nov 29, 2026
ec68c88
Worker: record each appliance key's first maker acceptance (#474)
teaspoonai Nov 29, 2026
2d8ec56
Docs, tests: the leak runbook sorts by first_maker_id and checks LEAK…
teaspoonai Nov 29, 2026
5725a1d
Worker: a maker acceptance that ever held a key gets no other (#474)
teaspoonai Nov 29, 2026
1d2fcaa
Docs: license_makers, and a spent maker acceptance (#474)
teaspoonai Nov 29, 2026
280c1d5
Docs: the licenses page's Worker citation, moved by the license route…
teaspoonai Nov 29, 2026
740e36c
Manifest signing: new boxes install and update only from a signed rel…
teaspoonai Nov 25, 2026
e4ed6c6
RELEASING: the key ceremony also makes the engine's offline license k…
teaspoonai Nov 29, 2026
f7c7a41
Docs: an erasure request keeps the license key records, restricted to…
teaspoonai Nov 29, 2026
3232ae3
Worker: an appliance key's link secret, and POST /api/license/link (#…
teaspoonai Nov 29, 2026
870fa03
Worker tests: the acceptance a box's setup makes is taken, and links …
teaspoonai Nov 29, 2026
e6f7731
Box: the owner's license helpers, to record and link their acceptance…
teaspoonai Nov 29, 2026
eda09eb
Root helpers: none writes, renames or removes the engine's license fi…
teaspoonai Nov 29, 2026
ef1aa3c
Setup: Read the license / I accept, beside Create your login (#465)
teaspoonai Nov 29, 2026
25448e5
install.sh: a factory install keeps the license text for the owner's …
teaspoonai Nov 29, 2026
ed72c41
Docs: the owner accepts the engine license at setup, and its link (#465)
teaspoonai Nov 29, 2026
350d8f2
Worker: /api/license/link answers one 403 before the secret; a move u…
teaspoonai Nov 29, 2026
492ca90
Box: the license helpers pin the license server, lock sends, recover …
teaspoonai Nov 29, 2026
5b050d5
Setup: Not you? Accept again, and Settings' login waits for the licen…
teaspoonai Nov 29, 2026
e18581f
Docs: the window before the link, the only proof of ownership, I1 as …
teaspoonai Nov 29, 2026
e8e9c49
Worker: owner_use (personal or business) for a box's setup; a link al…
teaspoonai Nov 29, 2026
5040bee
Box: Not you? ends with the owner's login; a mask that tells lookalik…
teaspoonai Nov 29, 2026
bb972ed
Docs: the support re-link, personal or business, the login's window (…
teaspoonai Nov 29, 2026
451e5e6
Worker: request_id dedups a resent acceptance; no Cc/Cf in an email; …
teaspoonai Nov 29, 2026
c542c1a
Box: no format characters in an email, IDNA in the mask, a caller tha…
teaspoonai Nov 29, 2026
dbd2faf
Docs: support's re-link ties the key to the requester's box, by facto…
teaspoonai Nov 29, 2026
060516d
Worker: every link rotates the link secret, with a handover; NFKC and…
teaspoonai Nov 29, 2026
bd7ae8b
Box: the link writes the rotated secret and confirms it; the holder o…
teaspoonai Nov 29, 2026
03ad823
Docs: re-link from the box first (possession outranks records); a run…
teaspoonai Nov 29, 2026
f3d42bd
Worker: a one-time recovery code for a box a copy locked out; the re-…
teaspoonai Nov 29, 2026
02fd899
Box: a lost link said, link --recovery-code; a failed replace keeps t…
teaspoonai Nov 29, 2026
27ccb06
Docs: the link contest, the lost state and the recovery code; a runbo…
teaspoonai Nov 29, 2026
4023edf
Worker: a handover's previous secret ends in an hour; a recovery code…
teaspoonai Nov 29, 2026
2efbe81
Box: the timer runs until a link's handover is confirmed, after setup…
teaspoonai Nov 29, 2026
6bdc09c
Docs: the owner's decision of 2026-11-29 as decided; the handover's e…
teaspoonai Nov 29, 2026
7ba1b08
Worker: a day's handover, the recovery code kept as the previous
teaspoonai Nov 29, 2026
385720c
Box: a lost handover said as lost; the handover marker cannot outlive…
teaspoonai Nov 29, 2026
076df9d
Runbook: writes checked by SELECTs; docs for the day's handover
teaspoonai Nov 29, 2026
cac02db
Box: a secret that never linked, refused, is a failed link of unknown…
teaspoonai Nov 29, 2026
be4a528
Box: a first link refused bad_link_secret is a failed link too
teaspoonai Nov 29, 2026
2c66fc5
Docs: what support checks first for a box whose link failed (#465)
teaspoonai Nov 29, 2026
04b3305
Docs: the acceptance's device_id from a box's setup is the serial's h…
teaspoonai Nov 29, 2026
7cf02ea
Merge origin/feat/owner-accept-465 (#488, O1) into the installer lice…
teaspoonai Nov 29, 2026
79140b8
Merge remote-tracking branch 'origin/feat/owner-accept-465' into feat…
teaspoonai Nov 29, 2026
331b7b2
Docs: citations after the merge of #488, re-checked against the merge…
teaspoonai Nov 29, 2026
cfef902
License key: license_key.py, the root helper that asks for, renews an…
teaspoonai Nov 29, 2026
dfc7299
Engine unit: RestartPreventExitStatus=78; the key's daily renewal, pa…
teaspoonai Nov 29, 2026
da55650
install.sh: the engine license key after the engine download; --licen…
teaspoonai Nov 29, 2026
0967549
teaport status and doctor: the engine license key (#474 I1)
teaspoonai Nov 29, 2026
aa8d7e1
License key: a renewal refused eula_changed asks again with the recei…
teaspoonai Nov 29, 2026
d03c821
Docs: the engine license key: what the installer asks for and writes,…
teaspoonai Nov 29, 2026
1007399
License key: an engine before license keys is never handed their flag…
teaspoonai Nov 29, 2026
644b841
Docs: citations after the engine flag check (#474 I1)
teaspoonai Nov 29, 2026
a6652ed
Merge fixes: the protected-path check before the manifest's signature…
teaspoonai Nov 29, 2026
b1a1784
Tests: the installer harnesses know the license key's step (#474 I1)
teaspoonai Nov 29, 2026
60ec610
License key: the engine checks every new key; the factory binding; se…
teaspoonai Nov 29, 2026
596a4f3
install.sh: --license-file checked by the engine before the run chang…
teaspoonai Nov 29, 2026
8243ca3
teaport status and doctor: a key kept for a refused new one, a symlin…
teaspoonai Nov 29, 2026
286d33f
Packaging: postinst starts the renewal timer; the license units harde…
teaspoonai Nov 29, 2026
34f1c8d
Docs: the engine checks every new key, the factory binding, the check…
teaspoonai Nov 29, 2026
19d4805
License key: a check stages outside /etc/teaport; a secret not writte…
teaspoonai Nov 29, 2026
e65e1c5
install.sh: a new engine checks the license file again before anythin…
teaspoonai Nov 29, 2026
cb57337
teaport status and doctor: engine.env's values on no command line (#4…
teaspoonai Nov 29, 2026
86020b9
Docs: citations after the second review's fixes (#474 I1 review 2)
teaspoonai Nov 29, 2026
e73b825
License key: a check's scratch directory never outlives it, and its c…
teaspoonai Nov 29, 2026
ecb4945
Docs: citations after the check's clean-up fix (#474 I1 review 3)
teaspoonai Nov 29, 2026
878994b
Merge remote-tracking branch 'origin/main' into feat/license-issue-474
teaspoonai Nov 30, 2026
1d758e8
Merge feat/license-issue-474 (main with #480, #482) into feat/owner-a…
teaspoonai Nov 30, 2026
7ab70a6
Merge origin/feat/owner-accept-465 (#488 with main's #480 and #482) i…
teaspoonai Nov 30, 2026
753a5df
Docs: citations after the merge of #488 with main, re-checked against…
teaspoonai Nov 30, 2026
31a49f0
Tests: the fresh-install case skips through the harness, not pytest (…
teaspoonai Nov 30, 2026
add7034
Manifest signing: new boxes install and update only from a signed rel…
teaspoonai Nov 25, 2026
efc431e
RELEASING: the key ceremony also makes the engine's offline license k…
teaspoonai Nov 29, 2026
be2c065
publish: accept GitHub's stateless installation tokens in last_upload.py
teaspoonai Nov 30, 2026
a64dd4a
docs: re-cite install.sh after rebasing manifest signing onto #480
teaspoonai Nov 30, 2026
4bb3162
publish: accept GitHub's stateless installation tokens in last_upload.py
teaspoonai Nov 30, 2026
a41ed6b
Merge #475's rebased head (a64dd4af) into the I1 branch
teaspoonai Dec 1, 2026
12006a3
Manifest signing: new boxes install and update only from a signed rel…
teaspoonai Nov 25, 2026
8616cfb
RELEASING: the key ceremony also makes the engine's offline license k…
teaspoonai Nov 29, 2026
95b5566
publish: accept GitHub's stateless installation tokens in last_upload.py
teaspoonai Nov 30, 2026
dcfad16
Merge main (0cb55748, #490) into the I1 branch
teaspoonai Dec 1, 2026
a6d3384
docs: re-cite install.sh after rebasing manifest signing onto #480 an…
teaspoonai Dec 1, 2026
a9b1b6b
docs: re-cite after merging #490 (brain port / GATEWAY_TOKEN)
teaspoonai Dec 1, 2026
ed8b552
Merge #475's second rebase (a6d33848, on main 0cb55748) into the I1 b…
teaspoonai Dec 1, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
98 changes: 98 additions & 0 deletions .github/actions/brain-deb-check/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,98 @@
name: brain-deb-check
description: >-
Install a teaport-brain .deb and check the installed package: the self-check (as the runner
user and as root), dpkg -V and file ownership, and that Depends covers every system library
the venv links against. ci.yml runs it on its own build of every commit; release-deb.yml on
the release .deb, after its sha256 is printed.
inputs:
deb:
description: the .deb, relative to the workspace
required: true
runs:
using: composite
steps:
- name: Install it
shell: bash
env:
DEB: ${{ inputs.deb }}
run: sudo apt-get install -y "./$DEB"
- name: Self-check the installed package
# From /, isolated (-I), as the runner user and then as root. Root is the strict
# case: a root python writes a __pycache__ wherever a .pyc is missing or stale,
# which the next step would see as a file the package does not own, or as a
# changed one. The run user on the box cannot write the tree at all, so a stale
# .pyc there would cost a recompile on every start instead.
shell: bash
run: |
cd /
/opt/teaport/brain/bin/python -I -m teaport_brain.selfcheck
sudo /opt/teaport/brain/bin/python -I -m teaport_brain.selfcheck
/opt/teaport/brain/bin/teaport-brain --help >/dev/null
test -x /usr/bin/teaport && bash -n /usr/bin/teaport
# compile(), not py_compile: that would write a __pycache__ beside the helper.
for p in /usr/lib/teaport/config_apply.py /usr/lib/teaport/update_apply.py /usr/lib/teaport/wifi_apply.py /usr/lib/teaport/login_apply.py /usr/lib/teaport/license_accept.py /usr/lib/teaport/license_link.py /usr/lib/teaport/manifest_sig.py /usr/lib/teaport/license_key.py; do
/usr/bin/python3 -I -c 'import sys; p = sys.argv[1]; compile(open(p).read(), p, "exec")' "$p"
done
# The update's unit, as systemd reads it (it is static: nothing enables it).
systemd-analyze verify /usr/lib/systemd/system/teaport-update.service
[ "$(systemctl show -p UnitFileState --value teaport-update.service)" = static ]
# The owner's license retry (#465): enabled by the package's own link.
systemd-analyze verify /usr/lib/systemd/system/teaport-license-owner.service /usr/lib/systemd/system/teaport-license-owner.timer
[ "$(readlink /usr/lib/systemd/system/timers.target.wants/teaport-license-owner.timer)" = /usr/lib/systemd/system/teaport-license-owner.timer ]
# The engine license key's renewal (#474), enabled the same way.
systemd-analyze verify /usr/lib/systemd/system/teaport-license-renew.service /usr/lib/systemd/system/teaport-license-renew.timer
[ "$(readlink /usr/lib/systemd/system/timers.target.wants/teaport-license-renew.timer)" = /usr/lib/systemd/system/teaport-license-renew.timer ]
# The engine's license files are never the package's (an upgrade or a purge would
# replace or remove a box's key), and nothing of the engine's issuer ships here.
if dpkg -L teaport-brain | grep -E '^/etc/teaport/license|/tools/license(/|$)|/license_keys(/|$)'; then
echo "teaport-brain ships an engine license file or the issuer's tools"; exit 1
fi
if dpkg-query --control-show teaport-brain conffiles 2>/dev/null | grep -E '/etc/teaport/license'; then
echo "teaport-brain lists an engine license file as a conffile"; exit 1
fi
- name: dpkg -V is clean, and the package owns every file under its root
shell: bash
run: |
out="$(dpkg -V teaport-brain)"
[ -z "$out" ] || { printf '%s\n' "$out"; echo "dpkg -V: files changed after install"; exit 1; }
stray="$(comm -13 <(dpkg -L teaport-brain | sort -u) <(find /opt/teaport/brain | sort -u))"
[ -z "$stray" ] || { printf '%s\n' "$stray" | head -50; echo "files under /opt/teaport/brain that the package does not own (written at run time?)"; exit 1; }
echo "dpkg -V clean; $(dpkg -L teaport-brain | wc -l) paths owned"
- name: Shared libraries (what Depends must cover)
# Every ELF object in the venv, through ldd. Anything unresolved fails the job.
# Anything resolved OUTSIDE the venv is a system library the package relies on:
# listed with the Debian package that ships it and one .so that needs it, and
# every such package must be named in the .deb's Depends: (what dpkg-shlibdeps
# would have derived, for a package nfpm builds without it).
shell: bash
run: |
find /opt/teaport/brain -type f \( -name '*.so' -o -name '*.so.*' \) > "$RUNNER_TEMP/elfs"
echo "$(wc -l < "$RUNNER_TEMP/elfs") shared objects in the venv"
missing=0; : > "$RUNNER_TEMP/sys"
while IFS= read -r f; do
out="$(ldd "$f" 2>&1 || true)"
if grep -q 'not found' <<<"$out"; then echo "UNRESOLVED in $f:"; grep 'not found' <<<"$out"; missing=1; fi
awk -v so="${f#/opt/teaport/brain/lib/python3.12/site-packages/}" \
'/=> \//{print $3, so} /^\t\/[^ ]+ \(/{print $1, so}' <<<"$out" \
| grep -v '^/opt/teaport/brain/' >> "$RUNNER_TEMP/sys" || true
done < "$RUNNER_TEMP/elfs"
# dpkg -S by the path ldd printed, then by its resolved one: since the /usr
# merge a library can be registered under either spelling. Diversion notes
# (the dynamic loader has one) are not owners.
owner() { { dpkg -S "$1"; dpkg -S "$(readlink -f "$1")"; } 2>/dev/null | grep -v '^diversion by' | head -1 | cut -d: -f1; }
echo "system libraries the venv links against:"
: > "$RUNNER_TEMP/pkgs"
while read -r lib so; do
pkg="$(owner "$lib" || true)"
printf ' %-44s %-12s e.g. %s\n' "$lib" "${pkg:-?}" "$so"
echo "${pkg:-?}" >> "$RUNNER_TEMP/pkgs"
done < <(sort -u -k1,1 "$RUNNER_TEMP/sys")
echo "packages: $(sort -u "$RUNNER_TEMP/pkgs" | paste -sd' ')"
depends="$(dpkg-query -W -f='${Depends}' teaport-brain)"
echo "Depends: $depends"
# Package names only (version constraints dropped), matched as whole lines.
sed 's/ *([^)]*)//g; s/, */\n/g' <<<"$depends" > "$RUNNER_TEMP/depends"
for pkg in $(sort -u "$RUNNER_TEMP/pkgs"); do
if ! grep -qxF "$pkg" "$RUNNER_TEMP/depends"; then echo "not in Depends: $pkg"; missing=1; fi
done
[ "$missing" = 0 ]
127 changes: 52 additions & 75 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,9 @@ name: ci
on:
push:
branches: [main]
# brain-v<X.Y.Z>: brain-deb builds the release package. It is uploaded as a run
# artifact like any other build; publishing it is a separate, manual step.
# brain-v<X.Y.Z>: brain-deb builds the tag here too, and brain-deb-check installs and
# checks that build. The release .deb itself (published, and signed for) is
# release-deb.yml's, a workflow of the tag alone.
tags: ["brain-v*"]
pull_request:

Expand Down Expand Up @@ -67,8 +68,8 @@ jobs:
run: |
pip install uv==0.9.24
uv sync --locked --no-editable --project brain
- name: Brain self-check (what the brain-deb job runs against the built package)
# The same gate the brain-deb job applies to the built package: import both
- name: Brain self-check (what the brain-deb-check job runs against the built package)
# The same gate the brain-deb-check job applies to the built package: import both
# front-ends and push audio through Silero VAD + Smart Turn v3, the compiled
# extensions (onnxruntime, loudness) a numpy major would break. brain-deb builds
# on the arm runner only; this step runs on both legs, so it is also what checks
Expand Down Expand Up @@ -111,8 +112,10 @@ jobs:
group: ci-brain-deb-${{ github.ref }}
cancel-in-progress: false
timeout-minutes: 30
# This job only builds and uploads; the self-check and the other checks of the package
# run in brain-deb-check.
steps:
- uses: actions/checkout@v5
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
with:
ref: ${{ github.event.pull_request.head.sha || github.sha }}
- name: Build the .deb
Expand All @@ -133,72 +136,7 @@ jobs:
# The checksum names the file, not dist/<file>: `sha256sum -c` works from wherever
# the artifact is downloaded.
ls -l "$deb"; (cd dist && sha256sum "$(basename "$deb")" | tee "$(basename "$deb").sha256")
- name: Install it
run: sudo apt-get install -y "./$DEB"
- name: Self-check the installed package
# From /, isolated (-I), as the runner user and then as root. Root is the strict
# case: a root python writes a __pycache__ wherever a .pyc is missing or stale,
# which the next step would see as a file the package does not own, or as a
# changed one. The run user on the box cannot write the tree at all, so a stale
# .pyc there would cost a recompile on every start instead.
run: |
cd /
/opt/teaport/brain/bin/python -I -m teaport_brain.selfcheck
sudo /opt/teaport/brain/bin/python -I -m teaport_brain.selfcheck
/opt/teaport/brain/bin/teaport-brain --help >/dev/null
test -x /usr/bin/teaport && bash -n /usr/bin/teaport
# compile(), not py_compile: that would write a __pycache__ beside the helper.
for p in /usr/lib/teaport/config_apply.py /usr/lib/teaport/update_apply.py /usr/lib/teaport/wifi_apply.py /usr/lib/teaport/login_apply.py; do
/usr/bin/python3 -I -c 'import sys; p = sys.argv[1]; compile(open(p).read(), p, "exec")' "$p"
done
# The update's unit, as systemd reads it (it is static: nothing enables it).
systemd-analyze verify /usr/lib/systemd/system/teaport-update.service
[ "$(systemctl show -p UnitFileState --value teaport-update.service)" = static ]
- name: dpkg -V is clean, and the package owns every file under its root
run: |
out="$(dpkg -V teaport-brain)"
[ -z "$out" ] || { printf '%s\n' "$out"; echo "dpkg -V: files changed after install"; exit 1; }
stray="$(comm -13 <(dpkg -L teaport-brain | sort -u) <(find /opt/teaport/brain | sort -u))"
[ -z "$stray" ] || { printf '%s\n' "$stray" | head -50; echo "files under /opt/teaport/brain that the package does not own (written at run time?)"; exit 1; }
echo "dpkg -V clean; $(dpkg -L teaport-brain | wc -l) paths owned"
- name: Shared libraries (what Depends must cover)
# Every ELF object in the venv, through ldd. Anything unresolved fails the job.
# Anything resolved OUTSIDE the venv is a system library the package relies on:
# listed with the Debian package that ships it and one .so that needs it, and
# every such package must be named in the .deb's Depends: (what dpkg-shlibdeps
# would have derived, for a package nfpm builds without it).
run: |
find /opt/teaport/brain -type f \( -name '*.so' -o -name '*.so.*' \) > "$RUNNER_TEMP/elfs"
echo "$(wc -l < "$RUNNER_TEMP/elfs") shared objects in the venv"
missing=0; : > "$RUNNER_TEMP/sys"
while IFS= read -r f; do
out="$(ldd "$f" 2>&1 || true)"
if grep -q 'not found' <<<"$out"; then echo "UNRESOLVED in $f:"; grep 'not found' <<<"$out"; missing=1; fi
awk -v so="${f#/opt/teaport/brain/lib/python3.12/site-packages/}" \
'/=> \//{print $3, so} /^\t\/[^ ]+ \(/{print $1, so}' <<<"$out" \
| grep -v '^/opt/teaport/brain/' >> "$RUNNER_TEMP/sys" || true
done < "$RUNNER_TEMP/elfs"
# dpkg -S by the path ldd printed, then by its resolved one: since the /usr
# merge a library can be registered under either spelling. Diversion notes
# (the dynamic loader has one) are not owners.
owner() { { dpkg -S "$1"; dpkg -S "$(readlink -f "$1")"; } 2>/dev/null | grep -v '^diversion by' | head -1 | cut -d: -f1; }
echo "system libraries the venv links against:"
: > "$RUNNER_TEMP/pkgs"
while read -r lib so; do
pkg="$(owner "$lib" || true)"
printf ' %-44s %-12s e.g. %s\n' "$lib" "${pkg:-?}" "$so"
echo "${pkg:-?}" >> "$RUNNER_TEMP/pkgs"
done < <(sort -u -k1,1 "$RUNNER_TEMP/sys")
echo "packages: $(sort -u "$RUNNER_TEMP/pkgs" | paste -sd' ')"
depends="$(dpkg-query -W -f='${Depends}' teaport-brain)"
echo "Depends: $depends"
# Package names only (version constraints dropped), matched as whole lines.
sed 's/ *([^)]*)//g; s/, */\n/g' <<<"$depends" > "$RUNNER_TEMP/depends"
for pkg in $(sort -u "$RUNNER_TEMP/pkgs"); do
if ! grep -qxF "$pkg" "$RUNNER_TEMP/depends"; then echo "not in Depends: $pkg"; missing=1; fi
done
[ "$missing" = 0 ]
- uses: actions/upload-artifact@v6
- uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: teaport-brain-deb
path: |
Expand All @@ -207,6 +145,29 @@ jobs:
if-no-files-found: error
compression-level: 0 # already compressed

brain-deb-check:
# The package itself, installed and run (the brain's code, as root too). A release's
# .deb, its hash for the signing laptop and the same checks of it are release-deb.yml's.
needs: brain-deb
runs-on: ubuntu-24.04-arm
timeout-minutes: 30
permissions:
contents: read
steps:
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
with:
ref: ${{ github.event.pull_request.head.sha || github.sha }}
persist-credentials: false
- uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
with:
name: teaport-brain-deb
path: dist
- name: The .deb
run: echo "DEB=$(ls dist/teaport-brain_*.deb)" >> "$GITHUB_ENV"
- uses: ./.github/actions/brain-deb-check
with:
deb: ${{ env.DEB }}

plugin:
runs-on: ubuntu-latest
steps:
Expand Down Expand Up @@ -301,12 +262,22 @@ jobs:
done
- name: Installer dry-run (voice-only path)
# No Jetson, no sandbox, not a TTY: exercises the full dry-run without touching the box.
run: TEAPORT_ALLOW_NON_JETSON=1 TEAPORT_MANIFEST_URL="$PWD/manifest/stable.json" bash install.sh --dry-run
# The checkout's manifest is verified with the .sig beside it. Read unsigned only while
# the tree has no stable.json.sig at all (before signing was turned on). Once it has
# one, a manifest PR fails here until its new .sig is committed: the .sig in the tree
# is the previous release's, and does not verify the edited file. That is by design.
run: |
unsigned=0; [ -f manifest/stable.json.sig ] || unsigned=1
TEAPORT_ALLOW_NON_JETSON=1 TEAPORT_MANIFEST_URL="$PWD/manifest/stable.json" \
TEAPORT_MANIFEST_UNSIGNED="$unsigned" bash install.sh --dry-run
- name: Installer dry-run (--install-agent)
# The agent-install plan (Node from NodeSource, the pinned OpenClaw, its onboarding)
# in front of the same full dry-run; nothing is installed, so the rest is voice-only.
# The checkout's manifest, verified as in the step above.
run: |
out="$(TEAPORT_ALLOW_NON_JETSON=1 TEAPORT_MANIFEST_URL="$PWD/manifest/stable.json" bash install.sh --install-agent --dry-run)"
unsigned=0; [ -f manifest/stable.json.sig ] || unsigned=1
export TEAPORT_ALLOW_NON_JETSON=1 TEAPORT_MANIFEST_URL="$PWD/manifest/stable.json" TEAPORT_MANIFEST_UNSIGNED="$unsigned"
out="$(bash install.sh --install-agent --dry-run)"
printf '%s\n' "$out"
for want in 'agent: installing OpenClaw (openclaw@' 'npm install -g openclaw@' '--allow-scripts=openclaw,' 'openclaw onboard --non-interactive' '--auth-choice skip' '--skip-daemon'; do
case "$out" in *"$want"*) ;; *) echo "::error::the --install-agent dry-run does not show: $want"; exit 1 ;; esac
Expand All @@ -320,10 +291,16 @@ jobs:
if [ "$rc" != 2 ]; then echo "::error::$what: exit $rc, not 2 (a usage error)"; printf '%s\n' "$err"; exit 1; fi
case "$err" in *"$words"*) ;; *) echo "::error::$what: not refused for that reason"; printf '%s\n' "$err"; exit 1 ;; esac
}
export TEAPORT_ALLOW_NON_JETSON=1 TEAPORT_MANIFEST_URL="$PWD/manifest/stable.json"
refused "--only brain --install-agent" "--install-agent is part of a full run" bash install.sh --only brain --install-agent --dry-run
refused "--only license --install-agent" "--install-agent is part of a full run" bash install.sh --only license --install-agent --dry-run
refused "TEAPORT_INSTALL_AGENT=nemoclaw" "unknown agent 'nemoclaw'" env TEAPORT_INSTALL_AGENT=nemoclaw bash install.sh --dry-run
- name: Installer dry-run (--only brain)
# The incremental brain update path. Off-appliance it warns that there is no
# install to update and shows the plan anyway: stage, self-check, swap, restart.
run: bash install.sh --only brain --dry-run
# Against the checkout's manifest, as the step above, so CI reads nothing from the
# bucket: verified with the .sig beside it, unsigned only while the tree has none, and
# failing on a manifest PR until its new .sig is committed (as the step above).
run: |
unsigned=0; [ -f manifest/stable.json.sig ] || unsigned=1
TEAPORT_MANIFEST_URL="$PWD/manifest/stable.json" TEAPORT_MANIFEST_UNSIGNED="$unsigned" \
bash install.sh --only brain --dry-run
Loading
Loading