From 784352ebf48ac39765f818b15c4afaaf57c41720 Mon Sep 17 00:00:00 2001 From: Jakub Al-Khalili Date: Thu, 17 Oct 2019 16:27:42 +0200 Subject: [PATCH] Add notification doc --- .../Getting Started/v0.3.0/notifications.md | 114 ++++++++++++++++++ 1 file changed, 114 insertions(+) create mode 100644 website/content/en/docs/Getting Started/v0.3.0/notifications.md diff --git a/website/content/en/docs/Getting Started/v0.3.0/notifications.md b/website/content/en/docs/Getting Started/v0.3.0/notifications.md new file mode 100644 index 00000000..a769afeb --- /dev/null +++ b/website/content/en/docs/Getting Started/v0.3.0/notifications.md @@ -0,0 +1,114 @@ +--- +title: "Notifications" +linkTitle: "Notifications" +weight: 10 +date: 2019-08-05 +description: > + How to setup operator notifications. +--- + +## Slack + +Please follow [this](https://api.slack.com/incoming-webhooks) instructions to get web hook URL. + +Create web hook secret with name `jenkins-operator-notification-data`. Contains key `url` with provided web hook URL. + +```bash +$ kubectl create secret generic jenkins-operator-notification-data --from-literal=url= +``` + +Example configuration for Slack: + +``` +kind: Jenkins +spec: + master: + notifications: + - loggingLevel: info + verbose: true + name: + slack: + webHookURLSecretKeySelector: + secret: + name: + key: +``` + +## Microsoft Teams + +Please follow [this](https://docs.microsoft.com/en-gb/outlook/actionable-messages/send-via-connectors) instructions to get web hook URL. + +Example configuration for Microsoft Teams: + +``` +kind: Jenkins +spec: + master: + notifications: + - loggingLevel: info + verbose: true + name: + teams: + webHookURLSecretKeySelector: + secret: + name: + key: +``` + +## Mailgun + +Example configuration for Mailgun: + +``` +kind: Jenkins +spec: + master: + notifications: + - loggingLevel: info + verbose: true + name: + mailgun: + domain: + apiKeySecretKeySelector: + secret: + name: + key: + recipient: + from: +``` + +## Debug options + +As you see there is two debugging options: + +* `loggingLevel` (warning/info) - Set level of messages to send. + +* `verbose` - Print stacktrace and additional error messages + +## Multiple providers + +You can use multiple providers to send notification to another communication channels at the same time. +For example you will send notifications to Slack and Teams. + +``` +kind: Jenkins +spec: + master: + notifications: + - loggingLevel: info + verbose: true + name: nslack + slack: + webHookURLSecretKeySelector: + secret: + name: + key: + - loggingLevel: info + verbose: true + name: nteams + teams: + webHookURLSecretKeySelector: + secret: + name: + key: +``` \ No newline at end of file