|
1 |
| -# Grafana OnCall Incident Response |
2 |
| -Grafana OnCall, cloud version of Grafana OnCall: https://grafana.com/products/cloud/ |
| 1 | +<img width="400px" src="docs/img/logo.png"> |
3 | 2 |
|
4 |
| -Developer-friendly, incident response management with brilliant Slack integration. |
5 |
| -- Connect monitoring systems |
6 |
| -- Collect and analyze data |
7 |
| -- On-call rotation |
8 |
| -- Automatic escalation |
9 |
| -- Never miss alerts with calls and SMS |
| 3 | +Developer-friendly, incident response with brilliant Slack integration. |
10 | 4 |
|
11 |
| - |
| 5 | +<img width="60%" src="screenshot.png"> |
| 6 | + |
| 7 | +- Collect and analyze alerts from multiple monitoring systems |
| 8 | +- On-call rotations based on schedules |
| 9 | +- Automatic escalations |
| 10 | +- Phone calls, SMS, Slack, Telegram notifications |
12 | 11 |
|
13 | 12 | ## Getting Started
|
14 |
| -OnCall consists of two parts: |
15 |
| -1. OnCall backend |
16 |
| -2. "Grafana OnCall" plugin you need to install in your Grafana |
17 | 13 |
|
18 |
| -### How to run OnCall backend |
19 |
| -1. An all-in-one image of OnCall is available on docker hub to run it: |
| 14 | +We prepared multiple environments: [production](PRODUCTION.md), [developer](DEVELOPER.md) and hobby: |
| 15 | + |
| 16 | +1. Download docker-compose.yaml: |
20 | 17 | ```bash
|
21 |
| -docker run -it --name oncall-backend -p 8000:8000 grafana/oncall-all-in-one |
| 18 | +curl https://github.com/grafana/oncall/blob/dev/docker-compose.yml -o docker-compose.yaml |
22 | 19 | ```
|
23 | 20 |
|
24 |
| -2. When the image starts up you will see a message like this: |
| 21 | +2. Set variables: |
25 | 22 | ```bash
|
26 |
| -👋 This script will issue an invite token to securely connect the frontend. |
27 |
| -Maintainers will be happy to help in the slack channel #grafana-oncall: https://slack.grafana.com/ |
28 |
| -Your invite token: <TOKEN>, use it in the Grafana OnCall plugin. |
| 23 | +echo "DOMAIN=http://localhost |
| 24 | +SECRET_KEY=my_random_secret_must_be_more_than_32_characters_long |
| 25 | +RABBITMQ_PASSWORD=rabbitmq_secret_pw |
| 26 | +MYSQL_PASSWORD=mysql_secret_pw |
| 27 | +COMPOSE_PROFILES=with_grafana # Remove this line if you want to use existing grafana |
| 28 | +GRAFANA_USER=admin |
| 29 | +GRAFANA_PASSWORD=admin" > .env_hobby |
29 | 30 | ```
|
30 | 31 |
|
31 |
| -3. If you started your container detached with -d check the log: |
| 32 | +3. Launch services: |
32 | 33 | ```bash
|
33 |
| -docker logs oncall-backend |
| 34 | +docker-compose --env-file .env_hobby -f docker-compose.yml up --build -d |
34 | 35 | ```
|
35 | 36 |
|
36 |
| -### How to install "Grafana OnCall" Plugin and connect with a backend |
37 |
| -1. Open Grafana in your browser and login as an Admin |
38 |
| -2. Navigate to Configuration → Plugins |
39 |
| -3. Type Grafana OnCall into the "Search Grafana plugins" field |
40 |
| -4. Select the Grafana OnCall plugin and press the "Install" button |
41 |
| -5. On the Grafana OnCall Plugin page Enable the plugin and go to the Configuration tab you should see a status field with the message |
| 37 | +4. Issue one-time invite token: |
| 38 | +```bash |
| 39 | +docker-compose --env-file .env_hobby -f docker-compose.yml run engine python manage.py issue_invite_for_the_frontend --override |
42 | 40 | ```
|
43 |
| -OnCall has not been setup, configure & initialize below. |
| 41 | + |
| 42 | +5. Go to [OnCall Plugin Configuration](http://localhost:3000/plugins/grafana-oncall-app) (or find OnCall plugin in configuration->plugins) and connect OnCall _plugin_ with OnCall _backend_: |
44 | 43 | ```
|
45 |
| -6. Fill in configuration fields using the token you got from the backend earlier, then press "Install Configuration" |
| 44 | +Invite token: ^^^ from the previous step. |
| 45 | +OnCall backend URL: http://engine:8080 |
| 46 | +Grafana Url: http://grafana:3000 |
46 | 47 | ```
|
47 |
| -OnCall API URL: (The URL & port used to access OnCall) |
48 |
| -http://host.docker.internal:8000 |
49 |
| -
|
50 |
| -OnCall Invitation Token (Single use token to connect Grafana instance): |
51 |
| -Invitation token from docker startup |
52 | 48 |
|
53 |
| -Grafana URL (URL OnCall will use to talk to this Grafana instance): |
54 |
| -http://localhost:3000 (or http://host.docker.internal:3000 if your grafana is running in Docker locally) |
55 |
| -``` |
| 49 | +6. Enjoy! |
56 | 50 |
|
57 |
| -## Getting Help |
58 |
| -- `#grafana-oncall` channel at https://slack.grafana.com/ |
59 |
| -- Grafana Labs community forum for OnCall: https://community.grafana.com |
60 |
| -- File an [issue](https://github.com/grafana/oncall/issues) for bugs, issues and feature suggestions. |
61 | 51 |
|
62 |
| -## Production Setup |
| 52 | +## Join community |
63 | 53 |
|
64 |
| -Looking for the production instructions? We're going to release them soon. Please join our Slack channel to be the first to know about them. |
| 54 | +<a href="https://github.com/grafana/oncall/discussions/categories/community-calls"><img width="200px" src="docs/img/community_call.png"></a> |
| 55 | +<a href="https://github.com/grafana/oncall/discussions"><img width="200px" src="docs/img/GH_discussions.png"></a> |
| 56 | +<a href="https://slack.grafana.com/"><img width="200px" src="docs/img/slack.png"></a> |
65 | 57 |
|
66 | 58 | ## Further Reading
|
67 | 59 | - *Documentation* - [Grafana OnCall](https://grafana.com/docs/grafana-cloud/oncall/)
|
68 | 60 | - *Blog Post* - [Announcing Grafana OnCall, the easiest way to do on-call management](https://grafana.com/blog/2021/11/09/announcing-grafana-oncall/)
|
69 | 61 | - *Presentation* - [Deep dive into the Grafana, Prometheus, and Alertmanager stack for alerting and on-call management](https://grafana.com/go/observabilitycon/2021/alerting/?pg=blog)
|
70 |
| - |
71 |
| -## FAQ |
72 |
| - |
73 |
| -- How do I generate a new invitation token to connect plugin with a backend? |
74 |
| -```bash |
75 |
| -docker exec oncall-backend python manage.py issue_invite_for_the_frontend --override |
76 |
| -``` |
0 commit comments