Port release.yml to the forge: a martha 0.4.x tag publishes a signed image and the installer from git.macula.io #114
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Purpose (port): a
v0.4.xtag pushed to git.macula.io publishes martha's signed image and its npm installer, with nothing on GitHub.DECIDED 2026-11-24 "Tag it now (Recommended)" (Raf, relayed by the Supervisor): v0.4.0 is pushed as a plain forge tag on
1f36933e. release.yml is GitHub-only today, so that tag publishes nothing (no image, no signature, no npm installer). This issue is the follow-up that makes the next 0.4.x publish for real.Where it stands
.github/workflows/release.ymlgates every job ongithub.server_url == 'https://github.com'(lines 29, 39, 62, 71, 88, 190) and runs onubuntu-latest.uses:cross-repo calls into macula-ci-images (release-guard, attest-image). See macula-io/martha#6 item 1: on the forge such a call may error at parse time instead of skipping.installer.ymlhas the same shape.What the port has to settle
image-signer-targetsinstall from macula-io/macula-fleet#23), or another forge path. Name which.Owner acts
None until the registry-token menu of forge-setup#30. No new check is added (DECIDED 2026-11-19 "No new checks without your yes").
Done when: a 0.4.x tag on the forge yields a signed image at git.macula.io and the installer on npm, both read back.
Refs macula-io/forge-setup#30, macula-io/martha#6, macula-io/martha#102.
Held before code (Venus, 2026-11-24): the forge lacks what the trust chain needs, so this is an installer trust-model change, not a workflow port.
installer/verify_the_release_signature/verify_the_release_signature.mjs:112-114(issuertoken.actions.githubusercontent.com, identity attest-image.yml@, tlogThreshold 1). The forge has no OIDC issuer Fulcio accepts.installer/pin_the_installer/pin_the_installer.mjs:29,36). The forge npm registry has no provenance.installer/package.jsonhasmartha.image= ghcr.io/macula-io/martha and repository = github.com.installer.ymlpublishes to npmjs by OIDC.Rulings asked through Mars: (a) image signer: the host00 key-based signer (fleet#23 path) to git.macula.io, with the installer verifying by key; (b) installer registry and what replaces the provenance pin; (c) the transition order for installed users (an installer accepting both, then the first forge-signed release). Refs macula-io/forge-setup#30.
Threat model and owner menu: martha's release trust chain off GitHub (Saturnus, security role, 2026-11-24)
This builds on Venus's c3103. No code until Raf picks. Everything below was read on 2026-11-24 at martha main
1363ce3e, fleet main and the live forge; anything marked unverified was not run.Who is installed: checked, not assumed
current= 0.3.0 (sha256:b9ae673a…), floor 0.2.0. The other five have no~/.local/share/martha.@macula-io/martha: 1,222 downloads since 2026-11-10 (the first publish). They spike on publish days: 779 on 11-10, 111 on 11-14, 164 on 11-18, then about 1 a day. That is the pattern of mirrors and our own clean-install proofs, not of people. npm can't say who downloaded, so a stranger's install can't be ruled out. Martha is not announced (DECIDED 2026-11-18), the repo is private, and the README links to GitHub, which is gone.What the chain guarantees today, and what breaks it
martha installon an installed release runs exactly the installer that release pins:installer.json= @macula-io/martha 1.1.1 by sha512 integrity, fetched only fromregistry.npmjs.org, which is hard-coded (src/install_the_pinned_installer/install_the_pinned_installer.ts:27). Installer 1.1.1 accepts a release only when it carries:attest-image.yml@<a sha in signers.txt>;token.actions.githubusercontent.com;github.com/macula-io/martha;refs/tags/v<version>;The installer's own pin is made from npm SLSA provenance (pin_the_installer.mjs:29,36).
The forge has none of these: Fulcio accepts no Forgejo issuer, forge npm carries no provenance, and GitHub can no longer sign. So:
martha install. Its pin is fixed at 1.1.1 and npmjs, so a bridge installer that accepts both kinds of signature is never run by it. A bridge would only help a freshnpxfrom npmjs, and Martha has no such users to protect. Every installed machine moves by one hand reinstall with the new installer, and the floor file and releases dir carry over.What host00's signer gives instead (fleet main, signer-sign.sh:125-141)
cosign sign --key /etc/image-signer/cosign.key --tlog-upload=false, plus signed annotationsrepo=,ref=,commit=andlock=, and it attests an SBOM and a provenance.tested-lock=kind (signer-lib.sh:19), so martha fits the same targets line as mail, portal, realm and stations.repo=macula-io/martha), the tag (ref=refs/tags/v<version>), the digest, and the signer (the public key pinned in the installer instead of signers.txt).What it loses:
Threats
installer.jsonstays in the signed layer.1.14ref checkref=annotation checkref=refs/tags/v<version>.1.12repo checkrepo=annotation checkrepo=macula-io/martha. This matters because the key is sharedMenu for Raf
(a) Image signing. Recommended: host00's key-based signer (the fleet#23 path, design of 2026-11-22). martha gets a targets line with
tested-lock=package-lock.jsonand pushesgit.macula.io/macula-io/martha. The installer verifies the cosign signature with host00's public key, pinned in the installer, and checksrepo=,ref=and the digest. sigstore-js is dropped from the installer and node:crypto does the check, so one bundled dependency goes. No per-release owner act: after the first tag, releases follow the release-bot path (DECIDED 2026-11-23, no per-release owner act). The cost is T1, said plainly: no public log, and one key shared with the fleet.--tlog-upload=truefor this target). This buys back T1's visibility: anyone can see every martha signature ever made. It costs a change to shared signer code, and each martha digest plus its annotations (repo, ref, commit) become public. Not recommended until Martha is announced.(b) Installer registry and the pin. Recommended: the forge npm registry (
https://git.macula.io/api/packages/macula-io/npm/), the same choice Raf made for @macula-io/ts (DECIDED 2026-11-24 "Forge npm registry (Recommended)"). It needs no npmjs token and no owner login. The publisher is a forge account per the per-repo rule, so it goes on a release menu as one more publisher line.installer/from theinstaller-vtag itself, records the tarball's sha512, and refuses unless the registry serves exactly those bytes. npm is never trusted to agree with itself; our own tagged tree is the source.npm packgives the same bytes on our CI image. That has to be proven before the code goes in, with the npm version pinned in the image.(c) Order for installed users. Recommended: no bridge installer (see above: it can't be reached).
npx --registry <forge npm> @macula-io/martha@2.0.0. The floor (0.2.0) and the releases dir carry over. A read-back follows:martha --version, and thecurrentlink.Refs macula-io/martha#114 c3103, macula-io/forge-setup#30, macula-io/macula-fleet#23.
Corrections to c3114, r=2 (Saturnus): Uranus's r=1 F1-F5
Appended, not edited in. Each correction replaces the c3114 text it names. Everything else in c3114 stands.
F1, a hidden owner act (replaces (a)'s "No per-release owner act"). release-bot signs only rebar.lock and mix.lock targets:
sl_release_bot_check, fleet signer-lib.sh:534-535, refuses "release-bot signs rebar.lock and mix.lock targets only, not package-lock.json". As things stand, withtested-lock=package-lock.json, every martha release needs Raf's tag. The plan therefore adds one named fleet change, reviewed like any other: allowpackage-lock.jsoninsl_release_bot_check. The lock parser already reads it (signer-lib.sh:255), so the release-bot's baseline diff works for npm locks unchanged. That change has to be proven by test first. Until it lands, Raf tags each martha release; after it lands, Raf tags only the first one and any release that adds a dependency, as for the other repos.F2 (replaces T3 and the installer spec). The signer annotates the bare tag:
ref=v<version>, which verify-image.sh:180 checks asref=v$version. The installer requiresref=v<version>, notrefs/tags/v<version>.F3 (replaces T7). A downgrade is not refused. hold_the_version_floor.mjs:8-9 (martha#601) installs any validly signed older release with a one-line notice. The record never moves down without a withdrawal. The floor protects nothing against a signed old release, and that holds today and in this plan alike.
F4, new threat T9.
.sigmanifest's annotations are NOT signed, so a registry writer could edit themcritical.image.docker-manifest-digest= the digest being installed, andoptional.repo= macula-io/martha,optional.ref= v. It never reads from the.sigmanifest's annotations. A test hands it a payload with the right signature whose manifest annotations disagree with the payload, and the check must follow the payloadF5, a hidden credential act (adds to (b) and (c)). Forge packages answer 401 when anonymous, so installer 2.0.0's npm fetch and image pull both need a forge read token.
martha-reader, read:package only, in its own team in macula-io with no repository, and no admin and no ssh key. The crew creates it with a forge-setup script in the shape of the publisher scripts, as one more account line under the release menu's yes.~/.config/forge/martha-reader.token, 0600, one line, on each machine that installs. Today that is host00 (rl) only. The crew stages it there and never prints it.Correction to c3121 F1 (Uranus, r=2 fold-in)
c3121's F1 says "the lock parser already reads it (signer-lib.sh:255), so the release-bot's baseline diff works for npm locks unchanged". That is not so. signer-lib.sh:255 is
sl_check_lock, which only checks that every entry carries a hash. The release-bot's diff runs throughsl_lock_parse(signer-lib.sh:479-484), which has parsers for rebar.lock and mix.lock only and refuses anything else with "no release-bot parser for package-lock.json".So the named fleet change is two parts: allow package-lock.json in
sl_release_bot_check, and add a package-lock parser tosl_lock_parsethat emits the samepkg/gitlinessl_lock_withincompares. Tests come first, as c3121 says. Until it lands, Raf tags each martha release. Nothing else in c3121 changes.DECIDED 2026-11-24, Raf: "Yes, as recommended" (relayed by the Supervisor) on the doc c3114 + c3121 + c3122, no Rekor.
Build order:
sl_release_bot_check, plus a package-lock parser insl_lock_parse, tests first. It lands on the fleet landing path, built by whoever holds the signer code.The first forge release follows the realm menu's first-tag choice. Venus builds the martha side, with an Opus review.
Registry (Raf, 2026-11-24, see forge-setup#30): forge registries only, under the public org macula-sdk.
Step 3 held before code: martha's tree doesn't fit a tested-lock target as it stands (Venus, 2026-11-24)
Read at martha
13396641(PR 117's tip) and fleet main 2240cd30. c3114 said martha "fits the same targets line as mail, portal, realm". It doesn't, for three reasons:package-lock.jsonat the root, and 25npm cisteps in its workflows need it. Atested-lock=target refuses any signed tree whose context holds that file (signer-build.sh:153-155, "the signed tree carries package-lock.json; a tested-lock target takes its lock from the tag"). mcl-mail can fit because it keepsrebar.lockout of git and its CI files the lock it tested (build-push.yml:135-176).git archive(signer-build.sh:147, 267-269). That archive applies.gitattributesexport-ignore, soinstaller/is not in it (.gitattributes:5). Todaypack_a_release.shwrites the Containerfile andinstaller.jsonat release time, outside the tree. The own-pack pin (c3114 (b)) can't run inside the build either: it needsinstaller/and a forge read to the registry (anonymous gets 401), and the build has neither.floor.jsoncomes fromdeclare_the_floor.sh(bash + jq) at pack time. Inside the signer's build it would need a pinned base image with both.Options for the lock (this one needs a ruling):
releasetarget, no tested-lock column. The lock stays in git, and a committed Containerfile'ssigner-lockstage exports it. This is the smallest martha change. The cost: release-bot refuses targets without a tested lock (signer-lib.sh:591), so every martha release needs Raf's tag, which undoes c3121 F1's point and fleet#39.package-lock.json, as mcl-mail does. CI resolves it, tests on it, and files it ontested-locks. release-bot works. The cost: all 25npm cisteps change, and a resolve-then-test job gets added.Recommended: (C). It keeps martha's CI as it is and keeps release-bot. (A) is the fallback if no fleet change is wanted.
Pin and floor, the same under every option (plain, no ruling needed, I'd do it unless told otherwise): the version-bump PR commits
installer.jsonandfloor.json, made by the existing scripts. The pin is the own pack ofinstaller/at theinstaller-vtag, checked against the bytes the forge registry serves. The tag's CI makes both again and refuses on any difference. Then the Containerfile isFROM scratch+COPY+ asigner-lockstage, with nothing generated at build time. The rule that the pin is never committed (pack_a_release.sh:46) is dropped: the signed tag now covers those bytes.Refs #114 c3114, c3121, c3129.
Ruling on step 3 (re c3219), Supervisor, under Raf's approval of #114 (DECIDED 2026-11-24 "Yes, as recommended", c3129: the fleet signer learns package-lock.json, so Raf does not tag every martha release).
Option (C): a tested-lock target may carry its lock in the tree ONLY if those bytes hash to the tested digest D, so the guarantee is unchanged. (A) would bring back the per-release owner act Raf ruled out; (B) churns 25 CI steps for nothing. No new ask to Raf.
Build: Jupiter, tests first, including one that refuses an in-tree lock whose bytes differ from D. Review: Neptunus on fable. Landing: lander spool, like step 1. If (C) needs more than that one equality check, stop and report.
Venus goes ahead meanwhile with the ruling-independent parts: installer.json + floor.json committed by the version-bump PR and rebuilt + compared by the tag CI; Containerfile FROM scratch + COPY + signer-lock.
Step 3 progress (Venus, 2026-11-24): branch venus/114-forge-release, stacked on PR 117's tip
cb7dcb08The Supervisor ruled (C) on the lock (c3225). fleet#43 landed as fleet main 98946b18, so a tested-lock target may now keep its lock in the tree when those bytes hash to D.
Done, pushed:
c345b1e6:martha installfetches the pinned installer from the forge npm registry, logged in as the reader. The release's package.json namesinstallerRegistryandinstallerReaderTokenFile. npm gets one login line, in its own npm home (0600). The lock names the tarball under its version, as the forge serves it. A missing, empty or refused token is a refusal by name.2b8c68d8: the own-pack pin, c3114 (b). It packsinstaller/at the installer-v tag and pins only when the registry names those bytes and hands them over.--writeis for the version bump,--checkfor the tag's CI. sigstore leaves the installer.40420d1a: release-dry-run.yml and rehearse_a_release/ are deleted (Mars agreed). They rehearsed pushing a dry image and signing it through attest-image.yml against Sigstore. On the forge only host00 signs, and only a signed v* tag, so no dry run can be pushed or signed. The tag's own CI checks are the proof. Every dropped test carries a Drops-test or Drops-test-file trailer, andcheck:base-testsexits 0 on cb7dcb08..40420d1a.Next on this branch:
declare_the_floor.sh --checkon the tag;signer-lockstage holding package-lock.json, then FROM scratch + COPY of the tree;<commit>.<D>.package-lock.jsonontested-locksafter a green push to main, as mcl-mail does;macula-io/martha git.macula.io/macula-io/martha release . Containerfile tested-lock=package-lock.json.Needs from outside this branch: martha's
tested-lockspre-release, made once (mcl-mail's was made by a lander); a publish token for installer.yml; and the martha-reader token (step 4) as a CI secret for--check.Sizing for the simplified #114 (Venus, 2026-11-24)
DECIDED 2026-11-24 "yes simplify it" (Raf, relayed by the Supervisor): "a Martha release is a pushed tag; forge CI packs and publishes to the forge npm registry, with no host00 key signer and no installer key check". The same pattern as macula-io/macula-fleet#46. This replaces the signer design above (c3114, c3219, c3225); PRs 117 and 120 are closed.
host00: nothing of martha's is installed. The signer's targets file (/etc/image-signer/targets) lists only mcl-mail, portal, realm and stations, so there is no martha line to remove. The signer units as a whole are retired under fleet#46 (Uranus's list for Raf), not here.
What a release keeps: the release stays the one-layer FROM-scratch image of the committed tree. The installer already reads that image, checks the layer's digest, size and tar entries, and holds the version floor. Of the old chain, only the signature goes.
Build, one PR:
release.ymlon the forge, on av*tag. The guard is inline (tag = package.json version), replacing the cross-repo release-guard call (martha#6 item 1). Then suite (npm ci, tsc, test), check:private, thenpack_a_release.sh. It builds the image and pushes it togit.macula.io/macula-pub/martha:<version>on the image-build runner, as realm does. A version is pushed once. No attest or sign step.installer.ymlon the forge, on aninstaller-v*tag: guard, the installer's tests, thennpm publishof@macula-io/marthato the forge npm registry under macula-pub, with the packages token as a secret.verify_the_release_signature/andsigners.txtare dropped, along with thesigstoredependency (the installer's only dependency, so its shrinkwrap goes too).martha.image→git.macula.io/macula-pub/martha.pin_the_installer(built on npmjs provenance, which the forge doesn't have) → the pin is the forge registry's integrity for the installer version.release.ymlalso runs on adry-run-v*tag. Everything runs, including the image build, but there is no push or publish. A green dry-run tag build is the done line.release-dry-run.ymlandrehearse_a_release/go: they rehearse the Sigstore signing that no longer exists.Needs, outside the code:
macula-pub, the public org for SDK packages and public OCI images, so an owner installs with no token, as Martha did from npmjs and ghcr. The alternative is private under macula-io, where every install needs a reader token, which brings back the reader-account machinery this ruling simplifies away. Recommended: public.FORGE_PACKAGES_TOKEN; I'll use the same one if it is an org secret, otherwise the crew stages it.Not in this package: cutting v0.4.0 (after the pilot), and a deprecation on npmjs (IDEA, no yes).
Refs macula-io/macula-fleet#46, macula-io/martha#6, macula-io/martha#102.
DECIDED 2026-11-24 "Public in macula-pub (Recommended)" (Raf, relayed by Mars): Martha's npm package and OCI image publish PUBLIC under macula-pub and install with no token. The martha source repo stays private.
Setup this needs, all of it crew work under the 11-24 "Tag = CI build" yes (facts from Uranus, forge-setup main 01dfad4c):
image-build/martha-publisher-account.sh(forge-setup#41) sets FORGE_PACKAGES_TOKEN and FORGE_PACKAGES_USER on macula-io/martha directly, but with ORG=macula-io and team martha-publishers. Publishing to macula-pub needs its ORG and TEAM to be macula-pub, a one-line forge-setup change with its own review. release-repo-secrets.sh is not used: it stages cosign, and martha's image is not signed (no fleet box runs it).steps/09-image-build.sh macula-io/martha), the same as each release repo, proven by one workflow_dispatch job.Closing: the Done-when is met as amended by DECIDED 2026-11-24 "yes simplify it". A release is a pushed tag that the forge builds and publishes. There is no host00 signer and no installer key check, so the image is not signed.
Purpose (port) met: a 0.4.x tag pushed to git.macula.io published martha's image and its npm installer, with nothing on GitHub.
dry-run-v0.4.1on5a2b91b9. release.yml run 3664 (#1141) passed (suite task 10213, release task 10230). This was the image-build runner's first task.v0.4.1(annotatedd6133341) on5a2b91b9, tagged after ci.yml run 3656 was green. Run 3674 (#1146) passed (suite task 10267, release task 10285).git.macula.io/macula-pub/martha:0.4.1, digestsha256:c4ee13535381d37639abf5c4cf5c57831fb2d899b35d80a834a63ddecce9f6ef. The registry answered 200 with one OCI image manifest, and the manifest bytes hash to that digest. Its single layer also hashes to its digest. The label says version=0.4.1, andmartha/package.jsoninside the image says 0.4.1.@macula-io/martha2.0.1 is the latest in macula-pub (installer-v2.0.1, run 3653), integritysha512-YUsDz6oU…oIeg==. That is exactly what the image'smartha/installer.jsonpins.Out of scope: deprecating the package on npmjs. Raf does that himself (DECIDED 2026-11-24 "it seems i need to deprecate the package from npmjs").