Repository navigation
feat(pm-console): every Android build GitHub makes is signed and released, where the key is - #12940
Merged
Merged
Conversation
…ased, where the key is GitHub Actions builds the app on every change, but does not hold the signing key, so its build was unsigned and nothing was released: the release waited for someone to put the key into GitHub by hand. The key is on the pm-stack host and stays there, so the signing now happens there, by itself. - android/release-built.sh (new), run every ten minutes by pm-console-android-release.timer: takes the newest unsigned build this repository made on main, signs it on the host (sign.sh, which refuses a result that does not carry the certificate the site lists), releases it (release.sh: the numbered release and the fixed address), and puts it where the console serves the app from. When the newest build is already released it asks GitHub one question and does nothing. The key is read by apksigner there and goes nowhere; what leaves is the signed APK, which is public. - Only this repository's own finished build on main, made by a push or by hand, is ever signed: never a pull request, another branch, a fork or another repository's run, whatever it is called. - A failure (wrong certificate, GitHub not answering, the release not made) leaves the release, the served app and the record as they were, and the next run tries again. The unit shows on the Services screen and in notifications like any other. - The workflow's artifact now carries the version the build was made as, so whoever signs it releases it under that version. - install.sh installs the timer and redeploy.sh watches its units, so the host picks all of this up from the merge with nobody at it. - release.sh can be told how gh is run (fleet gh on the host), and says in the release where the build was signed. - If GitHub's environment is given the key, the workflow signs and releases by itself as before, and the host finds nothing to do. The test (release-built.test.sh, in the scheduled pm-stack tests) runs the real three scripts against stand-ins for gh, fleet and apksigner. It found one fault before this was committed: with plain gh, the wrapper called itself for ever. Seventeen planted faults are each caught. Not checked here: the timer on the host itself, and apksigner's own signing. Both are checked by the release it makes: the APK it publishes is verified against signing-fingerprint.txt with apksigner from here. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01YLT5K1QVuzZjfWGFhXSSNF
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 2 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. |
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
GitHub Actions builds the Android app on every change, but does not hold the signing key, so its build was unsigned and nothing was ever released: the release waited for someone to put the key into GitHub by hand. The key is on the pm-stack host and stays there, so the signing now happens there, by itself.
What changes
android/release-built.sh(new), run every ten minutes bypm-console-android-release.timer: takes the newest unsigned build this repository made onmain, signs it on the host (sign.sh, which refuses a result that does not carry the certificate the site lists), releases it (release.sh: the numbered release and the fixed address), and puts it where the console serves the app from. When the newest build is already released it asks GitHub one question and does nothing.apksigneron the host and goes nowhere. What leaves is the signed APK, which is public.main, made by a push or by hand, is ever signed: never a pull request, another branch, a fork or another repository's run, whatever it is called.install.shinstalls the timer andredeploy.shwatches its units, so the host picks this up from the merge with nobody at it.Checked
release-built.test.sh(added to the scheduled pm-stack tests) runs the realrelease-built.sh,sign.shandrelease.shagainst stand-ins forgh,fleetandapksigner: twelve situations. It found one fault before this was committed: with plaingh, the wrapper called itself for ever.release.test.shstill passes;bun test193 pass; shfmt, shellcheck, actionlint and the CI policy check are clean.Not checked here
The timer on the host itself, and
apksigner's own signing. Both are checked by what this produces: once the host has released a build, I verify the published APK againstsigning-fingerprint.txtwithapksignerfrom outside.Generated by Claude Code
Open in [code]smith · Need help on this PR? Tag
@codesmith-botwith what you need.