-
Notifications
You must be signed in to change notification settings - Fork 10
38 lines (33 loc) · 1.25 KB
/
sendAppToQaAfterMergeStageQa.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
name: Build and sent to QA stageQa
on:
# Triggers the workflow when pull request closed events but only for the "dev" branch
pull_request:
types:
- closed
branches: [ "dev" ]
workflow_dispatch:
jobs:
send_to_qa_stage:
if: github.event.pull_request.merged == true
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v1
with: { java-version: 1.17 }
- name: Build and send application stageQa to App Distribution
env:
STORE_PASSWORD: ${{ secrets.STORE_PASSWORD }}
KEY_ALIAS: ${{ secrets.KEY_ALIAS }}
KEY_PASSWORD: ${{ secrets.KEY_PASSWORD }}
CREDENTIAL_FILE_CONTENT: ${{ secrets.CREDENTIAL_FILE_CONTENT }}
run: |
echo "$CREDENTIAL_FILE_CONTENT" > ./app/serviceCredentialsFile.json
echo "App type: stageQa" >> ./app/src/releaseNotes.txt
echo "buildNumber=${GITHUB_RUN_NUMBER}" >> ./app/src/releaseNotes.txt
./gradlew appDistributionToQaStageQa
- name: Check status
run: echo "Check build status and send status"
- name: Set failed if build failed
if: failure()
run: |
echo "::error::Build or send build stageQa to App Distribution failed"