Secrets, Keystores & Google Play Distribution
Security is paramount in mobile CI/CD. Flotio stores all sensitive credentials in an AES-256 encrypted vault that is decrypted and mounted only inside isolated ephemeral runner containers at build time.
1. Android Keystore Signing (.jks)
To produce signed release binaries (.apk and .aab for Google Play), Flotio provides a dedicated Keystore Manager.
Generating a Keystore (if you don't have one)
Adding your Keystore to Flotio
- Navigate to Project > Configuration > Android Keystores & Signing.
- Click + Upload Keystore and provide:
- Name: e.g. Production Key
- Keystore File: Select your .jks file
- Store Password: Keystore encryption password
- Key Alias: Alias name specified during generation (e.g. my-app-alias)
- Key Password: Alias password (if different from store password)
- Click Link Keystore to associate it with your project.
/keystore/keystore.jks and sets $KEYSTORE_PATH, $KEYSTORE_PASSWORD, $KEY_ALIAS, and $KEY_PASSWORD.2. Google Cloud & Google Play Service Account
Automated publishing to the Google Play Store requires a Google Cloud Service Account linked to your Google Play Developer Console.
Step 1: Create a Service Account in Google Cloud Console
- Go to the Google Cloud Console.
- Select your project and navigate to IAM & Admin > Service Accounts.
- Click Create Service Account:
- Name: flotio-play-publisher
- Grant role: Service Account User.
- Navigate to the Keys tab of the created service account.
- Click Add Key > Create new key > JSON and download the
.jsonkey file.
Step 2: Enable Google Play Android Developer API
- In Google Cloud Console, navigate to APIs & Services > Library.
- Search for Google Play Android Developer API and click Enable.
Step 3: Grant Permissions in Google Play Console
- Open the Google Play Console.
- Navigate to Users & Permissions > Invite new user.
- Paste the email address of the service account created in Google Cloud (e.g.
flotio-play-publisher@...iam.gserviceaccount.com). - In App permissions, select your app and grant the following permissions:
- Edit and delete draft releases
- Release to production, exclude devices, and use Play App Signing
- Release apps to testing tracks (Internal, Closed, Open)
- Click Invite user to confirm.
Step 4: Add the Key to Flotio
- In your Flotio Project, go to Configuration > Distribution & Store Publishing.
- Under Google Play Service Account Key (JSON), click + Add Key.
- Enter a name (e.g.
Play Store Console Key) and upload your JSON file. - Select the track for automated deployment:
- internal (Internal Testing track - recommended for CI/CD)
- alpha (Closed Testing)
- beta (Open Testing)
- production (Direct Production release)
- Set your Rollout Fraction (e.g.
1.0for 100% or0.1for 10% staged rollout).
3. Firebase Integration (google-services.json)
For Flutter apps using Firebase (Authentication, Firestore, Cloud Messaging, Crashlytics):
- Download your
google-services.jsonfrom the Firebase Console. - In Flotio, navigate to Project > Configuration > Environment Variables & Files.
- Upload
google-services.jsonas a secure file asset. - Flotio automatically mounts all uploaded environment files into
/env-files/and copiesgoogle-services.jsontoandroid/app/google-services.jsonbefore building.
4. Encrypted Environment Variables
You can inject environment variables into your Flutter build via Dart defines:
All keys and tokens are AES-256 encrypted at rest and never exposed in build logs.