Skip to content

Policies

Policies #1763

Workflow file for this run

name: Policies
on:
deployment_status:
workflow_dispatch:
workflow_call:
jobs:
policies:
name: Update Policies
if: github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_call' || github.event.deployment_status.state == 'success' && github.event.deployment_status.environment == 'production'
runs-on: ubuntu-latest
env:
GITHUB_NPM_TOKEN: ${{ secrets.GH_CUSTOM_TOKEN }}
permissions:
id-token: "write"
deployments: "write"
steps:
- uses: actions/checkout@v4
- name: Use Node.js
uses: actions/setup-node@v4
with:
node-version-file: ".nvmrc"
cache: "npm"
- id: "auth"
name: "Authenticate to Google Cloud"
uses: "google-github-actions/auth@v2"
with:
token_format: "access_token"
workload_identity_provider: "projects/914576303414/locations/global/workloadIdentityPools/github-actions-wi-pool/providers/github-actions-wi-provider"
service_account: "[email protected]"
access_token_lifetime: "300s"
- run: npm install
- run: npm run policies:generate
- name: Upload the Policies
uses: "google-github-actions/upload-cloud-storage@v2"
with:
path: policies.v3.json
process_gcloudignore: false
destination: cdn.zuplo.com/portal
headers: |-
content-type: text/plain
cache-control: public, max-age=3600, stale-while-revalidate=30