Files
waoziandClaude Opus 5.5 6f6d19f24d Rename account sync to Mesh
The codex-daochi-client-mesh-client-rename integration, committed as that
task staged it: mesh_client replaces daochi_client, account storage and
tests move to the Mesh names, and docs, locales and CI follow, with
existing accounts, encrypted records and local storage kept compatible.
The task stopped before its dependency versions were pushed; the next
commit moves Breeze to the pushed pins it needs.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-18 13:14:02 -03:00

148 lines
6.1 KiB
YAML

name: App packages
on:
push:
branches: [master]
paths:
- 'apps/**'
- 'assets/**'
- 'locales/**'
- 'themes/**'
- 'scripts/prepare-package-assets.py'
- 'src/**'
- 'scripts/build-apps.sh'
- 'scripts/build-node-apps.sh'
- 'scripts/package-release.py'
- 'scripts/practice_content.py'
- 'scripts/practice_media.py'
- 'design/tai-chi/narration*.json'
- 'design/tai-chi/text/**'
- 'scripts/generate-package-versions.py'
- 'scripts/update-package-version.py'
- 'scripts/check-package-versions.py'
- 'scripts/check-package-publishers.py'
- 'scripts/package-manifests.py'
- 'tests/package_manifests_test.py'
- 'tests/package_upload_test.py'
- 'tests/package_versions_test.py'
- 'tests/package_workflow_test.py'
- 'tests/package_release_test.py'
- 'tests/package_manager_host.c'
- 'tests/package_manager_behavior.zi'
- 'ziran.lock'
- '.github/workflows/packages.yml'
workflow_dispatch:
permissions:
contents: read
concurrency:
group: inbe-package-publishing
cancel-in-progress: false
jobs:
packages:
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4.4.0
- uses: ./.github/actions/ziran-packages
- name: Install signing and test dependencies
run: |
sudo apt-get update && sudo apt-get install -y python3-cryptography python3-fonttools
.github/scripts/install-apt-packages.sh .github/apt/test-packages.txt
- name: Build independent packages and check signatures
run: |
make package-version-test
make package-workflow-test
make package-manifest-test
make package-upload-test
make apps node-apps build-laws
python3 tests/package_release_test.py
- name: Run new packages in the last released app
run: python3 tests/package_compat_test.py --skip-forward
env:
GITHUB_TOKEN: ${{ github.token }}
- name: Configure publisher
id: publisher
env:
SIGNING_KEY: ${{ secrets.INBE_PACKAGE_SIGNING_KEY }}
KEY_ID: ${{ vars.INBE_PACKAGE_KEY_ID }}
SSH_KEY: ${{ secrets.INBE_NODE_SSH_KEY }}
SSH_HOSTS: ${{ secrets.INBE_NODE_KNOWN_HOSTS }}
TARGET: ${{ secrets.INBE_NODE_SSH_TARGET }}
STORE: ${{ secrets.INBE_NODE_PACKAGE_STORE }}
run: |
python3 - <<'PY'
import os
from pathlib import Path
signing = all(os.environ.get(name) for name in ('SIGNING_KEY', 'KEY_ID'))
configured = signing and all(os.environ.get(name) for name in ('SSH_KEY', 'SSH_HOSTS', 'TARGET', 'STORE'))
with open(os.environ['GITHUB_OUTPUT'], 'a') as output:
output.write('signing=' + str(signing).lower() + '\n')
output.write('configured=' + str(configured).lower() + '\n')
if signing:
directory = Path(os.environ['RUNNER_TEMP']) / 'inbe-publisher'
directory.mkdir(mode=0o700)
files = [('publisher.pem', 'SIGNING_KEY')]
if configured:
files += [('node.key', 'SSH_KEY'), ('known_hosts', 'SSH_HOSTS')]
for filename, name in files:
path = directory / filename
path.write_text(os.environ[name] + '\n')
path.chmod(0o600)
if signing and not configured:
print('Node deployment is not configured; signed releases will be archived for installation on the node.')
elif not signing:
print('Signing is not configured; unsigned build artifacts will be archived without publication.')
PY
- name: Sign app releases
if: steps.publisher.outputs.signing == 'true'
env:
KEY_ID: ${{ vars.INBE_PACKAGE_KEY_ID }}
run: |
python3 scripts/check-package-publishers.py
python3 scripts/package-release.py --store build/package-releases \
--key "$RUNNER_TEMP/inbe-publisher/publisher.pem" --key-id "$KEY_ID"
- name: Sign and publish to Waozi's Mesh node
if: steps.publisher.outputs.configured == 'true'
env:
KEY_ID: ${{ vars.INBE_PACKAGE_KEY_ID }}
TARGET: ${{ secrets.INBE_NODE_SSH_TARGET }}
STORE: ${{ secrets.INBE_NODE_PACKAGE_STORE }}
run: |
export INBE_SSH_IDENTITY="$RUNNER_TEMP/inbe-publisher/node.key"
export INBE_SSH_KNOWN_HOSTS="$RUNNER_TEMP/inbe-publisher/known_hosts"
python3 scripts/package-release.py --store build/package-releases \
--key "$RUNNER_TEMP/inbe-publisher/publisher.pem" --key-id "$KEY_ID" \
--ssh-target "$TARGET" --remote-store "$STORE" \
--verify-origin https://api.waozi.xyz
# Each app the node offers publishes on its own when its ledger names a
# newer release; the node keeps its newest three releases for rollback.
- name: Publish new releases of the apps the node offers
if: steps.publisher.outputs.configured == 'true'
env:
KEY_ID: ${{ vars.INBE_PACKAGE_KEY_ID }}
TARGET: ${{ secrets.INBE_NODE_SSH_TARGET }}
STORE: ${{ secrets.INBE_NODE_PACKAGE_STORE }}
run: |
export INBE_SSH_IDENTITY="$RUNNER_TEMP/inbe-publisher/node.key"
export INBE_SSH_KNOWN_HOSTS="$RUNNER_TEMP/inbe-publisher/known_hosts"
python3 scripts/package-release.py --node-apps --store build/package-releases \
--key "$RUNNER_TEMP/inbe-publisher/publisher.pem" --key-id "$KEY_ID" \
--ssh-target "$TARGET" --remote-store "$STORE" \
--verify-origin https://api.waozi.xyz
- name: Archive packages
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
with:
name: inbe-app-packages
path: |
build/inbe.zx
build/apps/*.zx
build/node-apps/*.zx
build/package-releases/
if-no-files-found: error
- name: Remove signing material
if: always()
run: rm -rf "$RUNNER_TEMP/inbe-publisher"