Skip to content

Commit

Permalink
[dy] Update notification config docs (mage-ai#1789)
Browse files Browse the repository at this point in the history
  • Loading branch information
dy46 authored Jan 19, 2023
1 parent d257ae4 commit 0325284
Show file tree
Hide file tree
Showing 3 changed files with 66 additions and 4 deletions.
26 changes: 24 additions & 2 deletions docs/production/observability/alerting-email.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ description: "Get status updates sent to your email inbox."
src="https://yourreclaimedlife.com/wp-content/uploads/2018/12/email-marketing-without-permission.jpg"
/>

## Configure email settings
## Create notification_config

In the root of your project’s folder (e.g. `default_repo/`), open the file
`metadata.yaml`.
Expand All @@ -21,10 +21,32 @@ In the root of your project’s folder (e.g. `default_repo/`), open the file
> didn’t customize it.
In the `default_repo/metadata.yaml` file, add a section with the following
configuration:
configuration or update the existing `notification_config` section:

```yaml
notification_config:
alert_on:
- trigger_failure
- trigger_passed_sla
```
If you omit the `alert_on` section it will default to `trigger_failure` and `trigger_passed_sla`.

Options:

- `trigger_failure`: alert when a run of a trigger fails
- `trigger_success`: alert when a run of a trigger succeeds
- `trigger_passed_sla`: alert when a run of a trigger passes sla

## Configure email settings

In the `default_repo/metadata.yaml` file, add a section with the following
configuration or update the existing `notification_config` section:

```yaml
notification_config:
alert_on:
...
email_config:
smtp_host: ...
smtp_mail_from: ...
Expand Down
22 changes: 21 additions & 1 deletion docs/production/observability/alerting-slack.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,30 @@ Follow these steps to add that webhook URL to your project settings:
http://localhost:6789/pipelines/example_pipeline/edit).
3. In your left sidebar in the file browser, scroll all the way down and click
on a file named `metadata.yaml`.
4. In the `metadata.yaml` file, add the following values:
4. In the `metadata.yaml` file, add a section with the following
configuration or update the existing `notification_config` section:

```yaml
notification_config:
alert_on:
- trigger_failure
- trigger_passed_sla
```
If you omit the `alert_on` section it will default to `trigger_failure` and `trigger_passed_sla`.

Options:

- `trigger_failure`: alert when a run of a trigger fails
- `trigger_success`: alert when a run of a trigger succeeds
- `trigger_passed_sla`: alert when a run of a trigger passes sla

5. In the `metadata.yaml` file, add the following values:

```yaml
notification_config:
alert_on:
...
slack_config:
webhook_url: ...
```
Expand Down
22 changes: 21 additions & 1 deletion docs/production/observability/alerting-teams.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,30 @@ Follow these steps to add that webhook URL to your project settings:
http://localhost:6789/pipelines/example_pipeline/edit).
3. In your left sidebar in the file browser, scroll all the way down and click
on a file named `metadata.yaml`.
4. In the `metadata.yaml` file, add the following values:
4. In the `metadata.yaml` file, add a section with the following
configuration or update the existing `notification_config` section:

```yaml
notification_config:
alert_on:
- trigger_failure
- trigger_passed_sla
```
If you omit the `alert_on` section it will default to `trigger_failure` and `trigger_passed_sla`.

Options:

- `trigger_failure`: alert when a run of a trigger fails
- `trigger_success`: alert when a run of a trigger succeeds
- `trigger_passed_sla`: alert when a run of a trigger passes sla

5. In the `metadata.yaml` file, add the following values:

```yaml
notification_config:
alert_on:
...
teams_config:
webhook_url: 'https://teams.webhook.office.com/webhookb2/B04XXXXGY67/IncomingWebhook/1UgUkao8pXXXXPmsuXXXX2lk'
```
Expand Down

0 comments on commit 0325284

Please sign in to comment.