SAP Commerce Cloud - Build
This GitHub Action provides the following functionalities to perform build operations on SAP Commerce Cloud in the Public Cloud (CCv2) projects.
Project Status
🚀 Completed Items
- Trigger Build: Trigger SAP Commerce Cloud build.
- Build Notification: Sends a notification when a build is triggered in CCv2.
- Build Status Notification: Frequently check the build status and send notifications when success or failure.
- Retry On Failure: Retry the build creation if it fails for the maxRetries times.
- Notifications: Notify the user via email or webhook when the build is triggered or completed.
- Create Build: Triggered with build is created in CCv2.
- Build Completed: Triggered when the build is completed in CCv2 whether it is success or failure.
- Slack: Send notifications to Slack.
- Microsoft Teams: Send notifications to Microsoft Teams.
🔧 Planned Items
- Testing: Improve test coverage with end-to-end tests.
- Notifications: Notify the user via email or webhook when the build is triggered or completed.
- Email: Send notifications to email.
- SendGrid: Send notifications using SendGrid.
- AWS SES: Send notifications using AWS SES.
- Custom SMTP: Send notifications using custom SMTP.
- Similar SMTP services.
Getting Started
Check this GitHub Action on the GitHub Marketplace
Example Workflow
Create a workflow YAML file (e.g., .github/workflows/build.yml
) in your repository with the following content:
Environment Variables
Variable | Purpose | Required |
---|---|---|
SAP_CCV2_API_TOKEN | SAP Commerce Cloud in the Public Cloud (CCv2) API Token. | True |
SAP_CCV2_SUB_CODE | SAP Commerce Cloud in the Public Cloud (CCv2) Subscription Code | True |
WEBHOOK_URL | The Webhook URL to send notifications. | False |
Inputs
Attribute | Purpose | Required | Default | Example |
---|---|---|---|---|
branch | The branch name or tag to trigger the build. | True | release/v1.0.0 | |
buildName | The name of the build. | False | ||
checkStatusInterval | The interval in milliseconds to check the build status. | False | 300000 (5 minutes) | |
retryOnFailure | Retry the build if failed. | False | false | |
maxRetries | The maximum number of retries. | False | 3 | |
notify | Send notifications on the build status. | False | false | |
dryRun | Run the action in dry-run mode. If true, the action will not trigger the build in actual CCv2. | False | false | |
timezone | The timezone to use for the timestamps. | False | America/New_York |
Outputs
buildCode
- The build code of the triggered build.buildStatus
- The status of the triggered build.