Skip to content

Commit

Permalink
CI: upload to GCP
Browse files Browse the repository at this point in the history
  • Loading branch information
AdamOlech committed Oct 19, 2023
1 parent 9c0c9ee commit 3bf663a
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions .github/workflows/workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,10 @@ jobs:
strategy:
matrix: ${{ fromJSON(needs.Prepare-Workload.outputs.matrix) }}

permissions:
contents: 'read'
id-token: write

steps:
- uses: actions/checkout@v3
- uses: actions/cache@v3
Expand Down Expand Up @@ -120,6 +124,29 @@ jobs:
path: |
build/**/*-result.json
- id: gcp-auth
name: GCP Authentcation
uses: google-github-actions/auth@v1
with:
service_account: ${{ secrets.GCP_SA }}
workload_identity_provider: ${{ secrets.GCP_WORKLOAD_IDENTITY_PROVIDER }}
cleanup_credentials: true
create_credentials_file: true
export_environment_variables: false

- name: Set up Cloud SDK
uses: google-github-actions/setup-gcloud@v1
env:
GOOGLE_GHA_CREDS_PATH: ${{ steps.gcp-auth.outputs.credentials_file_path }}
with:
version: '>= 363.0.0'

- name: Upload artifacts to GCP
run: |
gsutil -m rsync -r build/ gs://zephyr-samples-builder/zephyr/$ZEPHYR_VERSION
Print-status:
needs: Build
runs-on: ubuntu-latest
Expand Down

0 comments on commit 3bf663a

Please sign in to comment.