Skip to content

ci(mobile): sign Android packages when keystore secrets exist - #155

Merged
BerryUIKI merged 1 commit into
devfrom
feature/android-signing
Nov 4, 2026
Merged

BerryUIKI merged 1 commit into
devfrom
feature/android-signing

Conversation

@BerryUIKI

Copy link
Copy Markdown
Owner

Summary

  • Adds an optional signing path to the Android Package workflow.
  • When ANDROID_KEYSTORE_BASE64 (plus password/alias/key-password secrets) exists, the job decodes the keystore, installs scripts/android-signing.init.gradle as a Gradle init script, builds, then runs apksigner verify --print-certs and fails if the APK is not signed.
  • Without the secret, behavior is unchanged: unsigned APK/AAB, artifact taleno-android-unsigned.

Why an init script

tauri android init regenerates src-tauri/gen/android on every run, so patching the generated build.gradle.kts would not survive CI. Gradle loads every ~/.gradle/init.d/*.gradle automatically; the workflow copies the script there only when signing is configured, and the script no-ops without ANDROID_KEYSTORE_PATH.

Required secrets (documented in docs/MOBILE_DEVELOPMENT.md)

ANDROID_KEYSTORE_BASE64, ANDROID_KEYSTORE_PASSWORD, ANDROID_KEY_ALIAS, ANDROID_KEY_PASSWORD.

Verification status

  • The unsigned path and workflow syntax are verified by this PR's own run.
  • The signed path is not verified: the repository has no keystore. The apksigner verify gate is there so the first signed run fails loudly if the init script does not take effect, instead of silently uploading an unsigned APK.

The package workflow now decodes a base64 keystore from repository secrets,
installs a Gradle init script that configures the release signing config,
builds as before, and verifies the APK with apksigner when signing is on.

Without the keystore secret nothing changes: the job still produces
unsigned artifacts. Signing itself is unverified until a real keystore is
configured.
@BerryUIKI
BerryUIKI merged commit 9b5769c into dev Nov 4, 2026
5 checks passed
@BerryUIKI
BerryUIKI deleted the feature/android-signing branch November 4, 2026 02:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant