Skip to content

Commit

Permalink
Read Google Play credentials from env instead of from file for `sz de…
Browse files Browse the repository at this point in the history
…ploy android`
  • Loading branch information
nilsreichardt committed Sep 13, 2023
1 parent d228409 commit 8c06e04
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 19 deletions.
10 changes: 1 addition & 9 deletions .github/workflows/beta.yml
Original file line number Diff line number Diff line change
Expand Up @@ -192,18 +192,10 @@ jobs:
fvm flutter pub global activate --source path "$CI_CD_DART_SCRIPTS_PACKAGE_PATH"
echo $(pwd)/bin >> $GITHUB_PATH
- name: Set up Google Play credentials for Fastlane
env:
GOOGLE_PLAY_SERVICE_ACCOUNT_JSON: ${{ secrets.SHAREZONE_GOOGLE_PLAY_SERVICE_ACCOUNT_JSON }}
working-directory: app
run: |
mkdir private_keys && cd private_keys
echo $GOOGLE_PLAY_SERVICE_ACCOUNT_JSON > google-play-gserviceaccount.json
- name: Deploy
env:
# Export the Google Play service account credentials as an environment
# variable for Codemagic CLI tools.
# variable for Sharezone Repo CLI.
GCLOUD_SERVICE_ACCOUNT_CREDENTIALS: ${{ secrets.SHAREZONE_GOOGLE_PLAY_SERVICE_ACCOUNT_JSON }}
run: |
# When passing the changelog from GitHub Actions to the CLI, the line
Expand Down
10 changes: 1 addition & 9 deletions .github/workflows/stable.yml
Original file line number Diff line number Diff line change
Expand Up @@ -211,18 +211,10 @@ jobs:
fvm flutter pub global activate --source path "$CI_CD_DART_SCRIPTS_PACKAGE_PATH"
echo $(pwd)/bin >> $GITHUB_PATH
- name: Set up Google Play credentials for Fastlane
env:
GOOGLE_PLAY_SERVICE_ACCOUNT_JSON: ${{ secrets.SHAREZONE_GOOGLE_PLAY_SERVICE_ACCOUNT_JSON }}
working-directory: app
run: |
mkdir private_keys && cd private_keys
echo $GOOGLE_PLAY_SERVICE_ACCOUNT_JSON > google-play-gserviceaccount.json
- name: Deploy
env:
# Export the Google Play service account credentials as an environment
# variable for Codemagic CLI tools.
# variable for Sharezone Repo CLI.
GCLOUD_SERVICE_ACCOUNT_CREDENTIALS: ${{ secrets.SHAREZONE_GOOGLE_PLAY_SERVICE_ACCOUNT_JSON }}
run: |
# When passing the changelog from GitHub Actions to the CLI, the line
Expand Down
2 changes: 1 addition & 1 deletion app/android/fastlane/Appfile
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
json_key_file("../private_keys/google-play-gserviceaccount.json")
json_key_data_raw(ENV['GCLOUD_SERVICE_ACCOUNT_CREDENTIALS'])
package_name("de.codingbrain.sharezone")

0 comments on commit 8c06e04

Please sign in to comment.