When a Datadog alert fires, you might be doing something more important. But, you don't want to forget about it. With this workflow, you can automatically create an issue in Jira issue when a Datadog event is received.
Before you run this workflow, you will need the following:
- A Datadog account.
- An instance of Jira available to the internet. Jira Server and Jira Cloud are both supported.
Follow these steps to configure the workflow. Doing this will enable Relay to listen for alerts from Datadog and create tickets in Jira.
Follow these instructions to set up your Datadog trigger.
From the main workflow page, find the datadog
trigger and click the Copy webhook URL button.
In Datadog, add a new webhook:
- Click on the Integrations menu option.
- Install or configure the Webhooks Integration.
- Under Webhooks, click New +.
- Provide a meaningful name (e.g.
relay-webhook
) - Paste the URL to the webhook URL found in Relay.
- Additional properties can be added to the payload for workflow customization.
- Provide a meaningful name (e.g.
- Click Save.
Configure the Datadog monitor:
- Within the Monitor, click Settings(⚙) -> Edit
- Under Say what's happening, add the above webhook with
@webhook-{name of webhook}
(e.g.@webhook-relay
)
- Click Save
- Click Fill in missing connections or click Settings in the side nav.
-
Fill out the form to create a Connection to your Jira instance.
- jiraURL - The URL to the root of your Jira instance. For Jira Cloud, this is
https://your-domain.atlassian.net
. - jiraUsername - The username to use when authenticating to Jira.
- jiraToken - The API token (for Jira Cloud) or password to use when authenticating to Jira.
- jiraURL - The URL to the root of your Jira instance. For Jira Cloud, this is
-
Click Save
Configure the default Jira project where you will create the tickets.
- Navigate to the Code tab.
- Find the parameter for
jiraProjectKey
and specify thedefault:
project (e.g.OPS
) where tickets will be created.
jiraProjectKey:
description: the JIRA project key to use when creating tickets
default: OPS
To test the Datadog alert:
- Navigate to the Monitor that you configured earlier.
- Click Settings(⚙) -> Edit
- Scroll to the bottom of the page and click Test Notifications
- Select Alert (default)
- Click Run Test