diff --git a/.github/workflows/auto-update-semconv.yml b/.github/workflows/auto-update-semconv.yml index cc7be61..32f14cb 100644 --- a/.github/workflows/auto-update-semconv.yml +++ b/.github/workflows/auto-update-semconv.yml @@ -18,6 +18,8 @@ jobs: already-opened: ${{ steps.check-versions.outputs.already-opened }} steps: - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 + with: + persist-credentials: false - id: check-versions name: Check versions @@ -63,6 +65,8 @@ jobs: with: # using custom token so the changelog PR link update push triggers workflows token: ${{ steps.otelbot-token.outputs.token }} + # zizmor: ignore[artipacked] App credentials are required by the branch pushes below. + persist-credentials: true - name: Update version env: diff --git a/.github/workflows/build-common.yml b/.github/workflows/build-common.yml index 7c20b83..7a61111 100644 --- a/.github/workflows/build-common.yml +++ b/.github/workflows/build-common.yml @@ -56,6 +56,8 @@ jobs: steps: - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 + with: + persist-credentials: false - id: setup-java-test name: Set up Java ${{ matrix.test-java-version }} for tests @@ -74,13 +76,16 @@ jobs: - uses: gradle/actions/setup-gradle@3f131e8634966bd73d06cc69884922b02e6faf92 # v6.2.0 - name: build + shell: bash run: > ./gradlew build -PtestJavaVersion=${{ matrix.test-java-version }} - "-Porg.gradle.java.installations.paths=${{ steps.setup-java-test.outputs.path }},${{ steps.setup-java.outputs.path }}" + "-Porg.gradle.java.installations.paths=${STEPS_SETUP_JAVA_TEST_OUTPUTS_PATH},${STEPS_SETUP_JAVA_OUTPUTS_PATH}" env: DEVELOCITY_ACCESS_KEY: ${{ secrets.DEVELOCITY_ACCESS_KEY }} + STEPS_SETUP_JAVA_TEST_OUTPUTS_PATH: ${{ steps.setup-java-test.outputs.path }} + STEPS_SETUP_JAVA_OUTPUTS_PATH: ${{ steps.setup-java.outputs.path }} - name: generate # Skip running on macos-latest which doesn't have docker if: matrix.os == 'ubuntu-latest' diff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.yml index 0c08a08..f84e1a9 100644 --- a/.github/workflows/codeql.yml +++ b/.github/workflows/codeql.yml @@ -30,6 +30,8 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 + with: + persist-credentials: false - name: Set up Java 21 if: matrix.language == 'java' @@ -38,8 +40,9 @@ jobs: distribution: temurin java-version: 21 - # This workflow analyzes release branches but does not build or publish release artifacts. - - name: Set up gradle # zizmor: ignore[cache-poisoning] + - name: Set up gradle + # zizmor: ignore[cache-poisoning] This workflow analyzes release branches + # but does not build or publish release artifacts. if: matrix.language == 'java' uses: gradle/actions/setup-gradle@3f131e8634966bd73d06cc69884922b02e6faf92 # v6.2.0 diff --git a/.github/workflows/fossa.yml b/.github/workflows/fossa.yml index c2593c6..6fa8ed3 100644 --- a/.github/workflows/fossa.yml +++ b/.github/workflows/fossa.yml @@ -13,6 +13,8 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 + with: + persist-credentials: false - uses: fossas/fossa-action@29693cc50323968e039056be419b32989fc5880c # v2.0.0 with: diff --git a/.github/workflows/gradle-wrapper-validation.yml b/.github/workflows/gradle-wrapper-validation.yml index 6252285..6c2dfc7 100644 --- a/.github/workflows/gradle-wrapper-validation.yml +++ b/.github/workflows/gradle-wrapper-validation.yml @@ -12,6 +12,8 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 + with: + persist-credentials: false # this needs to be in its own workflow in order to make OSSF scorecard happy - uses: gradle/actions/wrapper-validation@3f131e8634966bd73d06cc69884922b02e6faf92 # v6.2.0 diff --git a/.github/workflows/issue-management-feedback-label.yml b/.github/workflows/issue-management-feedback-label.yml index 56664b3..a9b5b4d 100644 --- a/.github/workflows/issue-management-feedback-label.yml +++ b/.github/workflows/issue-management-feedback-label.yml @@ -19,6 +19,8 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 + with: + persist-credentials: false - name: Remove labels env: diff --git a/.github/workflows/prepare-release-branch.yml b/.github/workflows/prepare-release-branch.yml index c8bf4b8..de8d2f5 100644 --- a/.github/workflows/prepare-release-branch.yml +++ b/.github/workflows/prepare-release-branch.yml @@ -10,6 +10,8 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 + with: + persist-credentials: false - name: Verify prerequisites run: | @@ -35,6 +37,8 @@ jobs: # history is needed to allow fast-forward push below in case # re-running this workflow after merging additional PRs to main fetch-depth: 0 + # zizmor: ignore[artipacked] Credentials are required by the branch pushes below. + persist-credentials: true - name: Create release branch run: | @@ -71,7 +75,7 @@ jobs: - name: Create pull request against the release branch env: - # not using secrets.GITHUB_TOKEN since pull requests from that token do not run workflows + # pull requests from secrets.GITHUB_TOKEN do not run workflows GH_TOKEN: ${{ steps.otelbot-token.outputs.token }} run: | message="Prepare release $VERSION" @@ -80,9 +84,10 @@ jobs: git checkout -b $branch git commit -a -m "$message" git push --set-upstream origin $branch - gh pr create --title "[$RELEASE_BRANCH_NAME] $message" \ - --body "$message." \ - --base $RELEASE_BRANCH_NAME + gh pr create \ + --title "[$RELEASE_BRANCH_NAME] $message" \ + --body "$message." \ + --base $RELEASE_BRANCH_NAME create-pull-request-against-main: permissions: @@ -92,6 +97,9 @@ jobs: - prereqs steps: - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 + with: + # zizmor: ignore[artipacked] Credentials are required by the branch push below. + persist-credentials: true - name: Set environment variables run: | @@ -120,7 +128,7 @@ jobs: - name: Create pull request against main env: - # not using secrets.GITHUB_TOKEN since pull requests from that token do not run workflows + # pull requests from secrets.GITHUB_TOKEN do not run workflows GH_TOKEN: ${{ steps.otelbot-token.outputs.token }} run: | message="Update changelog for $VERSION release" @@ -130,6 +138,7 @@ jobs: git checkout -b $branch git commit -a -m "$message" git push --set-upstream origin $branch - gh pr create --title "$message" \ - --body "$body" \ - --base main + gh pr create \ + --title "$message" \ + --body "$body" \ + --base main diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 41cbab7..c26d47b 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -29,6 +29,8 @@ jobs: fi - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 + with: + persist-credentials: false - uses: actions/setup-java@0f481fcb613427c0f801b606911222b5b6f3083a # v5.5.0 with: @@ -76,6 +78,7 @@ jobs: - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 with: ref: main + persist-credentials: false - name: Check that change log update was merged to main run: | @@ -89,6 +92,7 @@ jobs: with: # tags are needed for the generate-release-contributors.sh script fetch-depth: 0 + persist-credentials: false - name: Generate release notes env: @@ -138,6 +142,8 @@ jobs: # add change log sync (if any) into this PR since the apidiff update # is required before any other PR can be merged anyway - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 + with: + persist-credentials: false - name: Copy change log section from release branch env: @@ -149,6 +155,8 @@ jobs: - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 with: ref: main + # zizmor: ignore[artipacked] Credentials are required by the branch push below. + persist-credentials: true - name: Merge change log to main env: @@ -207,7 +215,7 @@ jobs: - name: Create pull request against main env: VERSION: ${{ needs.release.outputs.version }} - # not using secrets.GITHUB_TOKEN since pull requests from that token do not run workflows + # pull requests from secrets.GITHUB_TOKEN do not run workflows GH_TOKEN: ${{ steps.otelbot-token.outputs.token }} run: | message="Update apidiff baseline to released version $VERSION" @@ -217,6 +225,7 @@ jobs: git checkout -b $branch git commit -m "$message" git push --set-upstream origin $branch - gh pr create --title "$message" \ - --body "$body" \ - --base main + gh pr create \ + --title "$message" \ + --body "$body" \ + --base main diff --git a/.github/workflows/reusable-lint-check.yml b/.github/workflows/reusable-lint-check.yml index 495f231..6abbd5e 100644 --- a/.github/workflows/reusable-lint-check.yml +++ b/.github/workflows/reusable-lint-check.yml @@ -13,6 +13,7 @@ jobs: - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 with: fetch-depth: 0 # needed for merge-base used in modified-files mode + persist-credentials: false - uses: jdx/mise-action@e6a8b3978addb5a52f2b4cd9d91eafa7f0ab959d # v4.2.0