This is an automated email from the ASF dual-hosted git repository.
vterentev pushed a commit to branch vitalii-t-test-activate-sa
in repository https://gitbox.apache.org/repos/asf/beam.git
The following commit(s) were added to refs/heads/vitalii-t-test-activate-sa by
this push:
new f0f0d8f070c Activate service account with retry
f0f0d8f070c is described below
commit f0f0d8f070c9835c94d1597c71b02fd63a849a98
Author: Vitaly Terentyev <[email protected]>
AuthorDate: Tue Apr 15 11:55:35 2025 +0400
Activate service account with retry
---
.github/workflows/beam_Publish_Beam_SDK_Snapshots.yml | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/.github/workflows/beam_Publish_Beam_SDK_Snapshots.yml
b/.github/workflows/beam_Publish_Beam_SDK_Snapshots.yml
index 90773c6d336..9dda843b0ca 100644
--- a/.github/workflows/beam_Publish_Beam_SDK_Snapshots.yml
+++ b/.github/workflows/beam_Publish_Beam_SDK_Snapshots.yml
@@ -104,7 +104,15 @@ jobs:
- name: Activate service account
run: |
echo '${{ secrets.GCP_SA_KEY }}' > /tmp/key.json
- gcloud auth activate-service-account --key-file=/tmp/key.json
+ for i in {1..5}; do
+ if gcloud auth activate-service-account --key-file=/tmp/key.json;
then
+ echo "Auth success"
+ break
+ else
+ echo "Auth failed, retrying in 5s..."
+ sleep 5
+ fi
+ done
- name: GCloud Docker credential helper
run: |
gcloud auth configure-docker ${{ env.docker_registry }}