iOS Fastlane AdHoc #456
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: iOS Fastlane AdHoc | |
on: | |
workflow_dispatch: | |
inputs: | |
versionName: | |
description: 'User-facing release version name' | |
required: true | |
default: "1.0.0" | |
versionCode: | |
description: 'versionCode or build number' | |
required: true | |
default: '1' | |
jobs: | |
deploy: | |
runs-on: macos-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up ruby env | |
uses: ruby/[email protected] | |
with: | |
ruby-version: 3.2.1 | |
bundler-cache: true | |
- name: Decode signing certificate into a file | |
env: | |
CERTIFICATE_BASE64: ${{ secrets.BUILD_CERTIFICATE_BASE64 }} | |
run: | | |
echo $CERTIFICATE_BASE64 | base64 --decode > signing-cert.p12 | |
- name: Setup the flutter environment | |
uses: subosito/flutter-action@v2 | |
with: | |
flutter-version: '3.22.0' | |
channel: 'stable' | |
cache: true | |
- name: Get flutter dependencies | |
run: flutter pub get | |
- name: Build the app | |
run: | | |
flutter build ipa --debug --build-number=${{ github.event.inputs.versionCode }} --build-name=${{ github.event.inputs.versionName }} --no-codesign --dart-define=BUGSNAG_API_KEY=${{ secrets.BUGSNAG_API_KEY }} | |
ls -la build/ios/archive | |
- name: Generate and sign the ipa | |
working-directory: ios | |
run: bundle install && bundle exec fastlane ios ad_hoc_build | |
env: | |
ASC_KEY_ID: ${{ secrets.APPSTORE_API_KEY_ID }} | |
ASC_ISSUER_ID: ${{ secrets.APPSTORE_ISSUER_ID }} | |
ASC_KEY: ${{ secrets.APPSTORE_API_PRIVATE_KEY }} | |
SIGNING_KEY_PASSWORD: ${{ secrets.P12_PASSWORD }} | |
SIGNING_KEY_FILE_PATH: ../signing-cert.p12 | |
- name: Upload artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
name: iOS IPA | |
path: ios/*.ipa |