Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace Firebase Token with Google Service Account #522

Open
blyscuit opened this issue Sep 7, 2023 · 0 comments
Open

Replace Firebase Token with Google Service Account #522

blyscuit opened this issue Sep 7, 2023 · 0 comments
Assignees

Comments

@blyscuit
Copy link
Collaborator

blyscuit commented Sep 7, 2023

Why

Currently we are using firebase_token to upload a new build to Firebase Distribution, but this approach requires the token be generated from an account, ideally a shared account.

Using Google Service Account does not require a shared account and the key can be shared with Android project.

More info on Service Account: https://firebase.google.com/docs/app-distribution/ios/distribute-fastlane#service-acc-fastlane

Acceptance Criteria

  • Replace FIREBASE_TOKEN from all workflows Secrets and use FIREBASE_GOOGLE_APPLICATION_CREDENTIALS_BASE64 instead.
  • GH
  • Bitrise
  • CodeMagic
  • Set ENV GOOGLE_APPLICATION_CREDENTIALS: ${{ steps.firebase_service_account.outputs.filePath }} to allow Fastlane to automatically use Service Account to upload.

example:

    - name: Read Google Service Account
      id: firebase_service_account
      uses: timheuer/[email protected]
      with:
        fileName: 'firebase_service_account.json'
        encodedString: ${{ secrets.FIREBASE_GOOGLE_APPLICATION_CREDENTIALS_BASE64 }}
    - name: Build Production App and Distribute to Firebase
      run: bundle exec fastlane buildProductionAndUploadToFirebase
      env:
        GOOGLE_APPLICATION_CREDENTIALS: ${{ steps.firebase_service_account.outputs.filePath }}

Who Benefits?

Users.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant