Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stream Cirrus CI webhook events to DataDog #2

Merged
merged 10 commits into from
Jul 13, 2023
Merged

Conversation

edigaryev
Copy link
Contributor

@edigaryev edigaryev commented Jul 11, 2023

The resulting event looks in DataDog like this:

Screenshot 2023-07-11 at 22 32 31

Resolves #1.

@edigaryev edigaryev requested a review from fkorotkov July 11, 2023 18:29
Comment on lines 123 to 126
evt := &statsd.Event{
Title: fmt.Sprintf("Webhook event of type %s", eventType),
Text: string(body),
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does it support some tags? To annotate it with repository name, user id, etc. Events should be useful and not just some raw dump of webhooks.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems that DataDog actually treats the Text as JSON and allows filtering by it's fields:

Screenshot 2023-07-12 at 00 02 08

I've added some tags in 648ecaf anyway.

@edigaryev edigaryev requested a review from fkorotkov July 11, 2023 20:50
.cirrus.yml Outdated Show resolved Hide resolved
.cirrus.yml Outdated Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
@edigaryev edigaryev requested a review from fkorotkov July 12, 2023 23:51
@edigaryev edigaryev merged commit 1617ce1 into main Jul 13, 2023
@edigaryev edigaryev deleted the audit-events-to-datadog branch July 13, 2023 14:53
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.

Cirrus CI audit events + DataDog intergration example
2 participants