This directory contains all the GitHub Actions workflows for the Order Management Service.
- Trigger: Push or pull request to
mainordevelopbranches - Jobs:
- Build and Test: Compiles the application and runs all tests
- Docker Build: Builds and tests the Docker image
- Code Quality: Runs SonarQube analysis and OWASP Dependency Check
- Trigger: Push to
developbranch - Jobs:
- Deploy to Staging: Builds and deploys the application to the staging environment
- Health check: Verifies the deployment was successful
- Trigger: Release publication
- Jobs:
- Deploy to Production: Builds and deploys the application to the production environment
- Health check: Verifies the deployment was successful
- Notifications: Sends success/failure notifications
- Trigger: Scheduled weekly, push or pull request to
mainordevelopbranches - Jobs:
- Security Scan: Runs OWASP Dependency Check and SpotBugs security analysis
For the workflows to work correctly, you need to set up the following secrets in your GitHub repository:
DOCKERHUB_USERNAME: Your Docker Hub usernameDOCKERHUB_TOKEN: Your Docker Hub access tokenSONAR_TOKEN: Your SonarQube token (if using SonarQube)
spotbugs-security-include.xml: Defines which security bugs to include in the analysisspotbugs-security-exclude.xml: Defines which security bugs to exclude from the analysis
You can customize these workflows based on your specific requirements:
- Modify trigger conditions in the
onsection - Adjust build steps and commands
- Add or remove jobs based on your deployment strategy
- Configure notifications for workflow success/failure