forked from succinctlabs/op-succinct
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
e1acdfa
commit 323d7ef
Showing
1 changed file
with
37 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
name: Release to GCP | ||
|
||
on: | ||
push: | ||
tags: | ||
- 'v*.*.*' | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: 'read' | ||
id-token: 'write' | ||
|
||
env: | ||
DOCKER_REGISTRY: us-docker.pkg.dev | ||
|
||
steps: | ||
- uses: 'actions/checkout@v4' | ||
|
||
- name: Authenticate to GCP using Workload Identity Federation | ||
uses: google-github-actions/auth@v2 | ||
with: | ||
workload_identity_provider: '${{ secrets.WORKLOAD_IDENTITY_PROVIDER }}' | ||
service_account: '${{ secrets.SERVICE_ACCOUNT }}' | ||
|
||
- name: Build op-proposer | ||
run: | | ||
cd programs/proposer | ||
cargo build --release | ||
- name: Push to GCP | ||
run: | | ||
gcloud auth configure-docker $DOCKER_REGISTRY | ||
docker build -f Dockerfile.op_proposer -t $$DOCKER_REGISTRY/${{ secrets.GCP_PROJECT_ID }}/op-succinct-proposer:${{ github.ref_name }} . | ||
docker push $$DOCKER_REGISTRY/${{ secrets.GCP_PROJECT_ID }}/op-succinct-proposer:${{ github.ref_name }} | ||
working-directory: proposer/op |