Mobile Fastlane

Profiles & CI (run_profile)

Last updated 2026-10-07

A profile is a saved setup. Profiles are committed to the repository, so the whole team and CI can run exactly the same build with one command.

Where profiles live

PathCommitted?Contents
fastlane/config/profiles/<name>.ymlYesPlatforms, environment, action and the per-platform overrides
fastlane/.setup_state.ymlNo (git-ignored)Name of the last profile you used on this machine

Profile format

A profile uses the same keys as an environment block in environments.yml. Anything a profile doesn't set falls back to that environment.

fastlane/config/profiles/staging-aab.yml
# Saved by `fastlane setup`. Run with: fastlane run_profile name:staging-aab
platforms:
- android
environment: staging
action: distribute # build | distribute
android:
flavor: staging
build_type: release
gradle_task: bundleStagingRelease
artifact:
type: AAB
glob: android/app/build/outputs/bundle/stagingRelease/*.aab
firebase:
enabled: true
groups: qa-team
app_testing:
enabled: false
release_notes:
enabled: true
source: git
commit_count: 10
name: staging-aab
Warning: profiles are committed. Never put tokens, passwords or webhook URLs in them. Use ${ENV_VAR} placeholders or leave the value blank so it comes from .env.

Run a profile without prompts

my-app — zsh
~/my-app $ bundle exec fastlane profiles
dev-apk — android · development · APK · build
staging-aab (last used) — android · staging · staging · AAB · distribute
~/my-app $ bundle exec fastlane run_profile name:dev-apk dry_run:true
Cruising over to lane 'android doctor' 🚖
Flavor mode: disabled
Android development configuration is valid.
Cruising over to lane 'android info' 🚖
Gradle task: assembleRelease
Artifact type: APK
Firebase enabled: false
Fastlane completed successfully: run_profile
Captured from a real dry run: the profile's overrides are applied to the existing doctor and info lanes.
OptionEffect
name:<profile>Required in CI. Locally it defaults to the last used profile.
dry_run:trueRuns doctor and info only. Nothing is built or uploaded.

Use profiles in GitHub Actions

Because run_profile never prompts, it can replace hand-written lane options in a workflow. Let the person running the workflow pick a profile through a workflow_dispatch input:

.github/workflows/android-distribution.yml (excerpt)
on:
workflow_dispatch:
inputs:
profile:
description: "Saved setup profile"
required: true
default: "staging-aab"
jobs:
distribute:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: ruby/setup-ruby@v1
with:
bundler-cache: true
- run: bundle exec fastlane run_profile name:${{ inputs.profile }}
env:
FIREBASE_TOKEN: ${{ secrets.FIREBASE_TOKEN }}
FIREBASE_ANDROID_STAGING_APP_ID: ${{ secrets.FIREBASE_ANDROID_STAGING_APP_ID }}
GitHub Actions · run_profile
~/my-app $ CI=true bundle exec fastlane setup
[!] `fastlane setup` is interactive. In CI use: fastlane run_profile name:<profile>
setup and init_project stop immediately in CI instead of hanging on a prompt.

Official documentation

Was this helpful?