Skip to content

Added Cors Policy

Added Cors Policy #7

Workflow file for this run

name: cd
on:
push:
paths:
- 'backend/**'
branches:
- main
jobs:
deploy:
name: deploy
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- id: 'auth'
uses: 'google-github-actions/auth@v2'
with:
credentials_json: '${{ secrets.GCP_CREDENTIALS }}'
- name: 'Set up Cloud SDK'
uses: 'google-github-actions/setup-gcloud@v2'
- name: 'Build and Deploy Image To Artifact Registry'
run: |
cd backend
gcloud builds submit --tag us-central1-docker.pkg.dev/my-portfolio-441113/polcon-backend/polcon-backend:latest
- name: Deploy to Cloud Run
run: gcloud run deploy polcon-backend --image us-central1-docker.pkg.dev/my-portfolio-441113/polcon-backend/polcon-backend:latest --region us-central1 --allow-unauthenticated --project my-portfolio-441113 --max-instances=4 --set-secrets=GOOGLE_GEMINI_API_KEY=GOOGLE_GEMINI_API_KEY:latest