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

add alerting documentation #381

Merged
merged 1 commit into from
Oct 20, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions source/apps/alerting.html.md.erb
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
---
title: Alerting on an app
weight: 55
last_reviewed_on: 2023-10-19
review_in: 12 months
owner_slack: "#analytical-platform-support"
owner_slack_workspace: "mojdt"
---

<%= partial 'documentation/apps/alerting' %>
38 changes: 38 additions & 0 deletions source/documentation/apps/alerting.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
# Enabling alerting

To enable alerting on your application:
- Navigate to your application repository
- Clone the repo down locally
- Alerts are configured in the following paths
- `<repo_name>.github/workflows/build-push-deploy-dev.yml`
- `<repo_name>.github/workflows/build-push-deploy-prod.yml`
- Add this syntax in the helm upgrade section of the required workflow(s) `--set Alerts.enabled=true`
- Merge your pr, alerts will then be enabled

You can find the current configured alerts below once enabled all these alerts will become active provided you have the required resources to alert on.

## Alert config
------------
| config | default | description |
| --------------- | -------------------------------------------- | --------------- |
| Alerts.enabled | `false` | enable alerting |
| Alerts.severity | `data-platform-application-migration-alerts` | severity label, used by CloudPlatform for sending Alerts to specific pager duty services |
| Alerts.cpuUsage | `"60"` | Trigger alert if Pod CPU % exceeds this level |
| Alerts.memoryUsage | `"80"` | Trigger alert if Pod memory exceeds the specified value of the resource limit (%) |
| Alerts.pvcUsage | `"90"` | Trigger alert if PVC storage exceeds the specified value (%) |

## Current configured alerts

- `5xxingress` - The ingress for the namespace is returning a high average of 500 error codes over a 1 minute period.
- `OOMKiller` - Pod killed due to OOM issues
- `TooManyContainerRestarts` - pod container(s) are restarting too many times, exceeding 20 restarts (indicative of app crashing over and over again)
- `CrashLoopBackOff` - Container has entered into a crashloop backoff state.
- `PodNotReadyKube` - Pod stuck in Pending|Unknown state
- `WebappRestartAlert` - The webapp has restarted
- `AuthProxyRestartAlert` - The Auth Proxy has restarted
- `CpuUsageHigh` - The Pod CPU usage has exceeded the specified percentage
- `MemUsageHigh` - The Pod Memory usage has exceeded the specified percentage
- `HighPersistantVolumeUsage` - PVC storage has exceeded limit

If you require any alerts not listed please send a feature request to our [support channel](https://github.com/ministryofjustice/data-platform-support)