ci(bitrise): split deploy by tag prefix and add iOS code-signing step
Build & Push Docker Images / test-backend (push) Successful in 21s
Build & Push Docker Images / test-frontend (push) Successful in 23s
Build & Push Docker Images / build-backend (push) Successful in 17s
Build & Push Docker Images / build-frontend (push) Successful in 15s
Build & Push Docker Images / test-backend (push) Successful in 21s
Build & Push Docker Images / test-frontend (push) Successful in 23s
Build & Push Docker Images / build-backend (push) Successful in 17s
Build & Push Docker Images / build-frontend (push) Successful in 15s
- Tag triggers split: ios-v* -> deploy_ios, android-v* -> deploy_android. The blanket tag: "*" trigger that ran both platforms on every tag is gone. - Add certificate-and-profile-installer@1 before xcode-archive@4 in deploy_ios and combined deploy. Reads Bitrise's auto-injected BITRISE_IOS_CODE_SIGNING_* env vars; no-op if not configured. - Harden test_ios simulator destination to generic/platform=iOS Simulator (was iPhone 15, OS=latest, which breaks when the runner ships a different Xcode). - Enable swift build cache on xcode-archive steps. Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
+61
-54
@@ -14,8 +14,10 @@ trigger_map:
|
||||
workflow: deploy
|
||||
- pull_request_source_branch: "*"
|
||||
workflow: test
|
||||
- tag: "*"
|
||||
workflow: deploy
|
||||
- tag: "ios-v*"
|
||||
workflow: deploy_ios
|
||||
- tag: "android-v*"
|
||||
workflow: deploy_android
|
||||
|
||||
workflows:
|
||||
# ── Shared setup ──────────────────────────────────────────
|
||||
@@ -66,6 +68,59 @@ workflows:
|
||||
- module: app
|
||||
- variant: debug
|
||||
|
||||
# ── iOS test / PR build (simulator) ──────────────────────
|
||||
test_ios:
|
||||
before_run:
|
||||
- _setup
|
||||
steps:
|
||||
- script@1:
|
||||
title: Sync iOS native project
|
||||
inputs:
|
||||
- content: |
|
||||
#!/bin/bash
|
||||
set -ex
|
||||
npx cap sync ios
|
||||
- cocoapods-install@2:
|
||||
inputs:
|
||||
- podfile_path: ios/App/Podfile
|
||||
- xcode-archive@4:
|
||||
title: Build iOS (simulator)
|
||||
inputs:
|
||||
- project_path: ios/App/App.xcodeproj
|
||||
- scheme: App
|
||||
- configuration: Debug
|
||||
- destination: generic/platform=iOS Simulator
|
||||
- output_tool: xcodebuild
|
||||
- cache_level: swift
|
||||
|
||||
# ── iOS deploy ───────────────────────────────────────────
|
||||
deploy_ios:
|
||||
before_run:
|
||||
- _setup
|
||||
steps:
|
||||
- script@1:
|
||||
title: Sync iOS native project
|
||||
inputs:
|
||||
- content: |
|
||||
#!/bin/bash
|
||||
set -ex
|
||||
npx cap sync ios
|
||||
- cocoapods-install@2:
|
||||
inputs:
|
||||
- podfile_path: ios/App/Podfile
|
||||
- certificate-and-profile-installer@1: {}
|
||||
- xcode-archive@4:
|
||||
title: Archive iOS (release)
|
||||
inputs:
|
||||
- project_path: ios/App/App.xcodeproj
|
||||
- scheme: App
|
||||
- configuration: Release
|
||||
- destination: generic/platform=iOS
|
||||
- output_tool: xcodebuild
|
||||
- export_method: app-store
|
||||
- cache_level: swift
|
||||
- deploy-to-bitrise-io@2: {}
|
||||
|
||||
# ── Android deploy ───────────────────────────────────────
|
||||
deploy_android:
|
||||
before_run:
|
||||
@@ -96,57 +151,7 @@ workflows:
|
||||
- variant: release
|
||||
- deploy-to-bitrise-io@2: {}
|
||||
|
||||
# ── iOS test / PR build ─────────────────────────────────
|
||||
test_ios:
|
||||
before_run:
|
||||
- _setup
|
||||
steps:
|
||||
- script@1:
|
||||
title: Sync iOS native project
|
||||
inputs:
|
||||
- content: |
|
||||
#!/bin/bash
|
||||
set -ex
|
||||
npx cap sync ios
|
||||
- cocoapods-install@2:
|
||||
inputs:
|
||||
- podfile_path: ios/App/Podfile
|
||||
- xcode-archive@4:
|
||||
title: Build iOS (simulator)
|
||||
inputs:
|
||||
- project_path: ios/App/App.xcodeproj
|
||||
- scheme: App
|
||||
- configuration: Debug
|
||||
- destination: platform=iOS Simulator,name=iPhone 15,OS=latest
|
||||
- output_tool: xcodebuild
|
||||
|
||||
# ── iOS deploy ───────────────────────────────────────────
|
||||
deploy_ios:
|
||||
before_run:
|
||||
- _setup
|
||||
steps:
|
||||
- script@1:
|
||||
title: Sync iOS native project
|
||||
inputs:
|
||||
- content: |
|
||||
#!/bin/bash
|
||||
set -ex
|
||||
npx cap sync ios
|
||||
- cocoapods-install@2:
|
||||
inputs:
|
||||
- podfile_path: ios/App/Podfile
|
||||
- xcode-archive@4:
|
||||
title: Archive iOS (release)
|
||||
inputs:
|
||||
- project_path: ios/App/App.xcodeproj
|
||||
- scheme: App
|
||||
- configuration: Release
|
||||
- destination: generic/platform=iOS
|
||||
- output_tool: xcodebuild
|
||||
- export_method: app-store
|
||||
- deploy-to-bitrise-io@2: {}
|
||||
|
||||
# ── Full deploy (both platforms) ─────────────────────────
|
||||
# ── Combined deploy (default branch push) ────────────────
|
||||
deploy:
|
||||
before_run:
|
||||
- _setup
|
||||
@@ -186,6 +191,7 @@ workflows:
|
||||
- cocoapods-install@2:
|
||||
inputs:
|
||||
- podfile_path: ios/App/Podfile
|
||||
- certificate-and-profile-installer@1: {}
|
||||
- xcode-archive@4:
|
||||
title: Archive iOS (release)
|
||||
inputs:
|
||||
@@ -195,4 +201,5 @@ workflows:
|
||||
- destination: generic/platform=iOS
|
||||
- output_tool: xcodebuild
|
||||
- export_method: app-store
|
||||
- deploy-to-bitrise-io@2: {}
|
||||
- cache_level: swift
|
||||
- deploy-to-bitrise-io@2: {}
|
||||
Reference in New Issue
Block a user