Skip to content
This repository was archived by the owner on Jul 16, 2025. It is now read-only.

Commit 32877e8

Browse files
committed
send a pub/sub message with the release tag to publish the release
1 parent 37830f2 commit 32877e8

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

.github/workflows/release_flow.yml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,3 +107,19 @@ jobs:
107107
with:
108108
delete_release: true
109109
tag_name: ${{ github.ref_name }}
110+
111+
112+
publish_release:
113+
name: Publish release
114+
needs: buildassets
115+
# Authenticate with gcloud using OIDC
116+
- name: Authenticate with GCP using OIDC
117+
run: |
118+
echo "${{ secrets.GCP_SERVICE_ACCOUNT_KEY }}" > gcp-service-account.json
119+
gcloud auth activate-service-account --key-file=gcp-service-account.json
120+
gcloud auth login --update-adc
121+
122+
# Publish the release tag to a Pub/Sub topic
123+
- name: Publish a message to a Pub/Sub topic
124+
run: |
125+
gcloud pubsub topics publish ${{ secrets.GCLOUD_UPLOADER_PUBSUB_TOPIC }} --message '{"release":"'"${{ github.ref_name }}"'", "latest":true}'

0 commit comments

Comments
 (0)