-
Notifications
You must be signed in to change notification settings - Fork 12
74 lines (64 loc) · 2.41 KB
/
android_beta_deployment.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
name: Android Beta Deployment
on:
push:
branches:
- "release/**"
- "hotfix/**"
defaults:
run:
shell: bash
jobs:
files-changed:
name: Detect changes
uses: ./.github/workflows/detect_changed_files_reusable_workflow.yml
with:
base: ${{ github.ref }}
# Run Gradle Wrapper Validation Action to verify the wrapper's checksum
gradle-wrapper-validation:
needs: files-changed
if: ${{ needs.files-changed.outputs.android == 'true' || needs.files-changed.outputs.shared == 'true' }}
name: Gradle Wrapper Validation
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v4.2.1
- name: Gradle Wrapper Validation
uses: gradle/actions/wrapper-validation@v4
# Build and submit to the Firebase App Distribution
firebase-deployment:
name: Deploy to Firebase App Distribution
needs: gradle-wrapper-validation
uses: ./.github/workflows/android_deploy_to_firebase.yml
secrets: inherit
# Build and submit to the Google Play
google-play-deployment:
name: Deploy to Google Play
needs: gradle-wrapper-validation
runs-on: ubuntu-22.04
environment: android_production
timeout-minutes: 60
steps:
- name: Checkout
uses: actions/checkout@v4.2.1
- name: Setup CI
id: setup
uses: ./.github/actions/setup-android
with:
setup-ruby: true
git-crypt-key: ${{ secrets.GIT_CRYPT_KEY }}
release-keystore-content: ${{ secrets.HYPERSKILL_RELEASE_KEYSTORE_CONTENT }}
service-account-content: ${{ secrets.SERVICE_ACCOUNT_CONTENT }}
- name: Submit a new Release Build to the Google Play
working-directory: "./androidHyperskillApp"
run: |
bundle exec fastlane release \
json_key:"${{ steps.setup.outputs.service-account-path }}" \
track:"internal"
env:
IS_GIT_CRYPT_UNLOCKED: ${{ steps.setup.outputs.is-git-crypt-unlocked }}
HYPERSKILL_KEYSTORE_PATH: ${{ steps.setup.outputs.release-keystore-path }}
HYPERSKILL_RELEASE_STORE_PASSWORD: ${{ secrets.HYPERSKILL_RELEASE_STORE_PASSWORD }}
HYPERSKILL_RELEASE_KEY_ALIAS: ${{ secrets.HYPERSKILL_RELEASE_KEY_ALIAS }}
HYPERSKILL_RELEASE_KEY_PASSWORD: ${{ secrets.HYPERSKILL_RELEASE_KEY_PASSWORD }}
GITHUB_USER: ${{ github.actor }}
GITHUB_PERSONAL_ACCESS_TOKEN: ${{ secrets.GITHUB_TOKEN }}