Mint tax and cash #2592
Workflow file for this run
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
name: Stencilbook | |
on: | |
push: | |
branches: [main, master] | |
pull_request: | |
workflow_dispatch: | |
env: | |
ACTIONS_ALLOW_UNSECURE_COMMANDS: true | |
jobs: | |
deploy: | |
name: Deploy to static site bucket | |
runs-on: ubuntu-latest | |
permissions: | |
contents: "read" | |
id-token: "write" | |
strategy: | |
fail-fast: false | |
matrix: | |
package: | |
- mint-components | |
- bedrock-components | |
- paypal-components | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Node Setup | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 14.x | |
- name: Install npm dependencies | |
run: cd packages/${{ matrix.package }} && npm install | |
- name: Build | |
run: cd packages/${{ matrix.package }} && NODE_ENV=dev npm run build | |
- name: Authenticate with Google Cloud | |
id: auth | |
uses: google-github-actions/auth@v0 | |
with: | |
token_format: "access_token" | |
workload_identity_provider: "projects/167728399658/locations/global/workloadIdentityPools/github/providers/github" | |
service_account: "github-static-site-actions@static-site-proxy.iam.gserviceaccount.com" | |
- name: Setup GCP | |
id: setup_gcp | |
uses: google-github-actions/setup-gcloud@v0 | |
- name: Deploy to bucket (pull request) | |
if: ${{ github.event_name == 'pull_request' }} | |
run: gsutil -m rsync -d -r packages/${{ matrix.package }}/www/ gs://stencilbook_static_saasquatch/${{ matrix.package }}/pr${{ github.event.number }}/ | |
- name: Deploy to bucket (push) | |
if: ${{ github.event_name == 'push' }} | |
run: gsutil -m rsync -d -r packages/${{ matrix.package }}/www/ gs://stencilbook_static_saasquatch/${{ matrix.package }}/production/ |