feat(admin): install the companion and media apps from the admin script #131
No reviewers
Labels
No labels
bug
duplicate
enhancement
future
help wanted
invalid
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
albert/shepherd-launcher!131
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "feat/admin-installs-android-apps"
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?
shepherd-admin apps install companion|mediafetches an APK and pushes itonto an attached Android device over adb. Where the APK comes from follows
how shepherd itself was installed, which is the point: a source checkout
builds the app's own Gradle project, so you install what you just wrote,
while a packaged install downloads the release asset matching its VERSION
from Forgejo and verifies it against the .sha256 sidecar release.yml
uploads beside every asset.
--source/--releaseoverride the guess;--versionand--apkcover the rest.It lives in scripts/lib/admin.sh so both entrypoints get it —
shepherdfrom a checkout,
shepherd-adminfrom the .deb — which is what makes thesource/packaged split expressible in one place.
The details that matter:
sudo run turns an authorised phone into
unauthorized, and a root Gradlerun leaves root-owned build output in the checkout. The command refuses
sudo and says why.
phone shouldn't cost a Gradle run — and a HOST:PORT serial is connected
first, which is how the Fire TV sticks are reached.
be installed on a family device. Cached APKs are re-verified before
reuse, so a truncated download self-heals.
F-Droid-signed copy) is translated into the
adb uninstallit needs —with a warning, for the companion app, that this erases the admin records
and claim tokens for every device that phone administers.
and a build log mixed into it becomes the filename.
adb and curl join the .deb as Suggests rather than Depends — a kiosk that
never has a phone plugged into it shouldn't carry the Android platform
tools — and both are checked at call time with the apt line that fixes it.
Verified against the real release server and a phone on USB: the source
build for both apps (including the media app's cargo-ndk cross-compile),
the release download for 0.3.5 and 0.3.6, and a packaged layout simulated
under a fake /usr/lib/shepherd, which downloaded, checksum-verified, and
installed shepherd-media 0.3.6 — release-signed with the certificate
dist/fdroid pins, launching cleanly on the device. Failure paths exercised
too: 404, corrupted cache, unknown serial, sudo, missing adb/curl.
Co-Authored-By: Claude Opus 5 (1M context) noreply@anthropic.com
Claude-Session: https://claude.ai/code/session_014RTqj36qW8Vax6GZ86pBAo