Blog

    CI/CD for Mobile Apps: Signing Keys, Store Build Tracks and Phased Releases

    By GauravSeptember 6, 20269 mins read
    On this page

    CI/CD for mobile differs from web delivery in three places: every build must be signed, every release passes through an app store, and a shipped version stays on devices until users update. A pipeline that ignores those three keeps the same manual steps and the same release-day surprises.

    Startup founders and engineering leaders shipping Android and iOS apps will find where signing keys should live, how builds should move through store test tracks, and how staged and phased releases limit the damage of a bad version.

    What is CI/CD for mobile apps?

    CI/CD for mobile apps is a pipeline that builds, tests and signs every change, uploads release candidates to the app stores' test tracks, and promotes a tested build to production through a staged rollout. Agnotic Technologies sets it up so no release depends on one developer's laptop or one person's signing key.

    Shipping mobile releases by hand?

    We build the pipeline, move signing into it and set up test tracks and rollouts.

    The difference from web delivery is that you cannot roll back a binary that is already installed on a phone. Every part of a mobile pipeline is arranged to catch problems before a build reaches most users.

    Where should signing keys live?

    Signing keys should live in the pipeline's secret store or a managed signing service, never on a developer's machine or in the repository. The pipeline signs; people do not.

    Google's Play Console Help says that with Play App Signing, Google manages and protects the app signing key while the developer signs uploads with a separate upload key. If the upload key is lost or compromised, the developer can request an upload key reset in Play Console.

    • Android: keep the upload key in the CI secret store and let Google hold the app signing key through Play App Signing.
    • iOS: keep the distribution certificate and provisioning profiles in the CI secret store or a managed signing setup, renewed before they expire.
    • Access: only the release job can read the keys, and every use is logged.
    • Recovery: write down who can request an upload key reset or revoke a certificate, and how they do it.

    How should builds move through store test tracks?

    Builds should move through the stores' own test tracks in order, from internal testers to a wider group and then to production, with the same binary promoted at each step. Rebuilding between steps means testing one binary and shipping another.

    Store tracks a release passes through
    StageGoogle PlayApple App StoreWho tests
    InternalInternal testing trackTestFlight internal testersThe team and QA
    Wider testClosed or open testing trackTestFlight external testersSelected users or the business
    ProductionProduction track with a staged rolloutApp Store release with a phased releaseA growing share of real users

    Promotion should be a pipeline action with an approval, not a manual upload. The pipeline records which commit, build number and test results each promoted binary came from.

    What should the pipeline run on every change?

    On every change the pipeline should run fast checks that block a merge, and save slower device tests for release candidates. Developers get quick feedback and releases still get full coverage.

    • Every pull request: static analysis, unit tests and a debug build for each platform.
    • Every merge to main: a signed release-candidate build with an incremented build number, uploaded to the internal track.
    • Release candidates: UI tests on a device farm or emulators, including the oldest OS versions you support.
    • Always: build artefacts, symbol files and test reports stored against the commit.

    How do staged and phased releases limit a bad update?

    Staged and phased releases send a new version to a small share of users first, so a crash or regression shows up in monitoring before most users have it. The release can then be paused while the team fixes the problem.

    Play Console Help says a staged rollout sends an update to a percentage of users that you increase over time. Halting it stops any more users from receiving that version, while users who already have it remain on it.

    App Store Connect Help says a phased release spreads an update over 7 days to a random sample of users with automatic updates turned on. The release can be paused for up to 30 days in total, and anyone can still download the update manually from the App Store.

    • Watch crash-free sessions, error rates and key business events by app version during the rollout.
    • Set the halt rule in advance, such as any new crash in sign-in or payment.
    • Ship the fix as a new build with a higher version number, because a halted version stays on the devices that already have it.

    How do you handle versions already on users' devices?

    Assume old versions stay installed for a long time, and design the backend and release process around that. A mobile release is not finished when the store accepts it.

    • Keep APIs backward compatible with every app version still in use, and retire old endpoints only after their usage drops.
    • Put risky features behind remote flags, so they can be switched off without a new build.
    • Add a minimum supported version check that asks users to update when an old version can no longer work correctly.
    • Track active users per app version to know when an old version can be retired.

    How should version and build numbers be managed?

    Version and build numbers should be set by the pipeline, never typed by hand. Both stores reject an upload whose build number has already been used, and a release that cannot be traced to a commit is hard to debug.

    • Build number: an integer the pipeline increments on every release-candidate build, shared by Android and iOS where possible.
    • Version name: the user-facing version, changed by a deliberate step when the team cuts a release.
    • Traceability: the commit hash and pipeline run stored with each build, and shown in the app's about screen for testers.
    • Hotfixes: built from a release branch by the same pipeline, with a higher build number than anything already uploaded.

    Which other secrets does a mobile pipeline hold?

    Besides signing material, a mobile pipeline holds store API credentials, crash reporting tokens and environment settings, and each needs the same care as the keys. A leaked store credential can be as damaging as a leaked signing key.

    • Store access: a Google Play service account and an App Store Connect API key, each limited to the release permissions the pipeline needs.
    • Build-time configuration: API base URLs and feature flag keys injected per environment, never committed in plain text.
    • Rotation: a written schedule and owner for every credential, with the pipeline failing clearly when one expires.

    What should a release checklist in the pipeline include?

    A release checklist should be enforced by the pipeline wherever a check can be automated, and recorded as an approval where it cannot. A checklist that lives only in a wiki gets skipped on the busiest release day.

    • Automated: every test green on the exact commit being promoted, with no suites skipped.
    • Automated: store listing text, screenshots and privacy answers unchanged, or flagged for review when they changed.
    • Automated: release notes present for every language the app ships in.
    • Approval: the product owner signs off the build in the wider test track.
    • Approval: the support team knows what changed and which known issues to expect.
    • Recorded: the rollout plan, the halt rule and who watches the dashboards that day.

    What are the common mistakes with CI/CD for mobile?

    The common mistakes with CI/CD for mobile leave a human step in the release path, usually around signing or store uploads, which is exactly where releases stall or go wrong.

    • Signing on a developer laptop, so releases stop whenever that person is away.
    • Rebuilding for production instead of promoting the binary that was tested.
    • Setting build numbers by hand, which leads to rejected uploads when two builds share a number.
    • Releasing to all users at once with no staged or phased rollout.
    • Skipping symbol uploads, so production crash reports cannot be read.

    A worked example: a weekly release train

    A product team ships an Android and iOS app on a weekly train. Each merge to main produces signed builds that go to the internal track and to TestFlight automatically.

    On release day the team promotes the week's candidate to the closed track and the external TestFlight group, then to production with a staged rollout on Android and a phased release on iOS.

    The next day, crash reports show a new crash on one older Android version. The team halts the Android rollout, ships a fixed build with a higher version through the same pipeline and resumes. Users who already had the faulty version receive the fix as a normal update.

    What does mobile CI/CD mean for your build plan?

    Mobile CI/CD is set up once and used on every release, so build it early, ideally before the first store submission. Adding it after launch means changing signing and release habits while users wait on updates.

    • Choose the CI service and decide where secrets and signing material live.
    • Enrol in Play App Signing and give the pipeline API access to App Store Connect.
    • Define the tracks, tester groups and who approves each promotion.
    • Pick the crash reporting and analytics the rollout decisions will depend on.

    How does Agnotic set up CI/CD for mobile apps?

    Agnotic builds the pipeline, moves signing into it, connects it to Google Play and App Store Connect, and sets up test tracks, promotions and rollout monitoring. We hand over runbooks for key recovery and halted rollouts so your team can run releases on its own.

    Signed in CI, promoted not rebuilt

    We set up the pipeline, the store tracks and the rollout checks for both platforms.

    Sources

    Frequently Asked Questions

    Yes, but iOS builds need macOS build machines, so most pipelines run the two platforms as separate jobs that share tests and versioning rules.

    Talk to an engineer about your project

    Tell us how you build and release today. We will map the pipeline, the signing setup and the rollout steps.