Skip to content

use env for job

use env for job #3

Workflow file for this run

name: Deploy to Google Cloud Functions
on:
push:
branches:
- main # or your default branch
workflow_dispatch: # allows manual triggers
jobs:
deploy:
runs-on: ubuntu-latest
environment: cicd
steps:
- uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '>=22.0.0'
cache: 'npm'
- name: Install dependencies
run: npm ci
- name: Build
run: npm run build
- id: 'auth'
uses: google-github-actions/auth@v2
with:
credentials_json: '${{ secrets.GCP_SA_KEY }}'
project_id: ${{ vars.GCP_PROJECT_ID }}
- name: Setup Google Cloud SDK
uses: google-github-actions/setup-gcloud@v2
with:
project_id: ${{ vars.GCP_PROJECT_ID }}
- name: Deploy to Cloud Run Functions
run: |
just deploy