ci: Gitea Actions workflow para build APK release v3.2.0
Build APK — WhatSMS Gateway / build (push) Failing after 4m5s
Build APK — WhatSMS Gateway / build (push) Failing after 4m5s
- Runner: mingc/android-build-box:latest (JDK 17) - Injecta google-services.json a partir de secret - Decode keystore.jks a partir de KEYSTORE_BASE64 - assembleRelease com signing via env vars - Upload APK como artefacto da run - Trigger: push feat/whatsms-branding-ptpt + workflow_dispatch
This commit is contained in:
@@ -0,0 +1,47 @@
|
||||
name: Build APK — WhatSMS Gateway
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- feat/whatsms-branding-ptpt
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
container:
|
||||
image: mingc/android-build-box:latest
|
||||
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Configurar JDK 17
|
||||
run: |
|
||||
export JAVA_HOME=/usr/lib/jvm/java-17-openjdk-amd64
|
||||
echo "JAVA_HOME=/usr/lib/jvm/java-17-openjdk-amd64" >> $GITHUB_ENV
|
||||
echo "/usr/lib/jvm/java-17-openjdk-amd64/bin" >> $GITHUB_PATH
|
||||
java -version
|
||||
|
||||
- name: Injectar google-services.json
|
||||
run: echo '${{ secrets.GOOGLE_SERVICES_JSON }}' > app/google-services.json
|
||||
|
||||
- name: Decode keystore
|
||||
run: echo '${{ secrets.KEYSTORE_BASE64 }}' | base64 -d > app/keystore.jks
|
||||
|
||||
- name: Build APK release
|
||||
env:
|
||||
SIGNING_STORE_PASSWORD: ${{ secrets.SIGNING_STORE_PASSWORD }}
|
||||
SIGNING_KEY_ALIAS: ${{ secrets.SIGNING_KEY_ALIAS }}
|
||||
SIGNING_KEY_PASSWORD: ${{ secrets.SIGNING_KEY_PASSWORD }}
|
||||
JAVA_HOME: /usr/lib/jvm/java-17-openjdk-amd64
|
||||
run: |
|
||||
chmod +x gradlew
|
||||
./gradlew assembleRelease --no-daemon --stacktrace
|
||||
|
||||
- name: Upload APK
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: whatsms-gateway-v3.2.0-release
|
||||
path: app/build/outputs/apk/release/*.apk
|
||||
retention-days: 30
|
||||
Reference in New Issue
Block a user