Migrate Jenkins pipeline to GitHub Actions CI/CD workflows#182
Open
devin-ai-integration[bot] wants to merge 3 commits intoDevOpsfrom
Open
Migrate Jenkins pipeline to GitHub Actions CI/CD workflows#182devin-ai-integration[bot] wants to merge 3 commits intoDevOpsfrom
devin-ai-integration[bot] wants to merge 3 commits intoDevOpsfrom
Conversation
Co-Authored-By: Joao Esteves <joao.esteves@cognition.ai>
Author
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
Co-Authored-By: Joao Esteves <joao.esteves@cognition.ai>
Co-Authored-By: Joao Esteves <joao.esteves@cognition.ai>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Migrates the existing Jenkins CI/CD pipeline (
Jenkinsfile+GitOps/Jenkinsfile) to GitHub Actions, producing two workflow files:CI Pipeline (
.github/workflows/ci.yml)Replaces the root
Jenkinsfile. Runs on push/PR tomain/DevOpsand via manual dispatch.actions/checkout@v4aquasecurity/trivy-action@0.35.0(fs mode)dependency-check/Dependency-Check_Action@main+ artifact uploadSonarSource/sonarqube-scan-action@v4(conditional onSONAR_ENABLEDvariable)SonarSource/sonarqube-quality-gate-action@v1docker/build-push-action@v6+docker/login-action@v3(gracefully degrades to local-only build when credentials are missing)actions/github-script@v7dispatchescd.ymlSecurity scans (Trivy, OWASP, SonarQube) run in parallel; Docker build/push gates on all three. A Trivy image scan was also added post-build as a bonus.
CD Pipeline (
.github/workflows/cd.yml)Replaces
GitOps/Jenkinsfile. Triggered by CI or manual dispatch with adocker_taginput.kubernetes/bankapp-deployment.yaml) viasedGH_PATfor write access)Required GitHub Secrets & Variables
Before running, configure these in Settings → Secrets and variables → Actions:
SONAR_TOKENSONAR_HOST_URLDOCKERHUB_TOKENGH_PATDOCKERHUB_USERmadhupdevops)SONAR_ENABLEDtrueto enable SonarQube analysisCI Status Explanation
SONAR_ENABLED=truevariable +SONAR_TOKEN/SONAR_HOST_URLsecrets)Dockerfile— the base imageopenjdk:17-alpinehas been removed from Docker Hub. This affects any CI system, not just GH Actions. Fix: replace witheclipse-temurin:17-jre-alpinein the Dockerfile.Review & Testing Checklist for Human
FROM openjdk:17-alpine as deployerwithFROM eclipse-temurin:17-jre-alpine as deployerworkflow_dispatch) and confirm all jobs passNotes
vars/*.groovy) are left in place to avoid breaking any other Jenkins consumers.--failOnCVSS 11on OWASP effectively makes the check non-blocking (matching the original Jenkins behavior). Lower this threshold to enforce stricter checks.workflow_dispatch.DOCKERHUB_USER/DOCKERHUB_TOKENare not set, the image is built locally only (no push), and a warning annotation is emitted.Link to Devin session: https://app.devin.ai/sessions/ff2b17cb9f5f484293ff8a52756b6fc0
Requested by: @joao-cognition
Devin Review