wzieba / Firebase-Distribution-Github-Action

This action uploads artifacts (.apk or .ipa) to Firebase App Distribution.
MIT License
379 stars 77 forks source link

apk does not exist: verify that file points to a binary : Issue #130

Open laltukumar-ayla opened 9 months ago

laltukumar-ayla commented 9 months ago

I am trying to distribute the release apk to Firebase. I am able to do it through the demo codebase. But when I am trying to upload it through actual getting the error "verify that file points to a binary". I am struggling to solve this from one week not able to fix it. Please help me through fixing this. My Job:

name: Deploy to Firebase

on: push: branches: [ Phase2_Development_Builds ]

jobs: build: name: Building and distributing app runs-on: ubuntu-latest env: SIGNING_KEY_STORE_PATH: ${{ secrets.SIGNING_KEY_STORE_PATH }} SIGNING_KEY_ALIAS: ${{ secrets.SIGNING_KEY_ALIAS }} SIGNING_KEY_PASSWORD: ${{ secrets.SIGNING_KEY_PASSWORD }} SIGNING_STORE_PASSWORD: ${{ secrets.SIGNING_STORE_PASSWORD }} steps:

Error image: ![Uploading Screenshot 2024-02-07 at 12.59.14 PM.png…]()

DarkAbhi commented 9 months ago

Can confirm for same

      - uses: actions/cache@v4
        with:
          path: |
            ~/.gradle/caches
            ~/.gradle/wrapper
          key: ${{ runner.os }}-${{ hashFiles('**/*.gradle*') }}-${{ hashFiles('**/gradle/wrapper/gradle-wrapper.properties') }}-${{ hashFiles('**/buildSrc/**/*.kt') }}
      - name: Make Gradle executable
        run: chmod +x ./gradlew
      - name: Build Release APK
        env:
          SIGNING_KEY_ALIAS: ${{ secrets.SIGNING_KEY_ALIAS }}
          SIGNING_KEY_PASSWORD: ${{ secrets.SIGNING_KEY_PASSWORD }}
          SIGNING_STORE_PASSWORD: ${{ secrets.SIGNING_STORE_PASSWORD }}
        run: ./gradlew assembleRelease
      - name: send APK build on success
        uses: appleboy/telegram-action@master
        with:
          to: ${{ secrets.TELEGRAM_TO }}
          token: ${{ secrets.TELEGRAM_TOKEN }}
          message: |
            iku Earth Debug Build
            Author: ${{ github.actor }}
            Commit ID: ${{ github.sha }}

            Commit Message: ${{ github.event.head_commit.message }}

            View: https://github.com/Iku-earth/iku-earth-android/actions/runs/${{ github.run_id }}
          document: ./app/build/outputs/apk/release/*.apk
      - name: Upload to Firebase App Distribution
        uses: wzieba/Firebase-Distribution-Github-Action@v1.7.0
        with:
          appId: ${{ secrets.FIREBASE_TEST_APP_ID }}
          token: ${{ secrets.FIREBASE_TOKEN_CI }}
          groups: alpha
          file: /home/runner/work/iku-earth-android/iku-earth-android/app/build/outputs/apk/release/*.apk
JillyTaboga commented 9 months ago

In my test the "file:" key dont accept special characters like "space" or "*" or ".".

To bypass the problem I used other issue indication to creat a variable with the name of the file:

      - name: Get app name
        id: app-name
        run: |
          APP_NAME=$(echo <.build/ios/ipa/app.ipa)
          echo "::set-output name=APP_NAME::${APP_NAME}"

And used it on the upload action

      - name: upload artifact to Firebase App Distribution
        uses: wzieba/Firebase-Distribution-Github-Action@v1
        with:
          appId: ${{secrets.FIREBASE_APP_ID_IOS_DEV}}
          serviceCredentialsFileContent: ${{ secrets.CREDENTIAL_FILE_CONTENT }}
          groups: testers
          file: ${{ steps.app-name.outputs.APP_NAME }}
PayneJay commented 8 months ago

I also encountered the same problem. Is there any solution?

yashrp2003 commented 6 months ago

if you found any solution please tell. @PayneJay