From 59b5e7d717b6d1cacbab080b46a3ccb1d2e0e7da Mon Sep 17 00:00:00 2001 From: Gustavo Flores Date: Wed, 20 May 2026 13:37:49 -0300 Subject: [PATCH] fix: move secret check from job-level to step-level on sync-dashboard-team --- .github/workflows/sync-dashboard-team.yaml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/workflows/sync-dashboard-team.yaml b/.github/workflows/sync-dashboard-team.yaml index 831532edb..697f4c384 100644 --- a/.github/workflows/sync-dashboard-team.yaml +++ b/.github/workflows/sync-dashboard-team.yaml @@ -29,8 +29,10 @@ permissions: jobs: # Add validation checks for Pull Requests validate: - if: github.event_name == 'pull_request' && secrets.ORG_ADMIN_TOKEN != '' + if: github.event_name == 'pull_request' runs-on: ubuntu-latest + env: + ORG_ADMIN_TOKEN: ${{ secrets.ORG_ADMIN_TOKEN }} permissions: contents: read @@ -51,11 +53,12 @@ jobs: run: npm ci - name: Dry run + if: env.ORG_ADMIN_TOKEN != '' working-directory: .github/scripts run: node sync-dashboard-team.js env: DRY_RUN: true - GITHUB_TOKEN: ${{ secrets.ORG_ADMIN_TOKEN }} + GITHUB_TOKEN: ${{ env.ORG_ADMIN_TOKEN }} ORG: kernelci TEAM_SLUG: dashboard