Skip to content

Remove a comment at the first line of gh actions #2

Remove a comment at the first line of gh actions

Remove a comment at the first line of gh actions #2

name: Deploy to Google App Engine
# This section defines when the workflow will be triggered.
on:
push:
branches:
# Trigger the workflow on pushes to the 'dev' branch.
- main
# This section defines the jobs that will be run as part of the workflow.
jobs:
build:
runs-on: ubuntu-latest

Check failure on line 13 in .github/workflows/deploy-to-prod.yaml

View workflow run for this annotation

GitHub Actions / .github/workflows/deploy-to-prod.yaml

Invalid workflow file

You have an error in your yaml syntax on line 13
deploy:
# Specifies the runner environment for the job.
runs-on: ubuntu-latest
# Defines the permissions granted to the GITHUB_TOKEN for this job.
permissions:
contents: 'read'
id-token: 'write'
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it.
- name: Checkout repository
uses: actions/checkout@v4
# Authenticates to Google Cloud using Workload Identity Federation.
- name: Authenticate to Google Cloud
uses: google-github-actions/auth@v2
with:
# The JSON-formatted service account key for authentication.
credentials_json: ${{ secrets.DEV_SA_KEY }}
# Sets up the Google Cloud SDK in the runner environment.
- name: Set up Cloud SDK
uses: google-github-actions/setup-gcloud@v2
with:
# The Google Cloud project ID to use.
project_id: ${{ secrets.DEV_PROJECT_ID }}
# Deploys the application to Google App Engine.
- name: Deploy to App Engine
run: gcloud app deploy prod.yaml --quiet