-
Notifications
You must be signed in to change notification settings - Fork 301
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #41 from grafana/dev
Merge dev to main
- Loading branch information
Showing
77 changed files
with
549 additions
and
2,464 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,4 +5,5 @@ frontend/node_modules | |
frontend/build | ||
package-lock.json | ||
./engine/extensions | ||
.env | ||
.env | ||
.env-hobby |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,6 +3,7 @@ | |
*.pyc | ||
venv | ||
.env | ||
.env_hobby | ||
.vscode | ||
dump.rdb | ||
.idea | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,76 +1,61 @@ | ||
# Grafana OnCall Incident Response | ||
Grafana OnCall, cloud version of Grafana OnCall: https://grafana.com/products/cloud/ | ||
<img width="400px" src="docs/img/logo.png"> | ||
|
||
Developer-friendly, incident response management with brilliant Slack integration. | ||
- Connect monitoring systems | ||
- Collect and analyze data | ||
- On-call rotation | ||
- Automatic escalation | ||
- Never miss alerts with calls and SMS | ||
Developer-friendly, incident response with brilliant Slack integration. | ||
|
||
 | ||
<img width="60%" src="screenshot.png"> | ||
|
||
- Collect and analyze alerts from multiple monitoring systems | ||
- On-call rotations based on schedules | ||
- Automatic escalations | ||
- Phone calls, SMS, Slack, Telegram notifications | ||
|
||
## Getting Started | ||
OnCall consists of two parts: | ||
1. OnCall backend | ||
2. "Grafana OnCall" plugin you need to install in your Grafana | ||
|
||
### How to run OnCall backend | ||
1. An all-in-one image of OnCall is available on docker hub to run it: | ||
We prepared multiple environments: [production](PRODUCTION.md), [developer](DEVELOPER.md) and hobby: | ||
|
||
1. Download docker-compose.yaml: | ||
```bash | ||
docker run -it --name oncall-backend -p 8000:8000 grafana/oncall-all-in-one | ||
curl https://github.com/grafana/oncall/blob/dev/docker-compose.yml -o docker-compose.yaml | ||
``` | ||
|
||
2. When the image starts up you will see a message like this: | ||
2. Set variables: | ||
```bash | ||
👋 This script will issue an invite token to securely connect the frontend. | ||
Maintainers will be happy to help in the slack channel #grafana-oncall: https://slack.grafana.com/ | ||
Your invite token: <TOKEN>, use it in the Grafana OnCall plugin. | ||
echo "DOMAIN=http://localhost | ||
SECRET_KEY=my_random_secret_must_be_more_than_32_characters_long | ||
RABBITMQ_PASSWORD=rabbitmq_secret_pw | ||
MYSQL_PASSWORD=mysql_secret_pw | ||
COMPOSE_PROFILES=with_grafana # Remove this line if you want to use existing grafana | ||
GRAFANA_USER=admin | ||
GRAFANA_PASSWORD=admin" > .env_hobby | ||
``` | ||
|
||
3. If you started your container detached with -d check the log: | ||
3. Launch services: | ||
```bash | ||
docker logs oncall-backend | ||
docker-compose --env-file .env_hobby -f docker-compose.yml up --build -d | ||
``` | ||
|
||
### How to install "Grafana OnCall" Plugin and connect with a backend | ||
1. Open Grafana in your browser and login as an Admin | ||
2. Navigate to Configuration → Plugins | ||
3. Type Grafana OnCall into the "Search Grafana plugins" field | ||
4. Select the Grafana OnCall plugin and press the "Install" button | ||
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 | ||
4. Issue one-time invite token: | ||
```bash | ||
docker-compose --env-file .env_hobby -f docker-compose.yml run engine python manage.py issue_invite_for_the_frontend --override | ||
``` | ||
OnCall has not been setup, configure & initialize below. | ||
|
||
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_: | ||
``` | ||
6. Fill in configuration fields using the token you got from the backend earlier, then press "Install Configuration" | ||
Invite token: ^^^ from the previous step. | ||
OnCall backend URL: http://engine:8080 | ||
Grafana Url: http://grafana:3000 | ||
``` | ||
OnCall API URL: (The URL & port used to access OnCall) | ||
http://host.docker.internal:8000 | ||
OnCall Invitation Token (Single use token to connect Grafana instance): | ||
Invitation token from docker startup | ||
|
||
Grafana URL (URL OnCall will use to talk to this Grafana instance): | ||
http://localhost:3000 (or http://host.docker.internal:3000 if your grafana is running in Docker locally) | ||
``` | ||
6. Enjoy! | ||
|
||
## Getting Help | ||
- `#grafana-oncall` channel at https://slack.grafana.com/ | ||
- Grafana Labs community forum for OnCall: https://community.grafana.com | ||
- File an [issue](https://github.com/grafana/oncall/issues) for bugs, issues and feature suggestions. | ||
|
||
## Production Setup | ||
## Join community | ||
|
||
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. | ||
<a href="https://github.com/grafana/oncall/discussions/categories/community-calls"><img width="200px" src="docs/img/community_call.png"></a> | ||
<a href="https://github.com/grafana/oncall/discussions"><img width="200px" src="docs/img/GH_discussions.png"></a> | ||
<a href="https://slack.grafana.com/"><img width="200px" src="docs/img/slack.png"></a> | ||
|
||
## Further Reading | ||
- *Documentation* - [Grafana OnCall](https://grafana.com/docs/grafana-cloud/oncall/) | ||
- *Blog Post* - [Announcing Grafana OnCall, the easiest way to do on-call management](https://grafana.com/blog/2021/11/09/announcing-grafana-oncall/) | ||
- *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) | ||
|
||
## FAQ | ||
|
||
- How do I generate a new invitation token to connect plugin with a backend? | ||
```bash | ||
docker exec oncall-backend python manage.py issue_invite_for_the_frontend --override | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.