-
Notifications
You must be signed in to change notification settings - Fork 1
120 lines (108 loc) · 4 KB
/
appCICD.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
name: App builds
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build_appbundle_deploy_internal_testing:
name: Build Android App Bundle
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Setup java code
uses: actions/setup-java@v1
with:
java-version: "12.x"
- name: Decode Keystore
run: |
echo "${{ secrets.KEYSTORE }}" > keystore.asc
gpg -d --passphrase "${{ secrets.KEYSTORE_PASSPHRASE }}" --batch keystore.asc > /home/runner/work/RecipeRootsApp/RecipeRootsApp/android/app/keystore.jks
- name: Setup ruby for Fastlane
uses: ruby/[email protected]
with:
ruby-version: 3.2.1
bundler-cache: true
working-directory: 'android'
- name: Increment Android Build Number from Internal Testing
uses: maierj/[email protected]
with:
lane: 'setBuildBasedOnInternalTesting'
subdirectory: 'android'
env:
GOOGLE_API_KEY: ${{ secrets.GOOGLE_API_KEY }}
- name: Setup Flutter
uses: subosito/flutter-action@v1
with:
channel: "stable"
- name: Clean up flutter
run: flutter clean
- name: Download packages
run: flutter pub get
- name: Build Android App Bundle
run: flutter build appbundle --release
env:
SIGNING_KEY_ALIAS: ${{ secrets.SIGNING_KEY_ALIAS }}
SIGNING_KEY_PASSWORD: ${{ secrets.SIGNING_KEY_PASSWORD }}
SIGNING_STORE_PASSWORD: ${{ secrets.SIGNING_STORE_PASSWORD }}
- name: Upload artifact to Github
uses: actions/upload-artifact@v1
with:
name: release-aab
path: build/app/outputs/bundle/release/app-release.aab
- name: Push out app
uses: maierj/[email protected]
with:
lane: 'deployInternalTesting'
subdirectory: 'android'
env:
GOOGLE_API_KEY: ${{ secrets.GOOGLE_API_KEY }}
build_ios_deploy_internal_testing:
name: Deploy build to TestFlight
runs-on: macos-latest
steps:
- name: Checkout code from ref
uses: actions/checkout@v2
with:
ref: ${{ github.ref }}
- name: Setup ruby for Fastlane
uses: ruby/[email protected]
with:
ruby-version: 3.2.1
bundler-cache: true
working-directory: 'ios'
- name: Run Flutter tasks
uses: subosito/flutter-action@v1
with:
flutter-version: '3.7.12'
- name: Bump Flutter version number
uses: maierj/[email protected]
with:
lane: bumpFlutterVersion
subdirectory: ios
env:
APPLICATON_ID: '${{ secrets.APPLICATON_ID }}'
APPLE_API_KEY: '${{ secrets.APPLE_API_KEY }}'
APPLE_API_KEY_ID: '${{ secrets.APPLE_API_KEY_ID }}'
APPLE_API_ISSUER_ID: '${{ secrets.APPLE_API_ISSUER_ID }}'
- run: flutter clean
- run: flutter pub get
- run: flutter build ios --release --no-codesign
- name: Deploy iOS Beta to TestFlight via Fastlane
uses: maierj/[email protected]
with:
lane: closed_beta
subdirectory: ios
env:
ITC_TEAM_ID: '${{ secrets.ITC_TEAM_ID }}'
APPLICATON_ID: '${{ secrets.APPLICATON_ID }}'
BUNDLE_IDENTIFIER: '${{ secrets.BUNDLE_IDENTIFIER }}'
DEVELOPER_PORTAL_TEAM_ID: '${{ secrets.DEVELOPER_PORTAL_TEAM_ID }}'
FASTLANE_APPLE_ID: '${{ secrets.FASTLANE_APPLE_EMAIL_ID }}'
FASTLANE_APPLE_APPLICATION_SPECIFIC_PASSWORD: '${{ secrets.APP_SPECIFIC_PASSWORD }}'
MATCH_PASSWORD: '${{ secrets.MATCH_PASSWORD }}'
GIT_AUTHORIZATION: '${{ secrets.GIT_AUTHORIZATION }}'
PROVISIONING_PROFILE_SPECIFIER: '${{ secrets.PROVISIONING_PROFILE_SPECIFIER }}'
TEMP_KEYCHAIN_PASSWORD: '${{ secrets.TEMP_KEYCHAIN_PASSWORD }}'
TEMP_KEYCHAIN_USER: '${{ secrets.TEMP_KEYCHAIN_USER }}'