By creating a Noibu release monitoring webhook from your GitHub repo with GitHub Actions, you can notify Noibu when changes are shipped to your domain, and report on whether the deployment succeeded or failed. This provides engineers with an easy way to correlate code deployments with new issues.
Prerequisites
Before beginning this process, retrieve your Domain's Unique ID String.
Process
Configuring a GitHub webhook requires you to modify an existing GitHub Actions workflow YAML file or create a new one. Visit the GitHub Actions Documentation to learn more about this process.
- To create a new workflow, open Actions and click New Workflow.
- To modify an existing workflow, search within the
.github/workflows
path in your repo.
Once you have chosen a workflow to process the webhook notification, create the job that will be responsible for making a POST request to the Noibu webhook URL.
An example workflows YAML file might look like this:
name: Send Release Event to Noibu example
on:
# Define when to trigger the workflow. For example, on push or manually:
push:
branches:
- main
jobs:
post-noibu-events-webhook:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set Current Time
run: echo "CURRENT_TIME=$(date -u +'%Y-%m-%d %H:%M:%S+00:00')" >> $GITHUB_ENV
- name: Make POST request to Noibu Webhook URL
run: |
curl -X POST "https://webhook.noibu.com/release_webhook/<YOUR_DOMAIN_ID>" \
-H "Content-Type: application/json" \
-d '{
"component":"frontend",
"title":"November 2023 release #3",
"description":"Changed PDP styling",
"status":"success",
"version":"'"$GITHUB_SHA"'",
"release_time":"'"$CURRENT_TIME"'"
}'
Within the YAML, you are free to set any valid trigger to run the workflow containing the webhook update. In this standard example, the webhook will be notified upon a push to the main branch.
Furthermore, you are free to configure any variables you’d like as string input into any of the fields used for the webhook notification request. This example pulls the triggering commit hash as the version
field and the current time as the release_time
field.
This process utilizes the Noibu generic webhook under the hood, the URL and payload will follow the same rules as defined in our guide to Configuring a Generic Webhook.
Webhook URL
https://webhook.noibu.com/release_webhook/<YOUR_DOMAIN_ID>
Webhook Request Body
The request body must include the following fields:
Field | Format | Description |
---|---|---|
component | String | What piece of your site did you release? (open field: "frontend", "backend", "checkout", "marketing", etc...) |
title | String | Summary of the release. This will likely be configured as a variable. |
description | String | Details about the release. Value can be “null”. This will likely be configured as a variable. |
status | String | Did the release successfully deploy or was there an error? ("success" or "failed") This will likely be configured as a variable. |
version | String | What version number/hash ID of the software was released? (open field: "1.0.0", commit hash, or ticket ID) This will likely be configured as a variable. |
release_time | String | The time the release went live. Use the RFC3339 timestamp. This will likely be configured as a variable. |
Noibu also accommodates a Jenkins Webhook, a GitLab Webhook, and a Generic Webhook.