-
Notifications
You must be signed in to change notification settings - Fork 6
57 lines (54 loc) · 1.94 KB
/
deploy-develop.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
name: deploy-develop-android
run-name: Build and deploy develop build for Android
on:
push:
branches:
- "develop"
paths:
- "android/**"
- "lib/**"
- "pubspec.yaml"
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build-deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
ref: develop
- uses: subosito/flutter-action@v2
with:
flutter-version: '3.19.3'
channel: 'stable'
- name: load certificate
uses: mobiledevops/secret-to-file-action@v1
with:
base64-encoded-secret: ${{ secrets.APP_CERTIFICATE }}
filename: "keystore.jks"
working-directory: ./android/app
- name: create credentials
env:
keystore_pass: ${{ secrets.KEYSTORE_PASS }}
run: |
echo -e "storePassword: $keystore_pass\nkeyPassword: $keystore_pass\nkeyAlias: upload-unn-mobile\nstoreFile=keystore.jks\n" >> ./android/key.properties
- name: install firebase
run: curl -sL https://firebase.tools | bash
- name: get dependencies
run: flutter pub get
- name: configure flutterfire
env:
firebase_token: ${{ secrets.FIREBASE_TOKEN }}
run: |
dart pub global activate flutterfire_cli
flutterfire configure -t $firebase_token -y -p unn-mobile-1 --platforms=android --android-package-name=ru.unn.unn_mobile
- name: build
run: flutter build appbundle
- name: deploy
env:
firebase_token: ${{ secrets.FIREBASE_TOKEN }}
app_id: ${{ secrets.FIREBASE_A_APP_ID }}
run: |
firebase --debug --project unn-mobile-1 --token $firebase_token appdistribution:distribute --groups "testers" --app "$app_id" --release-notes "$(git log -1 --pretty=%B)" "build/app/outputs/bundle/release/app-release.aab"