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

feat: Add custom headers support for Webhook AlertMethod #383

Merged
merged 4 commits into from
Jan 13, 2025

Conversation

kskitek
Copy link
Contributor

@kskitek kskitek commented Jan 12, 2025

Motivation

Webhook alert method does not support custom HTTP headers now.

Summary

  • the headers in .tf are split into headers and sensitive_headers to allow settings secrets..
resource "nobl9_alert_method_webhook" "webhook" {
  name            = "webhook"
  project         = "default"
  url             = "http://web.net"
  template        = "SLO needs attention $slo_name"
  headers         = {
    "X-Custom-Header" = "custom value"
  }
  sensitive_headers = {
    "Authorization" = "Bearer xyz"
  }
}

Release Notes

Webhook alert method now supports custom HTTP headers.

@n9-machine-user n9-machine-user added enhancement New feature or request go Pull requests that update Go code minor New functionality with at most minor breaking changes labels Jan 12, 2025
nobl9/resource_alertmethod.go Show resolved Hide resolved
nobl9/resource_alertmethod.go Outdated Show resolved Hide resolved
@kskitek kskitek requested a review from nieomylnieja January 13, 2025 09:45
@kskitek kskitek enabled auto-merge (squash) January 13, 2025 10:43
@kskitek kskitek merged commit 04ba643 into main Jan 13, 2025
5 checks passed
@kskitek kskitek deleted the add-webhook-customheaders branch January 13, 2025 10:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request go Pull requests that update Go code minor New functionality with at most minor breaking changes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants