Skip to content

Conversation

@devin-ai-integration
Copy link

Summary

This PR migrates the existing Jenkins CI/CD pipelines to GitHub Actions by adding two new workflow files:

  • CI Pipeline (.github/workflows/ci.yml): Replaces the root Jenkinsfile with equivalent GitHub Actions steps including Trivy scanning, OWASP dependency check, SonarQube analysis, Maven build, Docker image build/push, and CD workflow triggering via repository dispatch.

  • CD Pipeline (.github/workflows/cd.yml): Replaces GitOps/Jenkinsfile with a workflow that updates the Kubernetes manifest with the new Docker image tag, commits/pushes changes, and sends email notification.

Review & Testing Checklist for Human

  • Verify SonarQube URL: The CI workflow contains a placeholder http://your-sonarqube-server:9000 that needs to be updated to the actual SonarQube server URL before use
  • Configure required secrets: Ensure the following secrets are configured in the repository settings: SONAR_TOKEN, DOCKER_USERNAME, DOCKER_PASSWORD, EMAIL_USERNAME, EMAIL_PASSWORD
  • Verify email recipient: The CD workflow sends notifications to trainwithshubham@gmail.com - confirm this is the intended recipient

Recommended test plan:

  1. Merge this PR to DevOps branch
  2. Trigger the CI workflow manually via workflow_dispatch to verify the pipeline runs
  3. Check that the CD workflow is triggered correctly via repository dispatch
  4. Verify Kubernetes manifest is updated and email notification is sent

Notes

  • The CI workflow triggers on pushes to the DevOps branch (matching the original Jenkins setup)
  • Docker images are tagged with github.sha instead of the manual DOCKER_TAG parameter from Jenkins
  • The existing Jenkins pipelines (Jenkinsfile and GitOps/Jenkinsfile) are preserved and can be removed after validating the GitHub Actions workflows

Link to Devin run: https://app.devin.ai/sessions/6489e975cd5e4227b4f85e0d0a2773af
Requested by: Shawn Azman (@ShawnAzman)

- Add CI workflow (.github/workflows/ci.yml) that:
  - Triggers on push to DevOps branch and manual dispatch
  - Sets up JDK 17
  - Runs Trivy filesystem scan
  - Runs OWASP Dependency Check
  - Runs SonarQube analysis
  - Builds with Maven
  - Builds and pushes Docker image to Docker Hub
  - Triggers CD workflow via repository dispatch
  - Archives OWASP reports as artifacts

- Add CD workflow (.github/workflows/cd.yml) that:
  - Triggers on repository dispatch from CI workflow
  - Updates Kubernetes manifest with new Docker image tag
  - Commits and pushes changes
  - Sends email notification

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
@devin-ai-integration
Copy link
Author

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment and CI monitoring

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants