diff --git a/.github/workflows/govulncheck.yaml b/.github/workflows/govulncheck.yaml index afbeb1ef..30710a9e 100644 --- a/.github/workflows/govulncheck.yaml +++ b/.github/workflows/govulncheck.yaml @@ -22,6 +22,8 @@ on: branches: - 'main' pull_request: + branches: + - 'main' schedule: - cron: '0 2 * * *' diff --git a/.github/workflows/lint.yaml b/.github/workflows/lint.yaml index bbcc1715..e729f9c0 100644 --- a/.github/workflows/lint.yaml +++ b/.github/workflows/lint.yaml @@ -15,6 +15,8 @@ name: lint on: pull_request: + branches: + - 'main' # Declare default permissions as read only. permissions: read-all diff --git a/.github/workflows/sample-tests.yaml b/.github/workflows/sample-tests.yaml index 5f7ed0a1..64391ef2 100644 --- a/.github/workflows/sample-tests.yaml +++ b/.github/workflows/sample-tests.yaml @@ -14,6 +14,8 @@ name: sample on: pull_request: + branches: + - main push: branches: - main @@ -68,8 +70,8 @@ jobs: id: 'auth' uses: google-github-actions/auth@71fee32a0bb7e97b4d33d548e7d957010649d8fa # v2.1.3 with: - workload_identity_provider: ${{ var.PROVIDER_NAME }} - service_account: ${{ var.SERVICE_ACCOUNT }} + workload_identity_provider: ${{ vars.PROVIDER_NAME }} + service_account: ${{ vars.SERVICE_ACCOUNT }} - name: Set up Cloud SDK uses: google-github-actions/setup-gcloud@98ddc00a17442e89a24bbf282954a3b65ce6d200 # v2.1.0 diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index f628379f..6d04548f 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -15,6 +15,8 @@ name: tests on: pull_request: + branches: + - main push: branches: - main @@ -65,8 +67,8 @@ jobs: name: Authenticate to Google Cloud uses: google-github-actions/auth@71fee32a0bb7e97b4d33d548e7d957010649d8fa # v2.1.3 with: - workload_identity_provider: ${{ var.PROVIDER_NAME }} - service_account: ${{ var.SERVICE_ACCOUNT }} + workload_identity_provider: ${{ vars.PROVIDER_NAME }} + service_account: ${{ vars.SERVICE_ACCOUNT }} - name: Set up Cloud SDK uses: google-github-actions/setup-gcloud@98ddc00a17442e89a24bbf282954a3b65ce6d200 # v2.1.0 @@ -76,11 +78,11 @@ jobs: uses: google-github-actions/get-secretmanager-secrets@dc4a1392bad0fd60aee00bb2097e30ef07a1caae # v2.1.3 with: secrets: |- - ALLOYDB_INSTANCE_URI:${{ var.GOOGLE_CLOUD_PROJECT }}/ALLOYDB_INSTANCE_NAME - ALLOYDB_CLUSTER_PASS:${{ var.GOOGLE_CLOUD_PROJECT }}/ALLOYDB_CLUSTER_PASS - IMPERSONATED_USER:${{ var.GOOGLE_CLOUD_PROJECT }}/IMPERSONATED_USER - ALLOYDB_IAM_USER:${{ var.GOOGLE_CLOUD_PROJECT }}/ALLOYDB_PROXY_IAM_USER - ALLOYDB_PSC_INSTANCE_URI:${{ var.GOOGLE_CLOUD_PROJECT }}/ALLOYDB_PSC_INSTANCE_URI + ALLOYDB_INSTANCE_URI:${{ vars.GOOGLE_CLOUD_PROJECT }}/ALLOYDB_INSTANCE_NAME + ALLOYDB_CLUSTER_PASS:${{ vars.GOOGLE_CLOUD_PROJECT }}/ALLOYDB_CLUSTER_PASS + IMPERSONATED_USER:${{ vars.GOOGLE_CLOUD_PROJECT }}/IMPERSONATED_USER + ALLOYDB_IAM_USER:${{ vars.GOOGLE_CLOUD_PROJECT }}/ALLOYDB_PROXY_IAM_USER + ALLOYDB_PSC_INSTANCE_URI:${{ vars.GOOGLE_CLOUD_PROJECT }}/ALLOYDB_PSC_INSTANCE_URI - name: Run tests env: