Skip to content

Deploy iOS

Deploy iOS #201

Workflow file for this run

name: Deploy iOS
on:
workflow_dispatch:
push:
branches:
- internal
- alpha
- beta
- master
concurrency:
group: deploy-ios-${{ github.ref }}
cancel-in-progress: false
jobs:
build-ios:
name: Deploy iOS
runs-on: macos-14
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Install dependencies
uses: ./.github/actions/install-dependencies
- name: Extract branch name
shell: bash
run: |
if [[ ${{ github.ref }} == 'refs/heads/master' ]]; then
echo "lane=production" >> $GITHUB_OUTPUT
else
echo "lane=internal" >> $GITHUB_OUTPUT
fi
id: extract_branch
- name: Encrypt GPG secure files
run: |
brew install gnupg@1.4
echo ${{ secrets.SUPER_SECRET_PASSWORD }} | gpg1 --no-tty --passphrase-fd 0 ios/AuthKey_3Q9U495BMY.p8.gpg
echo ${{ secrets.SUPER_SECRET_PASSWORD }} | gpg1 --no-tty --passphrase-fd 0 -o ios/GoogleService-Info.${{ steps.extract_branch.outputs.lane }}.plist ios/GoogleService-Info.${{ steps.extract_branch.outputs.lane }}.plist.gpg
- name: Fix match prompt issue
run: echo -e "Host github.com\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config
- name: Fastlane
uses: maierj/fastlane-action@v3.0.0
with:
lane: 'ios deploy --env ${{ steps.extract_branch.outputs.lane }}'
subdirectory: 'ios'
env:
TRAVIS_BRANCH: ${{ github.ref }}
TRAVIS: 'true'
MATCH_GIT_BASIC_AUTHORIZATION: ${{ secrets.MATCH_GIT_BASIC_AUTHORIZATION }}
FASTLANE_PASSWORD: ${{ secrets.FASTLANE_PASSWORD }}
MATCH_PASSWORD: ${{ secrets.MATCH_PASSWORD }}
CI: true