Skip to content

Commit

Permalink
fix: pass CODECOV_TOKEN to reusable workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
binbin-li committed Sep 14, 2024
1 parent aa0523b commit 0511997
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 4 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/build-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ permissions: read-all
jobs:
call_test_cli:
uses: ./.github/workflows/e2e-cli.yml
secrets:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}

call_test_e2e_basic:
name: "run e2e on basic matrix"
Expand Down
11 changes: 7 additions & 4 deletions .github/workflows/e2e-cli.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@ name: e2e-cli

on:
workflow_call:
secrets:
CODECOV_TOKEN:
required: true

permissions:
contents: read
Expand Down Expand Up @@ -50,8 +53,8 @@ jobs:
run: bin/ratify version
- name: Upload coverage to codecov.io
uses: codecov/codecov-action@e28ff129e5465c2c0dcc6f003fc735cb6ae0c673 # v4.5.0
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
with:
token: $${{ secrets.CODECOV_TOKEN }}
- name: Run helm lint
run: helm lint charts/ratify
build_test_cli:
Expand Down Expand Up @@ -83,8 +86,8 @@ jobs:
make test-e2e-cli GOCOVERDIR=${GITHUB_WORKSPACE}/test/e2e/.cover
- name: Upload coverage to codecov.io
uses: codecov/codecov-action@e28ff129e5465c2c0dcc6f003fc735cb6ae0c673 # v4.5.0
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
with:
token: $${{ secrets.CODECOV_TOKEN }}
markdown-link-check:
runs-on: ubuntu-latest
steps:
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/run-full-validation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ permissions: read-all
jobs:
call-e2e-cli:
uses: ./.github/workflows/e2e-cli.yml
secrets:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}

call_test_e2e_full:
name: "Build and run e2e on full test matrix"
Expand Down

0 comments on commit 0511997

Please sign in to comment.