Repository navigation
Harden build pipeline: strict checksums, CodeQL, Dependabot, safer deliver.sh - #2
Conversation
…r.sh Co-Authored-By: oraclefoo@yahoo.com <oraclefoo@yahoo.com>
|
I'll fix CI failures and address comments from users with write access. I'll skip comments containing "(aside)".
|
There was a problem hiding this comment.
👀 1 finding needs your review
Devin reviewed the finding on 7d53387 and left it for you. Click a finding below to jump to its comment.
For your review (1)
| - package-ecosystem: docker | ||
| directory: "/jenkins" | ||
| schedule: | ||
| interval: weekly |
There was a problem hiding this comment.
🟡 Jenkins image updates never run
Docker Dependabot finds no supported manifest under /jenkins because the Maven image exists only in a Jenkinsfile. Its weekly runs cannot update that image.
Learn more
Dependabot's docker ecosystem discovers image references in supported Docker manifests, not Jenkins Pipeline agent declarations. The configured directory contains Jenkinsfile and scripts/deliver.sh, so no dependency is available for this update entry.
Example: When maven:3.9.12-eclipse-temurin-17 becomes available, the weekly Docker job scans /jenkins, finds no Dockerfile, and opens no pull request for the pinned 3.9.11 tag.
Recommended fix: Use an update mechanism that supports Jenkinsfiles, or move the image declaration into a supported manifest consumed by the pipeline. Remove this Dependabot entry if neither approach is adopted, so the configuration does not promise ineffective coverage.
Was this helpful? React with 👍 or 👎 to provide feedback.
Summary
No vulnerable dependencies remain (OSV batch query over the full resolved test classpath — JUnit 6.1.3 and transitives — returns zero advisories after #1). So this PR closes the supply-chain and pipeline gaps instead:
deliver.sh: addedset -euo pipefail, quoted"target/${NAME}-${VERSION}.jar", and replaced the backtick +grep "^[^\[]"scraping ofhelp:evaluatewith$(mvn -q help:evaluate -Dexpression=... -DforceStdout). Previously a failingmvnleftNAME/VERSIONempty and the script still ranjava -jar target/-.jar, and unquoted expansion made the values word-split..github/workflows/build.yml):mvn -B --strict-checksums clean verifyon push/PR, so a tampered or corrupt artifact download fails the build instead of being silently accepted..github/workflows/codeql.yml) withsecurity-extended, weekly plus on PR; least-privilegepermissions:on both workflows..github/dependabot.yml) for maven, github-actions, and the Jenkins docker image.maven:3.9.11-eclipse-temurin-17(was floating3.9), build cache mount changed from the host's root-owned/root/.m2to$HOME/.m2, and a 30-minute pipeline timeout.Verified locally (Maven 3.9.9 / JDK 17):
mvn -B --strict-checksums clean verifypasses,shellcheck jenkins/scripts/deliver.shis clean, anddeliver.shruns end to end printingHello World!.Note: Dependabot alerts are currently disabled on this repo (
GET /dependabot/alerts→ 403), so the config above only drives version-update PRs until you enable Dependabot alerts + security updates in Settings → Code security.Link to Devin session: https://app.devin.ai/sessions/8913315af198494dab7ed91724147f96
Open in Devin Desktop: https://app.devin.ai/desktop/session/8913315af198494dab7ed91724147f96?variant=devin
Requested by: @oraclefoo