Skip to content

🌱 Prepare CI, release tooling and the image for v2.5.0 - #1716

Merged
justaugustus merged 10 commits into
ossf:mainfrom
justaugustus:scorecard-naming-and-validation
Oct 11, 2026
Merged

justaugustus merged 10 commits into
ossf:mainfrom
justaugustus:scorecard-naming-and-validation

Conversation

@justaugustus

@justaugustus justaugustus commented Oct 11, 2026 •

Copy link
Copy Markdown
Member

What kind of change does this PR introduce?

CI, release tooling and docs, plus a base-image update, ahead of v2.5.0 (#1710).

What is the current behavior?

  • The Scorecard workflow only runs manually, via ossf/scorecard-action@main, which resolves to the last release's image. Release validation tests the previous release, and this repo's code-scanning results date from July.
  • Workflows have zizmor findings and no zizmor check.
  • The image builds on golang:1.26.5, which lacks the standard-library fixes in 1.26.9 and 1.27.2.
  • Leftovers: GCP Cloud Build configs, a placeholder codeql.js that only exists so CodeQL's javascript job has input, an unreachable Go method, a stale e2e README, and "Scorecards" naming (including the installer's default config path, which upstream renamed).
  • RELEASE.md has TODOs and a broken starter-workflow step.

What is the new behavior (if this is a feature change)?

  • postsubmits.yml (on push to main, weekly, manual): builds and pushes ghcr.io/ossf/scorecard-action:latest, then runs Scorecard with that image and publishes results. It follows the results API's workflow restrictions: no id-token on the image job, no global env. ghcr.yml now only builds tagged release images.

  • zizmor.yml presubmit, pinned to zizmor 1.30.1; existing findings fixed; Dependabot gets a 7-day cooldown.

  • Image built on golang:1.27.2 with a refreshed distroless base (replaces 🌱 Bump the docker-images group across 1 directory with 2 updates #1700).

  • CodeQL analyzes actions and go; codeql.js deleted.

  • Cloud Build configs, github.Client.SetTransport and the 2022 e2e notes removed; "Scorecards" becomes "Scorecard". The installer writes scorecard.yml and still recognizes the old names.

  • RELEASE.md: validate via the postsubmits run, concrete starter-workflow steps, and documented release notes.

  • Tests for the changes have been added (for bug fixes/features)

Which issue(s) this PR fixes

NONE

Special notes for your reviewer

  • The docker:// step gets every with: key as an input but none of action.yaml's defaults, so it sets them explicitly. ossf-tests/scorecard-action's scorecard-head workflow already publishes this way. The latest reference is intentionally unpinned (zizmor ignore inline).
  • Verified locally: go build, go vet, go test, deadcode -test (clean), zizmor 1.30.1 on the repo (no findings), markdownlint (no new findings). The first postsubmits.yml run after merge confirms publishing and doubles as v2.5.0's validation.
  • The main ruleset requires Analyze (javascript), which this PR replaces with Analyze (actions). Update the ruleset when merging.

Does this PR introduce a user-facing change?

The action's container image is now built with Go 1.27.2.

The project is named Scorecard. Rename it in the README, and have the
installer create `scorecard.yml` while still recognizing existing
`scorecards.yml` and `scorecards-analysis.yml` workflows.

The installer's default config path also moves to
`starter-workflows/code-scanning/scorecard.yml`, the name the starter
workflow already uses upstream, and the README's link to Scorecard's
installation docs gets its current anchor.

Assisted-by: LLM
Signed-off-by: Stephen Augustus <foo@auggie.dev>
The Scorecard workflow only ran on manual trigger and used
`ossf/scorecard-action@main`, whose action.yaml pins the last released
image, so pre-release validation tested the previous release and the
repository's own code-scanning results went months without updating.

Replace it with postsubmits.yml, which on every push to main (and
weekly) builds and pushes the `latest` image, then runs Scorecard with
that image, uploading SARIF and publishing results. The image job has
no `id-token` permission and the workflow sets no global env, as the
results API requires. ghcr.yml now builds only tagged release images,
with attestation.

Assisted-by: LLM
Signed-off-by: Stephen Augustus <foo@auggie.dev>
- "Validate the Action" now checks the postsubmits run for the commit
  being released, which exercises that commit's image, and says to do
  it before the image tag PR.
- "Update the starter workflow" becomes concrete steps against the
  current `code-scanning/scorecard.yml` path, replacing the undefined
  `GH2` placeholder and the renamed file link.
- Push only the release tag, and fix a table-of-contents anchor.

Assisted-by: LLM
Signed-off-by: Stephen Augustus <foo@auggie.dev>
Ahead of adding a zizmor presubmit, fix what it reports today instead
of suppressing it:

- Set `persist-credentials: false` on every checkout. No job uses the
  persisted git credentials; tests read the token from the environment
  and image pushes use docker/login-action.
- Replace tests.yaml's `permissions: read-all` with `contents: read`.

Assisted-by: LLM
Signed-off-by: Stephen Augustus <foo@auggie.dev>
Run zizmor on pull requests and pushes to main, mirroring
ossf/scorecard-infra's workflow, so workflow security issues are
caught at review time. `advanced-security: false` prints findings and
fails the job on them; in SARIF mode zizmor exits 0 regardless.

Assisted-by: LLM
Signed-off-by: Stephen Augustus <foo@auggie.dev>
@justaugustus justaugustus changed the title 🌱 Rename to "Scorecard", run Scorecard on every merge, and fix RELEASE.md 🌱 Rename to "Scorecard", run Scorecard on every merge, add a zizmor presubmit, and fix RELEASE.md Oct 11, 2026
The presubmit ran zizmor 1.30.1, which adds audits the local 1.23.1
didn't have:

- Give Dependabot version updates a 7-day cooldown, so new releases
  aren't proposed in their first week. Security updates aren't
  affected.
- Mark postsubmits.yml's `latest` image reference as intentionally
  unpinned: it runs the image the previous job pushed from the same
  commit, and `uses:` can't take that job's digest output.
- Pin zizmor-action to zizmor 1.30.1, so new audits arrive as a
  deliberate bump instead of failing unrelated PRs.

Assisted-by: LLM
Signed-off-by: Stephen Augustus <foo@auggie.dev>
- Delete cloudbuild.yaml and cloudbuild-tag.yaml, left over from the
  retired GCP project; ghcr.yml and postsubmits.yml build the images.
- Delete github.Client.SetTransport, which `deadcode -test` reports as
  unreachable.
- Rewrite e2e/README.md, which described the 2022 Bash-to-Go
  migration, the Cloud Build trigger and a test repository that no
  longer exists, to cover the daily runs in ossf-tests that remain.

Assisted-by: LLM
Signed-off-by: Stephen Augustus <foo@auggie.dev>
The builder's golang:1.26.5 lacks the standard library fixes in Go
1.26.9 and 1.27.2. Pin golang:1.27.2, matching Scorecard's images, and
the current gcr.io/distroless/base digest. This replaces Dependabot's
ossf#1700, which proposed golang:1.27.0.

Assisted-by: LLM
Signed-off-by: Stephen Augustus <foo@auggie.dev>
Replace the TODO with the steps used for v2.4.4: start from GitHub's
generated notes, lead with the Scorecard version and its release
notes, list the action's own changes without Dependabot bumps, and
share the draft before publishing.

Assisted-by: LLM
Signed-off-by: Stephen Augustus <foo@auggie.dev>
@justaugustus justaugustus changed the title 🌱 Rename to "Scorecard", run Scorecard on every merge, add a zizmor presubmit, and fix RELEASE.md 🌱 Prepare CI, release tooling and the image for v2.5.0 Oct 11, 2026
The `javascript` CodeQL job existed only to scan codeql.js, a one-line
placeholder; the repository has no JavaScript. Switch the matrix to
`actions` so CodeQL analyzes the GitHub Actions workflows, and delete
the placeholder.

The required check changes from `Analyze (javascript)` to
`Analyze (actions)`; the main ruleset needs the same update.

Assisted-by: LLM
Signed-off-by: Stephen Augustus <foo@auggie.dev>
@github-advanced-security

Copy link
Copy Markdown

You are seeing this message because GitHub Code Scanning has recently been set up for this repository, or this pull request contains the workflow file for the Code Scanning tool.

What Enabling Code Scanning Means:

  • The 'Security' tab will display more code scanning analysis results (e.g., for the default branch).
  • Depending on your configuration and choice of analysis tool, future pull requests will be annotated with code scanning analysis results.
  • You will be able to see the analysis results for the pull request's branch on this overview once the scans have completed and the checks have passed.

For more information about GitHub Code Scanning, check out the documentation.

@justaugustus justaugustus added this to the v2.5.0 milestone Oct 11, 2026
@justaugustus
justaugustus marked this pull request as ready for review October 11, 2026 22:25
@justaugustus
justaugustus requested a review from a team as a code owner October 11, 2026 22:25
@justaugustus
justaugustus merged commit b4b9adf into ossf:main Oct 11, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants