A hotfix that someone has to publish from their laptop depends on that person being online. A hotfix that goes out from CI has the same review as every other change, and anyone on the team can trigger it.
Here's how to publish an over-the-air (OTA) update for a Flutter app from GitHub Actions, using OverPush.
Before you start
Your app needs one store release made with OverPush (overpush release android / overpush release ios). Patches are checked against that release. See the getting started guide.
1. Get a CI token
In your project, on your laptop:
overpush token It prints two values. In your GitHub repo, go to Settings → Secrets and variables → Actions → New repository secret and add both:
OVERPUSH_TOKENOVERPUSH_API_BASE
Treat the token like a password. You can remove it any time from the dashboard.
2. Add the workflow
.github/workflows/patch-android.yml:
name: patch-android on: workflow_dispatch: inputs: rollout: description: Rollout percent default: "10" jobs: patch: runs-on: ubuntu-latest env: OVERPUSH_TOKEN: ${{ secrets.OVERPUSH_TOKEN }} OVERPUSH_API_BASE: ${{ secrets.OVERPUSH_API_BASE }} steps: - uses: actions/checkout@v4 - uses: subosito/flutter-action@v2 with: flutter-version: 3.41.4 # the version that built the release - run: curl -fsSL https://overpush.in/install.sh | bash - run: flutter pub get - run: ~/.overpush/bin/overpush patch android --yes --rollout-percent ${{ inputs.rollout }} For iOS, copy it, use runs-on: macos-latest and overpush patch ios. A patch needs no code signing.
Use the same Flutter version that built the store release.
3. Ship a hotfix
- Merge the fix into your release branch.
- Go to Actions → patch-android → Run workflow, enter a rollout percent (start with 10), and run it.
- Watch installs and failures in the dashboard, then raise the rollout.
Patching an older release
To patch something other than the newest release:
overpush patch android --yes --release-version 1.4.0+31 Notes
- CI tokens are on the Pro plan and up.
- If the fix turns out to be wrong:
overpush patches revoke N, and devices go back to the release code at their next launch. - Codemagic works the same way: https://docs.overpush.in/ci-codemagic.html
Full CI docs: https://docs.overpush.in/ci-github.html
