{"id":341491,"date":"2022-11-20T21:00:08","date_gmt":"2022-11-20T21:00:08","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=341491"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=341491","title":{"rendered":"<span>Grafana OnCall. \u0411\u044b\u0441\u0442\u0440\u043e\u0435 \u0437\u043d\u0430\u043a\u043e\u043c\u0441\u0442\u0432\u043e<\/span>"},"content":{"rendered":"<div><\/div>\n<div id=\"post-content-body\">\n<div>\n<div class=\"article-formatted-body article-formatted-body article-formatted-body_version-2\">\n<div xmlns=\"http:\/\/www.w3.org\/1999\/xhtml\">\n<p><strong>Grafana OnCall<\/strong> &#8212; \u044d\u0442\u043e \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u043e\u043c\u043e\u0436\u0435\u0442 \u043e\u0440\u0433\u0430\u043d\u0438\u0437\u043e\u0432\u0430\u0442\u044c \u043d\u0430\u0434\u0435\u0436\u043d\u043e\u0435 \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0435 \u043f\u0440\u0438 \u0438\u043d\u0446\u0438\u0434\u0435\u043d\u0442\u0430\u0445 \u0434\u043b\u044f \u0432\u0430\u0448\u0435\u0439 \u043a\u043e\u043c\u0430\u043d\u0434\u044b, \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u044e\u0449\u0435\u0435 \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u044e \u0441\u043e Slack \u0438 Telegram.<\/p>\n<p>\u0411\u043e\u043b\u0435\u0435 \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u043e \u043e \u0434\u0430\u043d\u043d\u043e\u043c \u043f\u0440\u043e\u0434\u0443\u043a\u0442\u0443 \u043c\u043e\u0436\u043d\u043e \u0443\u0437\u043d\u0430\u0442\u044c \u0438\u0437 <a href=\"https:\/\/habr.com\/ru\/post\/688794\/\" rel=\"noopener noreferrer nofollow\">\u0441\u0442\u0430\u0442\u044c\u0438<\/a> \u0438\u043b\u0438 \u0438\u0437 <a href=\"https:\/\/www.youtube.com\/watch?v=7uSe1pulgs8&amp;ab_channel=Grafana\" rel=\"noopener noreferrer nofollow\">\u0432\u0438\u0434\u0435\u043e<\/a>. \u0426\u0435\u043b\u044c\u044e \u0436\u0435 \u0434\u0430\u043d\u043d\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0438 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u043e\u0439 \u043b\u0430\u0431\u043e\u0440\u0430\u0442\u043e\u0440\u043a\u0438 \u0432 \u0445\u043e\u0434\u0435 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0432\u044b \u0431\u043b\u0438\u0436\u0435 \u043f\u043e\u0437\u043d\u0430\u043a\u043e\u043c\u0438\u0442\u0435\u0441\u044c \u0441 \u043f\u0440\u043e\u0434\u0443\u043a\u0442\u043e\u043c \u0438 \u043f\u0440\u043e\u0439\u0434\u0435\u0442\u0435 \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u044d\u0442\u0430\u043f\u044b \u0440\u0430\u0431\u043e\u0442 \u0441 \u043d\u0438\u043c.<\/p>\n<p>\u0426\u0435\u043b\u044c \u043b\u0430\u0431\u043e\u0440\u0430\u0442\u043e\u0440\u043a\u0438, \u043a\u0430\u043a \u0438 \u0432\u0441\u0451 \u0432 \u044d\u0442\u043e\u043c \u043c\u0438\u0440\u0435, \u043a\u0440\u0430\u0439\u043d\u0435 \u043f\u0440\u043e\u0441\u0442\u0430 &#8212; \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440 nginx \u0438 \u0435\u0441\u043b\u0438 \u043e\u043d \u043e\u0442\u043a\u043b\u044e\u0447\u0435\u043d \u043f\u0440\u0438\u0441\u043b\u0430\u0442\u044c \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0435 \u0432 Slack. <br \/>\u0426\u0435\u043f\u043e\u0447\u043a\u0430 \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0439 \u0431\u0443\u0434\u0435\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0430\u044f: \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f Prometheus \u0431\u0443\u0434\u0435\u043c \u0441\u0447\u0438\u0442\u044b\u0432\u0430\u0442\u044c \u043c\u0435\u0442\u0440\u0438\u043a\u0438 Nginx \u0438 \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044c \u0438\u0445 \u0432 Grafana. Grafana \u0431\u0443\u0434\u0435\u0442 \u043e\u0442\u0441\u043b\u0435\u0436\u0438\u0432\u0430\u0442\u044c \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043c\u0435\u0442\u0440\u0438\u043a \u0438 \u0440\u0435\u0430\u0433\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043d\u0430 \u043d\u0438\u0445 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c (\u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0435 \u0432 Slack).<\/p>\n<blockquote>\n<p>Grafana &#8212; \u044d\u0442\u043e \u0441\u0435\u0440\u0432\u0438\u0441 \u043f\u043e \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044e \u043c\u0435\u0442\u0440\u0438\u043a\u0430\u043c\u0438 \u0438 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u0430\u043b\u0435\u0440\u0442\u043e\u0432. <br \/>Grafana OnCall &#8212; \u043f\u043b\u0430\u0433\u0438\u043d \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0449\u0438\u0439 \u043d\u0430\u0441\u0442\u0440\u0430\u0438\u0432\u0430\u0442\u044c \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0435 \u043e\u0431 \u0430\u043b\u0435\u0440\u0442\u0430\u0445 \u0431\u043e\u043b\u0435\u0435 \u0434\u0435\u0442\u0430\u043b\u044c\u043d\u043e.<\/p>\n<\/blockquote>\n<p>\u0420\u0430\u0437\u043e\u0431\u044c\u0435\u043c \u043d\u0430\u0448\u0443 \u0437\u0430\u0434\u0430\u0447\u0443 \u043d\u0430 \u0448\u0430\u0433\u0438:<\/p>\n<ul>\n<li>\n<p>\u0417\u0430\u043f\u0443\u0441\u0442\u0438\u043c Grafana\/OnCall \u0432 docker compose;<\/p>\n<\/li>\n<li>\n<p>\u0414\u043e\u0431\u0430\u0432\u0438\u043c \u043f\u043b\u0430\u0433\u0438\u043d \u201cGrafana\/OnCall\u201d \u0432 \u201cGrafana\/Grafana\u201d;<\/p>\n<\/li>\n<li>\n<p>\u0414\u043e\u0431\u0430\u0432\u0438\u043c \u0432 docker compose \u043a\u043e\u043d\u0442\u0435\u0438\u0306\u043d\u0435\u0440 \u201cnginx\u201d \u0438 \u201cprometheus\u201d;<\/p>\n<\/li>\n<li>\n<p>\u041e\u0442\u0441\u043b\u0435\u0434\u0438\u043c \u043c\u0435\u0442\u0440\u0438\u043a\u0438 \u043a\u043e\u043d\u0442\u0435\u0438\u0306\u043d\u0435\u0440\u0430 \u201cnginx\u201d \u043f\u0440\u0438 \u043f\u043e\u043c\u043e\u0449\u0438 \u201cprometheus\u201d \u0438 \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044c \u0438\u0445 \u0432 \u201cGrafana\/OnCall\u201d; <\/p>\n<\/li>\n<li>\n<p>\u041d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438\u0306 \u0440\u0435\u0430\u0433\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0434\u043b\u044f \u0438\u043d\u0446\u0438\u0434\u0435\u043d\u0442\u0430 <em>\u043e\u0441\u0442\u0430\u043d\u043e\u0432 \u0441\u0435\u0440\u0432\u0438\u0441\u0430 <\/em>Nginx;<\/p>\n<\/li>\n<li>\n<p>\u0421\u043e\u0437\u0434\u0430\u0442\u044c \u0431\u043e\u0442\u0430 \u0434\u043b\u044f Slack \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u044e c Grafana\/Oncall;<\/p>\n<\/li>\n<li>\n<p>\u0421\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u0440\u0430\u0441\u043f\u0438\u0441\u0430\u043d\u0438\u044f \u0434\u043b\u044f \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0438\u0306.<\/p>\n<\/li>\n<\/ul>\n<h3>Grafana\/OnCall \u0438 docker compose<\/h3>\n<p><a href=\"https:\/\/github.com\/grafana\/oncall\" rel=\"noopener noreferrer nofollow\">GitHub<\/a>. \u0414\u043b\u044f \u0434\u0430\u043d\u043d\u043e\u0438\u0306 \u0437\u0430\u0434\u0430\u0447\u0438 \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0441\u0440\u0435\u0434\u0443: hobby.<\/p>\n<p>\u0412\u044b\u043f\u043e\u043b\u043d\u0438\u043c \u043a\u043e\u043c\u0430\u043d\u0434\u0443: <\/p>\n<p><code>curl -fsSL https:\/\/raw.githubusercontent.com\/grafana\/oncall\/dev\/docker-compose.yml -o docker-compose.yml<\/code> <\/p>\n<p>\u0412\u044b\u043f\u043e\u043b\u043d\u0438\u043c \u043a\u043e\u043c\u0430\u043d\u0434\u0443: <\/p>\n<p><code>echo \"DOMAIN=http:\/\/localhost:8080 COMPOSE_PROFILES=with_grafana SECRET_KEY=my_random_secret_must_be_more_than_32_characters_long RABBITMQ_PASSWORD=rabbitmq_secret_pw MYSQL_PASSWORD=mysql_secret_pw\" > .env<\/code> <\/p>\n<p>\u0412\u044b\u043f\u043e\u043b\u043d\u0438\u043c \u043a\u043e\u043c\u0430\u043d\u0434\u0443:<\/p>\n<p><code>docker-compose up -d<\/code><\/p>\n<p> \u041e\u0442\u043a\u0440\u043e\u0435\u043c \u043f\u043e\u0440\u0442 3000 \u0432 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0435: <code>localhost:3000<\/code><\/p>\n<p>\u041b\u043e\u0433\u0438\u043d \u0438 \u043f\u0430\u0440\u043e\u043b\u044c &#8212; <strong>admin<\/strong>. \u041f\u043e\u0441\u043b\u0435 \u0432\u0445\u043e\u0434\u0430 \u043d\u0430\u043c \u043f\u0440\u0435\u0434\u043b\u043e\u0436\u0430\u0442 \u0438\u0437\u043c\u0435\u043d\u0438\u0442\u044c \u043f\u0430\u0440\u043e\u043b\u044c, \u044d\u0442\u043e\u0442 \u0448\u0430\u0433 \u043c\u043e\u0436\u043d\u043e \u043f\u0440\u043e\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u043d\u0430\u0436\u0430\u0432 \u043a\u043d\u043e\u043f\u043a\u0443 <strong>skip.<\/strong><\/p>\n<h3>\u041f\u043b\u0430\u0433\u0438\u043d \u201cGrafana\/OnCall\u201d \u0432 \u201cGrafana\/Grafana\u201d<\/h3>\n<p>\u041d\u0430\u0445\u043e\u0434\u044f\u0441\u044c \u043d\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0435 \u201cGrafana\u201d \u0432 \u043f\u0430\u043d\u0435\u043b\u0438 \u043c\u0435\u043d\u044e \u0432 \u043b\u0435\u0432\u043e\u0438\u0306 \u0447\u0430\u0441\u0442\u0438 \u044d\u043a\u0440\u0430\u043d\u0430 \u0432\u044b\u0431\u0435\u0440\u0438\u0442\u0435 \u201cConfiguration\u201d \u0438 \u043f\u0435\u0440\u0435\u0438\u0306\u0434\u0438\u0442\u0435 \u0432 \u0440\u0430\u0437\u0434\u0435\u043b \u201cPlugins\u201d. \u0412 \u043f\u043e\u0438\u0441\u043a\u043e\u0432\u043e\u0438\u0306 \u0441\u0442\u0440\u043e\u043a\u0435 \u043d\u0430\u0431\u0435\u0440\u0438\u0442\u0435 \u201cOnCall\u201d \u0438 \u0432\u044b\u0431\u0435\u0440\u0438\u0442\u0435 \u0435\u0433\u043e. <\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/05b\/ccd\/932\/05bccd932d3f51bb92fa357dbcce9a29.png\" alt=\"Grafana\/Configuration\/Plugins\" title=\"Grafana\/Configuration\/Plugins\" width=\"1120\" height=\"810\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/05b\/ccd\/932\/05bccd932d3f51bb92fa357dbcce9a29.png\"\/><figcaption>Grafana\/Configuration\/Plugins<\/figcaption><\/figure>\n<p>\u0414\u043b\u044f \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u043f\u043b\u0430\u0433\u0438\u043d\u0430 \u043f\u043e\u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u0442\u043e\u043a\u0435\u043d. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u0443: <\/p>\n<p><code>docker-compose run engine python manage.py issue_invite_for_the_frontend --override<\/code> <\/p>\n<p>\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u043d\u044b\u0438\u0306 \u0442\u043e\u043a\u0435\u043d \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0441\u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0438 \u0432\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0432 \u0433\u0440\u0430\u0444\u0443 \u201c<strong>Invite token<\/strong>\u201d, \u043a\u0430\u043a \u043f\u043e\u043a\u0430\u0437\u0430\u043d\u043e \u043d\u0430 \u0441\u043a\u0440\u0438\u043d\u0435 \u043d\u0438\u0436\u0435.<\/p>\n<figure class=\"bordered full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/f45\/da6\/f42\/f45da6f42b6f46fa1a3e7ddd5aded55d.png\" alt=\"Invite token\" title=\"Invite token\" width=\"744\" height=\"774\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/f45\/da6\/f42\/f45da6f42b6f46fa1a3e7ddd5aded55d.png\"\/><figcaption>Invite token<\/figcaption><\/figure>\n<p>\u041d\u0430\u0436\u043c\u0438\u0442\u0435 \u043a\u043d\u043e\u043f\u043a\u0443 \u201c<strong>Enable<\/strong>\u201d \u0434\u043b\u044f \u043f\u043b\u0430\u0433\u0438\u043d\u0430 OnCall, \u0443\u0431\u0435\u0434\u0438\u0442\u0435\u0441\u044c, \u0447\u0442\u043e \u0432\u0432\u0435\u043b\u0438 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u043d\u044b\u0438\u0306 \u0442\u043e\u043a\u0435\u043d \u0432 \u0433\u0440\u0430\u0444\u0443 \u201c<strong>Invite token<\/strong>\u201d \u0438 \u043d\u0430\u0436\u043c\u0438\u0442\u0435 \u201c<strong>Connect<\/strong>\u201d. \u041f\u043e\u0441\u043b\u0435 \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u043f\u043b\u0430\u0433\u0438\u043d Grafana\/OnCall \u043f\u043e\u044f\u0432\u0438\u0442\u0441\u044f \u0432 \u043c\u0435\u043d\u044e \u0431\u044b\u0441\u0442\u0440\u043e\u0433\u043e \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u0432 \u043b\u0435\u0432\u043e\u0438\u0306 \u0447\u0430\u0441\u0442\u0438 \u044d\u043a\u0440\u0430\u043d\u0430.<\/p>\n<h3>Nginx \u0438 Prometheus<\/h3>\n<p>\u0414\u043e\u0431\u0430\u0432\u0438\u043c \u0432 \u0444\u0430\u0438\u0306\u043b <code>docker-compose.yml<\/code> \u043a\u043e\u0434: <\/p>\n<pre><code class=\"python\">web:   image: nginx:1.23.1   ports:     - \"8000:80\"<\/code><\/pre>\n<p>\u0414\u043e\u0431\u0430\u0432\u0438\u043c \u0432 \u0444\u0430\u0438\u0306\u043b docker-compose.yml \u043a\u043e\u0434: <\/p>\n<pre><code class=\"python\">prometheus:   image: prom\/prometheus:latest   volumes:     - .\/prometheus.yml:\/etc\/prometheus\/prometheus.yml   container_name: prometheus   hostname: prometheus   command:     - --config.file=\/etc\/prometheus\/prometheus.yml   ports:     - 9090:9090 restart: unless-stopped networks:     - default<\/code><\/pre>\n<p>\u0412 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044e \u0432 \u0444\u0430\u0438\u0306\u043b\u043e\u043c <code>docker-compose.yml<\/code> \u0434\u043e\u0431\u0430\u0432\u0438\u043c \u043d\u043e\u0432\u044b\u0438\u0306 \u0444\u0430\u0439\u043b <code>prometheus.yml<\/code> \u0438 \u0434\u043e\u0431\u0430\u0432\u0438\u043c \u0432 \u043d\u0435\u0433\u043e \u043a\u043e\u0434: <\/p>\n<pre><code class=\"python\">global:   scrape_interval: 50s #\u043a\u0430\u043a \u0447\u0430\u0441\u0442\u043e \u043e\u0431\u043d\u043e\u0432\u043b\u044f\u0442\u044c \u0442\u0430\u0440\u0433\u0435\u0442   evaluation_interval: 60s #\u043a\u0430\u043a \u0447\u0430\u0441\u0442\u043e \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u044c \u043e\u0446\u0435\u043d\u043a\u0443 \u043f\u0440\u0430\u0432\u0438\u043b   scrape_timeout: 50s #\u0447\u0435\u0440\u0435\u0437 \u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0432\u0440\u0435\u043c\u0435\u043d\u0438 \u0434\u043e \u0438\u0441\u0442\u0435\u0447\u0435\u043d\u0438\u044f \u0441\u0440\u043e\u043a\u0430 \u043e\u0436\u0438\u0434\u0430\u043d\u0438\u044f \u0437\u0430\u043f\u0440\u043e\u0441\u0438\u0442\u044c \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0435  scrape_configs:   - job_name: 'prometheus'     static_configs:       - targets: [ 'localhost:9090' ]   - job_name: 'nginx'     metrics_path: \/metrics     static_configs:       - targets: [ 'web:8000' ]   - job_name: 'grafana'     metrics_path: \/metrics     static_configs:       - targets: [ 'grafana:3000' ]<\/code><\/pre>\n<p>\u0414\u043b\u044f \u043d\u0430\u0433\u043b\u044f\u0434\u043d\u043e\u0441\u0442\u0438 \u043c\u044b \u0434\u043e\u0431\u0430\u0432\u0438\u043c \u0434\u043b\u044f Prometheus 3 \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a\u0430 \u043c\u0435\u0442\u0440\u0438\u043a: Prometheus; Nginx \u0438 Grafana. \u0412\u043d\u043e\u0432\u044c \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u043c \u043a\u043e\u043c\u0430\u043d\u0434\u0443 : <\/p>\n<p><code>docker-compose up -d<\/code><\/p>\n<h3>\u041e\u0442\u0441\u043b\u0435\u0436\u0438\u0432\u0430\u043d\u0438\u0435 \u043c\u0435\u0442\u0440\u0438\u043a \u043a\u043e\u043d\u0442\u0435\u0438\u0306\u043d\u0435\u0440\u0430 Nginx \u043f\u0440\u0438 \u043f\u043e\u043c\u043e\u0449\u0438 Prometheus<\/h3>\n<p>\u041e\u0442\u043a\u0440\u043e\u0435\u043c \u043f\u043e\u0440\u0442 \u201cprometheus\u201d 9090 \u0432 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0435 (localhost:9090). \u0412 \u0432\u0435\u0440\u0445\u043d\u0435\u043c \u043c\u0435\u043d\u044e \u043e\u0442\u043a\u0440\u044b\u0432\u0448\u0435\u0433\u043e\u0441\u044f \u043e\u043a\u043d\u0430 \u0432\u044b\u0431\u0435\u0440\u0435\u043c \u201cStatus\/Targets\u201d, \u043f\u043e\u0434\u043e\u0436\u0434\u0435\u043c \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 \u043c\u0435\u0442\u0440\u0438\u043a. \u041f\u043e \u0438\u0442\u043e\u0433\u0443 \u043c\u044b \u0434\u043e\u043b\u0436\u043d\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/e2f\/3af\/3b6\/e2f3af3b67469a2baa95ffd2b8373667.png\" alt=\"Prometheus 9090\" title=\"Prometheus 9090\" width=\"1350\" height=\"574\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/e2f\/3af\/3b6\/e2f3af3b67469a2baa95ffd2b8373667.png\"\/><figcaption>Prometheus 9090<\/figcaption><\/figure>\n<p>\u041a\u0430\u043a \u0432\u0438\u0434\u0438\u043c \u0434\u0432\u0430 \u0441\u0435\u0440\u0432\u0438\u0441\u0430 \u0438\u0437 \u0442\u0440\u0435\u0445 \u0432 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0438 <strong>\u201cup\u201d<\/strong>. \u041f\u0440\u0438\u0447\u0438\u043d\u0430 \u0432 \u0442\u043e\u043c, \u0447\u0442\u043e \u0434\u043b\u044f \u0441\u0435\u0440\u0432\u0438\u0441\u0430 Nginx \u043d\u0435 \u0432\u043a\u043b\u044e\u0447\u0435\u043d\u0430 \u0444\u0443\u043d\u043a\u0446\u0438\u044f \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u043c\u0435\u0442\u0440\u0438\u043a.<\/p>\n<p>\u0414\u043e\u0431\u0430\u0432\u0438\u043c \u0444\u0443\u043d\u043a\u0446\u0438\u044e \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u043c\u0435\u0442\u0440\u0438\u043a \u0434\u043b\u044f \u043d\u0430\u0448\u0435\u0433\u043e \u043a\u043e\u043d\u0442\u0435\u0438\u0306\u043d\u0435\u0440\u0430 Nginx. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043d\u0430\u043c \u043f\u043e\u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u0438\u0437\u043c\u0435\u043d\u0438\u0442\u044c \u0444\u0430\u0438\u0306\u043b \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438 Nginx <code>default.conf<\/code>.<\/p>\n<p>\u0421\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u0432 \u043d\u0430\u0448\u0435\u0438\u0306 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438 \u0444\u0430\u0438\u0306\u043b <code>default.conf<\/code> \u0438 \u0434\u043e\u0431\u0430\u0432\u0438\u043c \u0432 \u043d\u0435\u0433\u043e \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0438\u0306 \u043a\u043e\u0434:<\/p>\n<pre><code class=\"python\">server {   listen 80;   listen [::]:80;   server_name localhost;    #access_log \/var\/log\/nginx\/host.access.log main; 7   location \/ {     root \/usr\/share\/nginx\/html;     index index.html index.htm;   }  location \/metrics { # \u0422\u0435 \u0441\u0430\u043c\u044b\u0435 \u0441\u0442\u0440\u043e\u043a\u0438 \u043a\u043e\u0434\u0430,   stub_status on;   # \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u043d\u0430\u043c \u043d\u0435 \u0445\u0432\u0430\u0442\u0430\u043b\u043e }  #error_page 404 \/404.html;    error_page 500 502 503 504 \/50x.html;     location = \/50x.html {     root \/usr\/share\/nginx\/html;   }<\/code><\/pre>\n<p>\u0414\u043e\u043f\u043e\u043b\u043d\u0438\u043c \u043a\u043e\u0434 \u0434\u043b\u044f \u0444\u0430\u0438\u0306\u043b\u0430 <code>docker-compose.yml<\/code>: <\/p>\n<pre><code class=\"python\">web:  image: nginx:1.23.1  volumes:   - .\/default.conf:\/etc\/nginx\/conf.d\/default.conf  ports:   - \"8000:80\"<\/code><\/pre>\n<p>\u0418 \u0442\u0430\u043a \u043c\u044b \u043a\u0432\u043b\u044e\u0447\u0438\u043b\u0438 \u043e\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u043c\u0435\u0442\u0440\u0438\u043a \u0434\u043b\u044f \u043d\u0430\u0448\u0435\u0433\u043e Nginx, \u043e\u0434\u043d\u0430\u043a\u043e \u043d\u043e\u0432\u0430\u044f \u0441\u043b\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0441\u043e\u0441\u0442\u043e\u0438\u0442 \u0432 \u0442\u043e\u043c, \u0447\u0442\u043e \u0444\u043e\u0440\u043c\u0430\u0442 \u043c\u0435\u0442\u0440\u0438\u043a Nginx \u043d\u0435 \u043f\u043e\u0434\u0445\u043e\u0434\u0438\u0442 \u0434\u043b\u044f Prometheus. \u0414\u043b\u044f \u0440\u0435\u0448\u0435\u043d\u0438\u044f \u044d\u0442\u043e\u0438\u0306 \u0437\u0430\u0434\u0430\u0447\u0438 \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043a\u043e\u043d\u0442\u0435\u0438\u0306\u043d\u0435\u0440 nginx\/nginx-prometheus-exporter . <\/p>\n<p>\u0414\u043e\u0431\u0430\u0432\u0438\u043c \u0432 \u0444\u0430\u0438\u0306\u043b docker-compose.yml \u043d\u043e\u0432\u044b\u0438\u0306 \u0431\u043b\u043e\u0433 \u043a\u043e\u0434\u0430:<\/p>\n<pre><code class=\"python\">exporter:     image: nginx\/nginx-prometheus-exporter:0.11     ports:       - 9113:9113     command:       - -nginx.scrape-uri=http:\/\/web:80\/metrics<\/code><\/pre>\n<p>\u041d\u0435 \u0437\u0430\u0431\u0443\u0434\u0435\u043c \u043e\u0431\u043d\u043e\u0432\u0438\u0442\u044c \u0444\u0430\u0438\u0306\u043b <code>prometheus.yml<\/code>: <\/p>\n<pre><code class=\"python\">global:   scrape_interval: 50s   evaluation_interval: 60s   scrape_timeout: 50s    scrape_configs:   - job_name: 'prometheus'     static_configs:       - targets: [ 'localhost:9090' ]   - job_name: 'nginx'   metrics_path: \/metrics # \u041f\u0440\u0438\u043c\u0435\u0447\u0430\u043d\u0438\u0435. \u0415\u0441\u043b\u0438 \u043d\u0435 \u0443\u043a\u0430\u0437\u0430\u0442\u044c metrics_path, \u0442\u043e \u043f\u0440\u0438\u043c\u0435\u043d\u0438\u0442\u0441\u044f \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0439 \u043f\u0443\u0442\u044c \/metrics    static_configs:     - targets: [ 'exporter:9113' ] # \u0417\u0430\u043c\u0435\u043d\u0438\u043b\u0438 \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a \u043c\u0435\u0442\u0440\u0438\u043a \u043d\u0430 exporter   - job_name: 'grafana'   metrics_path: \/metrics   static_configs:     - targets: [ 'grafana:3000' ]<\/code><\/pre>\n<p>\u0412\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u0435 \u043e\u0441\u0442\u0430\u043d\u043e\u0432 \u0432\u0441\u0435\u0445 \u043a\u043e\u043d\u0442\u0435\u0438\u0306\u043d\u0435\u0440\u043e\u0432 \u0438 \u043f\u0435\u0440\u0435\u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u0435 docker-compose \u043a\u043e\u043c\u0430\u043d\u0434\u043e\u0438\u0306:<\/p>\n<p> <code>docker-compose up -d<\/code> <\/p>\n<p>\u041f\u043e\u0432\u0442\u043e\u0440\u043d\u043e \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u043c \u0432\u0445\u043e\u0434 \u043d\u0430 \u043f\u043e\u0440\u0442 <code>localhost:9090<\/code>. \u041f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u0440\u0430\u0437\u0434\u0435\u043b \u201c<em>Status\/Targets\u201d. <\/em>\u041d\u0430 \u044d\u0442\u043e\u0442 \u0440\u0430\u0437 \u0441\u0442\u0430\u0442\u0443\u0441\u044b \u0432\u0441\u0435\u0445 \u0440\u0435\u0441\u0443\u0440\u0441\u043e\u0432 \u0434\u043e\u043b\u0436\u043d\u044b \u0431\u044b\u0442\u044c \u0432 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0438  <strong>\u201cup\u201d<\/strong>.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/dbd\/689\/4f0\/dbd6894f06d00e870287fc03e9aaf2df.png\" alt=\"Status\/Targets\" title=\"Status\/Targets\" width=\"1134\" height=\"634\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/dbd\/689\/4f0\/dbd6894f06d00e870287fc03e9aaf2df.png\"\/><figcaption>Status\/Targets<\/figcaption><\/figure>\n<p>\u041f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043a\u0430\u043a\u0438\u0435 \u043c\u0435\u0442\u0440\u0438\u043a\u0438 Prometheus \u0441\u0447\u0438\u0442\u044b\u0432\u0430\u0435\u0442 \u0441 \u0441\u0435\u0440\u0432\u0438\u0441\u0430 Nginx. \u041e\u0442\u043a\u0440\u043e\u0435\u043c \u043f\u043e\u0440\u0442 9113 \u0432 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0435 <code>localhost:9113\/metrics<\/code>. \u0414\u043b\u044f \u043d\u0430\u0448\u0435\u0438\u0306 \u043a\u043e\u043d\u0435\u0447\u043d\u043e\u0438\u0306 \u0437\u0430\u0434\u0430\u0447\u0438 \u043d\u0430\u043c \u043f\u043e\u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u043e\u0442\u0441\u043b\u0435\u0436\u0438\u0432\u0430\u0442\u044c \u043c\u0435\u0442\u0440\u0438\u043a\u0443 <code>nginx_up<\/code> , \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u043e\u0442\u0432\u0435\u0447\u0430\u0435\u0442 \u0437\u0430 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0441\u0435\u0440\u0432\u0438\u0441\u0430 (up\/down).<\/p>\n<figure class=\"\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/a2b\/556\/585\/a2b5565856df27fd355a75854c9e9545.png\" width=\"360\" height=\"148\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/a2b\/556\/585\/a2b5565856df27fd355a75854c9e9545.png\"\/><figcaption><\/figcaption><\/figure>\n<h3>\u041d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438\u0306 \u0440\u0435\u0430\u0433\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0434\u043b\u044f \u0438\u043d\u0446\u0438\u0434\u0435\u043d\u0442\u0430 \u041e\u0441\u0442\u0430\u043d\u043e\u0432 \u0441\u0435\u0440\u0432\u0438\u0441\u0430 Nginx<\/h3>\n<p>\u0414\u043e\u0431\u0430\u0432\u0438\u043c \u043f\u043b\u0430\u0433\u0438\u043d Prometheus \u0432 Grafana. \u041e\u0442\u043a\u0440\u043e\u0435\u043c \u043f\u043e\u0440\u0442 3000 \u0432 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0435 <code>localhost:3000<\/code> \u0438 \u043f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u0440\u0430\u0437\u0434\u0435\u043b \u201c<em>Configurations\/Plugins<\/em>\u201d. \u0412\u044b\u043f\u043e\u043b\u043d\u0438\u043c \u043f\u043e\u0438\u0441\u043a: Prometheus.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/7b6\/865\/7ca\/7b68657caa76dc1eec1df9174208cbfa.png\" alt=\"Prometheus\" title=\"Prometheus\" width=\"836\" height=\"368\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/7b6\/865\/7ca\/7b68657caa76dc1eec1df9174208cbfa.png\"\/><figcaption>Prometheus<\/figcaption><\/figure>\n<p>\u041d\u0430\u0436\u043c\u0435\u043c \u043d\u0430 \u043a\u043d\u043e\u043f\u043a\u0443 \u201cCreate a Prometheus data source\u201d \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u043c \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0306\u043a\u0443. \u041d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0437\u0430\u0434\u0430\u0442\u044c \u043f\u0443\u0442\u044c \u0434\u043e \u0441\u0435\u0440\u0432\u0438\u0441\u0430 Prometheus \u0432 \u0433\u0440\u0430\u0444\u0435 URL, \u043a\u0430\u043a \u043f\u043e\u043a\u0430\u0437\u0430\u043d\u043e \u043d\u0430 \u0441\u043a\u0440\u0438\u043d\u0435 \u043d\u0438\u0436\u0435. <\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/884\/5c0\/bf4\/8845c0bf44d9fdc6c4abf94ceb273eed.png\" alt=\"Create a Prometheus data source\" title=\"Create a Prometheus data source\" width=\"868\" height=\"286\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/884\/5c0\/bf4\/8845c0bf44d9fdc6c4abf94ceb273eed.png\"\/><figcaption>Create a Prometheus data source<\/figcaption><\/figure>\n<p>\u041e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u0435 \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0306\u043a\u0438 \u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u043c \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0438 \u043d\u0430\u0436\u0438\u043c\u0430\u0435\u043c \u201cSave &amp; Test\u201d. <\/p>\n<figure class=\"\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/eee\/632\/cdc\/eee632cdc514ff12e51a59d09590f145.png\" alt=\"Done\" title=\"Done\" width=\"380\" height=\"136\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/eee\/632\/cdc\/eee632cdc514ff12e51a59d09590f145.png\"\/><figcaption>Done<\/figcaption><\/figure>\n<p>\u0421\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u0446\u0435\u043f\u043e\u0447\u043a\u0443 \u044d\u0441\u043a\u0430\u043b\u0430\u0446\u0438\u0438 \u0434\u043b\u044f OnCall (\u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438\u0306 \u0440\u0435\u0430\u0433\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u043d\u0430 \u0438\u043d\u0446\u0438\u0434\u0435\u043d\u0442). \u041f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u0440\u0430\u0437\u0434\u0435\u043b \u201c<em>OnCall\/Escalations Chains<\/em>\u201d.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/eb3\/382\/327\/eb338232792ac0bcb6af322ded15adc4.png\" alt=\"Escalations Chains\" title=\"Escalations Chains\" width=\"756\" height=\"312\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/eb3\/382\/327\/eb338232792ac0bcb6af322ded15adc4.png\"\/><figcaption>Escalations Chains<\/figcaption><\/figure>\n<p>\u041d\u0430\u0448 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438\u0306 \u0431\u0443\u0434\u0435\u0442 \u0443\u0432\u0435\u0434\u043e\u043c\u043b\u044f\u0442\u044c \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f admin \u043e\u0431 \u0438\u043d\u0446\u0438\u0434\u0435\u043d\u0442\u0435, \u0432\u044b\u0436\u0438\u0434\u0430\u0442\u044c 1 \u043c\u0438\u043d\u0443\u0442 \u0438 \u043f\u043e\u0432\u0442\u043e\u0440\u043d\u043e \u043d\u0430\u043f\u0440\u0430\u0432\u043b\u044f\u0442\u044c \u0443\u0432\u0435\u0434\u043e\u043c\u043b\u0435\u043d\u0438\u0435. <\/p>\n<blockquote>\n<p>\u041d\u0430 \u0434\u0430\u043d\u043d\u043e\u043c \u044d\u0442\u0430\u043f\u0435 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0439 \u043d\u0435 \u0431\u0443\u0434\u0435\u0442 \u043f\u043e\u0434\u0440\u0430\u0437\u0443\u043c\u0435\u0432\u0430\u0442\u044c\u0441\u044f \u043f\u0440\u0438\u043c\u0435\u043d\u0435\u043d\u0438\u044f Slack<\/p>\n<\/blockquote>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/a5c\/898\/472\/a5c8984720b06e22a6d04831679fca87.png\" alt=\"My new EChain\" title=\"My new EChain\" width=\"980\" height=\"324\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/a5c\/898\/472\/a5c8984720b06e22a6d04831679fca87.png\"\/><figcaption>My new EChain<\/figcaption><\/figure>\n<p>\u041f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u0440\u0430\u0437\u0434\u0435\u043b \u201cIntegrations\u201d \u0438 \u0441\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u043d\u043e\u0432\u0443\u044e \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u044e \u0434\u043b\u044f \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0438\u0306, \u043d\u0430\u0436\u0430\u0432 \u043a\u043d\u043e\u043f\u043a\u0443 \u201cNew Integration receiving alerts\u201d. \u0412\u044b\u0431\u0435\u0440\u0435\u043c \u201cGrafana Alerting\u201d \u043d\u0430\u0436\u0430\u0432 \u043a\u043d\u043e\u043f\u043a\u0443 \u201cQuick Connect\u201d.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/dc9\/56d\/087\/dc956d087feb6ca50556f892bcfd76eb.png\" alt=\"Grafana Alerting\" title=\"Grafana Alerting\" width=\"1100\" height=\"298\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/dc9\/56d\/087\/dc956d087feb6ca50556f892bcfd76eb.png\"\/><figcaption>Grafana Alerting<\/figcaption><\/figure>\n<p>\u0414\u0430\u043b\u0435\u0435 \u043d\u0430\u0436\u0438\u043c\u0430\u0435\u043c \u201cOpen Escalations Settings\u201d \u0438 \u0432\u044b\u0431\u0435\u0440\u0435\u043c \u0440\u0430\u043d\u0435\u0435 \u0441\u043e\u0437\u0434\u0430\u043d\u043d\u044b\u0438\u0306 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438\u0306 \u044d\u0441\u043a\u0430\u043b\u0430\u0446\u0438\u0438.<\/p>\n<figure class=\"bordered full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/6ff\/828\/941\/6ff828941a57f48ef9001c63cdaa4a0b.png\" alt=\"Open Escalations Settings\" title=\"Open Escalations Settings\" width=\"596\" height=\"512\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/6ff\/828\/941\/6ff828941a57f48ef9001c63cdaa4a0b.png\"\/><figcaption>Open Escalations Settings<\/figcaption><\/figure>\n<p>\u0414\u0430\u043b\u0435\u0435 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0432\u043d\u0435\u0441\u0442\u0438 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0306\u043a\u0438 \u201cContact points\u201d. \u041f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u0440\u0430\u0437\u0434\u0435\u043b \u201cAlerting\/Contact points\u201d.<\/p>\n<figure class=\"\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/497\/030\/ec7\/497030ec7fbf3fbe730d99e67e57e869.png\" alt=\"Contact points\" title=\"Contact points\" width=\"516\" height=\"262\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/497\/030\/ec7\/497030ec7fbf3fbe730d99e67e57e869.png\"\/><figcaption>Contact points<\/figcaption><\/figure>\n<p>\u041f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0306\u043a\u0438 \u0442\u043e\u0447\u043a\u0438 \u0434\u043e\u0441\u0442\u0443\u043f\u0430.<\/p>\n<figure class=\"bordered\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/9ec\/0a9\/1ad\/9ec0a91ad8c5d1a0f1dd28797e3f21ea.png\" alt=\"Grafana Alerting\" title=\"Grafana Alerting\" width=\"318\" height=\"274\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/9ec\/0a9\/1ad\/9ec0a91ad8c5d1a0f1dd28797e3f21ea.png\"\/><figcaption>Grafana Alerting<\/figcaption><\/figure>\n<p>\u0412 \u0433\u0440\u0430\u0444\u0435 URL \u0438\u0437\u043c\u0435\u043d\u0438\u043c \u043f\u0443\u0442\u044c \u0441 <code>localhost:8080<\/code> \u043d\u0430 <code>engine:8080<\/code>.  \u0414\u043b\u044f \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 \u0442\u043e\u0447\u043a\u0438 \u043a\u043e\u043d\u0442\u0430\u043a\u0442\u0430 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u0435 \u201cTest\/Sent test notification\u201d (\u0432 \u043f\u0440\u0430\u0432\u043e\u0438\u0306 \u0447\u0430\u0441\u0442\u0438 \u043e\u043a\u043d\u0430). \u0412\u044b \u0434\u043e\u043b\u0436\u043d\u044b \u0443\u0432\u0438\u0434\u0435\u0442\u044c \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435 \u043e\u0431 \u0443\u0441\u043f\u0435\u0448\u043d\u043e\u043c \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0438 \u0442\u0435\u0441\u0442\u0430. <br \/>\u041d\u0430\u0436\u0438\u043c\u0430\u0435\u043c \u201cSave Contact Point\u201d \u0438 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u043c \u043a \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0435 \u201cNotification policies\u201d, \u0434\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0432\u0443\u044e\u0449\u0438\u0438\u0306 \u0440\u0430\u0437\u0434\u0435\u043b.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/72d\/8c5\/e3e\/72d8c5e3e0de764fa157d0d309fa3dc4.png\" alt=\"Notification policies\" title=\"Notification policies\" width=\"776\" height=\"276\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/72d\/8c5\/e3e\/72d8c5e3e0de764fa157d0d309fa3dc4.png\"\/><figcaption>Notification policies<\/figcaption><\/figure>\n<p>\u041f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u0442 \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0306\u043a\u0438 \u201cRoot policy &#8212; <em>default for all alerts<\/em>\u201d \u0438 \u043f\u043e\u043c\u0435\u043d\u044f\u0435\u043c \u201cDefault contact point\u201d \u043d\u0430 \u0441\u043e\u0437\u0434\u0430\u043d\u043d\u044b\u0438\u0306 \u043d\u0430\u043c\u0438 \u0440\u0430\u043d\u0435\u0435. \u0421\u043e\u0445\u0440\u0430\u043d\u0438\u043c \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f. <\/p>\n<p>\u041f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u0440\u0430\u0437\u0434\u0435\u043b \u201cAlert Rules\u201d \u0434\u043b\u044f \u0437\u0430\u0432\u0435\u0440\u0448\u0435\u043d\u0438\u044f \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043a. <br \/>\u041d\u0430\u0436\u043c\u0435\u043c \u043a\u043d\u043e\u043f\u043a\u0443 \u201cNew Alert Rules\u201d. \u0414\u043b\u044f \u043e\u0442\u0441\u043b\u0435\u0436\u0438\u0432\u0430\u043d\u0438\u0435 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u0441\u0435\u0440\u0432\u0438\u0441\u043e\u0432 \u0432\u044b\u0431\u0435\u0440\u0435\u043c \u043f\u043b\u0430\u0433\u0438\u043d Prometheus, Metric = <code>nginx_up<\/code>.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/481\/570\/e26\/481570e263ccd44cfb661b5ced8da1a2.png\" width=\"770\" height=\"366\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/481\/570\/e26\/481570e263ccd44cfb661b5ced8da1a2.png\"\/><figcaption><\/figcaption><\/figure>\n<p>\u041c\u0435\u0442\u0440\u0438\u043a\u0430 <code>nginx_up<\/code> \u043f\u0435\u0440\u0435\u0434\u0430\u0435\u0442 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 <strong>1 <\/strong>\u043f\u0440\u0438 \u0440\u0430\u0431\u043e\u0442\u0435 \u0441\u0435\u0440\u0432\u0438\u0441\u0430 \u0438 <strong>0 <\/strong>\u043f\u0440\u0438 \u0435\u0433\u043e \u043e\u0442\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0438. \u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u043d\u0430\u043c \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043f\u043e\u043b\u0443\u0447\u0430\u0442\u044c \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0435, \u043a\u043e\u0433\u0434\u0430 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043c\u0435\u0442\u0440\u0438\u043a\u0438 \u043d\u0435 \u0440\u0430\u0432\u043d\u043e <strong>1<\/strong>. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u043c \u043c\u043e\u0434\u0443\u043b\u044c \u201cB &#8212; expression\u201d \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c. <\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/d22\/b44\/265\/d22b442654d245aeaa7cf4064a40f00e.png\" alt=\"B - expression\" title=\"B - expression\" width=\"1054\" height=\"206\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/d22\/b44\/265\/d22b442654d245aeaa7cf4064a40f00e.png\"\/><figcaption>B &#8212; expression<\/figcaption><\/figure>\n<p>\u0412 \u0433\u0440\u0430\u0444\u0435 \u201cSet alert condition\u201d \u0432\u044b\u0431\u0435\u0440\u0435\u043c \u201cB &#8212; expression\u201d. \u0412\u044b\u043f\u043e\u043b\u043d\u0438\u043c \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0443 \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u043e\u0433\u043e Alert \u043d\u0430\u0436\u0430\u0432 \u043a\u043d\u043e\u043f\u043a\u0443 \u201cPreview alert\u201d \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u0432\u044b \u043d\u0435 \u0434\u043e\u043b\u0436\u043d\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u043e\u0448\u0438\u0431\u043a\u0443 \u0432 \u043f\u043e\u044f\u0432\u0438\u0432\u0448\u0435\u043c\u0441\u044f \u043e\u043a\u043d\u0435.<br \/>\u0417\u0430\u043f\u043e\u043b\u043d\u0438\u043c \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e \u0434\u043b\u044f \u0434\u0430\u043d\u043d\u043e\u0433\u043e \u043f\u0440\u0430\u0432\u0438\u043b\u0430 \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u044f.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/147\/e9b\/e9e\/147e9be9e3e456225c3639903e72f039.png\" alt=\"Add details for your alert\" title=\"Add details for your alert\" width=\"1042\" height=\"844\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/147\/e9b\/e9e\/147e9be9e3e456225c3639903e72f039.png\"\/><figcaption>Add details for your alert<\/figcaption><\/figure>\n<p>\u041d\u0430\u0436\u043c\u0435\u043c \u043a\u043d\u043e\u043f\u043a\u0443 \u201cSave and exit\u201d. <\/p>\n<p>\u041f\u0435\u0440\u0435\u0434 \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u043e\u0438\u0306 \u0441\u043e\u0437\u0434\u0430\u043d\u043d\u043e\u0433\u043e \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u044f \u043f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u0440\u0430\u0437\u0434\u0435\u043b \u201cOnCall\/Alert Group\u201d. \u0412 \u0442\u0430\u0431\u043b\u0438\u0446\u0435 \u0431\u0443\u0434\u0435\u0442 \u0440\u0430\u043d\u0435\u0435 \u0441\u043e\u0437\u0434\u0430\u043d\u043d\u043e\u0435 \u043d\u0430\u043c\u0438 \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0435, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u043c\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u0438 \u043f\u0440\u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0438 \u0442\u0435\u0441\u0442\u0430 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438 \u201cContact point\u201d.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/e4b\/24b\/033\/e4b24b0334398b4379808792eb6e23d2.png\" alt=\"TestAlert\" title=\"TestAlert\" width=\"1342\" height=\"70\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/e4b\/24b\/033\/e4b24b0334398b4379808792eb6e23d2.png\"\/><figcaption>TestAlert<\/figcaption><\/figure>\n<h4>\u041f\u0440\u043e\u0432\u0435\u0440\u0438\u043c \u0440\u0430\u0431\u043e\u0442\u0443 \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u043e\u0433\u043e \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u044f<\/h4>\n<p>\u041f\u0440\u043e\u0438\u0437\u0432\u0435\u0434\u0435\u043c \u043e\u0441\u0442\u0430\u043d\u043e\u0432 \u043a\u043e\u043d\u0442\u0435\u0438\u0306\u043d\u0435\u0440\u0430 Nginx \u0438 \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u043c \u0440\u0430\u0431\u043e\u0442\u0443 \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u043e\u0433\u043e \u043d\u0430\u043c\u0438 Grafana\/OnCall. \u041e\u0442\u043a\u0440\u043e\u0435\u043c \u0432 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0435 \u043f\u043e\u0440\u0442 9113 <code>http:\/\/localhost:9113\/metrics<\/code> \u0438 \u0443\u0432\u0438\u0434\u0438\u043c \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0435 \u043e\u0442\u0441\u043b\u0435\u0436\u0438\u0432\u0430\u0435\u043c\u043e\u0438\u0306 \u043d\u0430\u043c\u0438 \u043c\u0435\u0442\u0440\u0438\u043a\u0438 <code>nginx_up<\/code>, \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440 \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u0440\u0430\u0432\u0435\u043d <strong>0<\/strong>.<br \/>\u041f\u0440\u043e\u0432\u0435\u0440\u0438\u043c \u043d\u0430\u043b\u0438\u0447\u0438\u044f \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u044f \u0432 \u201cOnCall\/Alert Group\u201d. <\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/cdd\/6ac\/56c\/cdd6ac56cb413424be11929e11a8e0b1.png\" alt=\"Nginx_onoff\" title=\"Nginx_onoff\" width=\"1066\" height=\"80\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/cdd\/6ac\/56c\/cdd6ac56cb413424be11929e11a8e0b1.png\"\/><figcaption>Nginx_onoff<\/figcaption><\/figure>\n<blockquote>\n<p>\u041e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0435 \u043d\u0435 \u043f\u0440\u0438\u0434\u0435\u0442 \u043c\u0433\u043d\u043e\u0432\u0435\u043d\u043d\u043e: Prometheus \u043e\u0431\u043d\u043e\u0432\u043b\u044f\u0435\u0442 \u043c\u0435\u0442\u0440\u0438\u043a\u0438 \u0440\u0430\u0437 \u0432 60s, \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u044b\u0438\u0306 \u043d\u0430\u043c\u0438 Alert rules \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442 \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0443 \u0440\u0430\u0437 \u0432 \u043c\u0438\u043d\u0443\u0442, \u043f\u043e\u0441\u043b\u0435 \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 \u0438 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f <strong>0 <\/strong>\u043e\u0442 \u043c\u0435\u0442\u0440\u0438\u043a\u0438 <code>nginx_up<\/code> \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044f Alert \u0438\u0437\u043c\u0435\u043d\u0438\u0442\u044c\u0441\u044f \u0441 \u201c<strong>Norm<\/strong>\u201d \u043d\u0430 \u201c<strong>Pending<\/strong>\u201d, \u043e\u0436\u0438\u0434\u0430\u044f \u0432 \u0442\u0435\u0447\u0435\u043d\u0438\u0438 5 \u043c\u0438\u043d\u0443\u0442 \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044f \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044f (<strong>=1<\/strong>) \u0438 \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u043e\u0441\u043b\u0435 \u044d\u0442\u043e\u0433\u043e \u043f\u0435\u0440\u0435\u0432\u0435\u0434\u0435\u0442 Alert \u0432 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u201c<strong>Firing<\/strong>\u201d. <\/p>\n<\/blockquote>\n<p>\u041f\u0440\u043e\u0432\u0435\u0440\u0438\u043c \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u201cAlerting\/Alert rules\u201d. <\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/142\/d39\/b1b\/142d39b1bbe16322ef74ca6b329d9c4d.png\" alt=\"Firing Nginx_onoff\" title=\"Firing Nginx_onoff\" width=\"750\" height=\"772\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/142\/d39\/b1b\/142d39b1bbe16322ef74ca6b329d9c4d.png\"\/><figcaption>Firing Nginx_onoff<\/figcaption><\/figure>\n<h3>\u0421\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u0431\u043e\u0442\u0430 \u0434\u043b\u044f Slack \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u043c \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u044e c Grafana\/Oncall;<\/h3>\n<p>\u0414\u043b\u044f \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u0438 \u0441\u043e Slack \u043a\u043e\u043d\u0442\u0435\u0438\u0306\u043d\u0435\u0440 \u0441 \u0434\u0432\u0438\u0436\u043a\u043e\u043c Grafana\/OnCall (engine) \u0434\u043e\u043b\u0436\u0435\u043d \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b https (<a href=\"https:\/\/github.com\/localtunnel\/localtunnel\" rel=\"noopener noreferrer nofollow\">localtunel<\/a>).<\/p>\n<p>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u043c localtunel \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0432 \u043a\u043e\u043c\u0430\u043d\u0434\u0443 <code>npm install -g localtunnel<\/code> \u0438 \u0434\u043e\u0431\u0430\u0432\u0438\u043c \u0432 \u043d\u0430\u0448 \u043f\u0440\u043e\u0435\u043a\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0432 \u043a\u043e\u043c\u0430\u043d\u0434\u0443 \u0432 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438 \u0441 doker-compose <code>yarn add localtunnel<\/code> <\/p>\n<p>\u0417\u0430\u043f\u0443\u0441\u0442\u0438\u043c \u043a\u043e\u043d\u0442\u0435\u0438\u0306\u043d\u0435\u0440 Grafana\/OnCall (engine) \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b https:<\/p>\n<p><code>lt --port 8080 -s &lt;URL_ADDRESS> --print-requests<\/code> <br \/>\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 <br \/><code>lt --port 8080 -s galgameth-fcm-96 --print-requests<\/code> <\/p>\n<p>\u041e\u0442\u043a\u0440\u043e\u0435\u043c \u043d\u0430\u0448 URL \u0438 \u0437\u0430\u0432\u0435\u0440\u0448\u0438\u043c \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0443.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/8ee\/9c7\/57d\/8ee9c757ddd2d67bddf339e80affa653.png\" alt=\"Continue\" title=\"Continue\" width=\"1040\" height=\"558\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/8ee\/9c7\/57d\/8ee9c757ddd2d67bddf339e80affa653.png\"\/><figcaption>Continue<\/figcaption><\/figure>\n<p>\u0421\u043e\u0437\u0434\u0430\u0438\u0306\u0442\u0435 \u0440\u0430\u0431\u043e\u0447\u0435\u0435 \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u043e \u0432 <a href=\"https:\/\/slack.com\/get-started\" rel=\"noopener noreferrer nofollow\">Slack<\/a> \u0438\u043b\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0438\u0306\u0442\u0435 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u0435. <\/p>\n<p>\u041f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u043f\u043e \u0441\u0441\u044b\u043b\u043a\u0435 <a href=\"https:\/\/api.slack.com\/apps\" rel=\"noopener noreferrer nofollow\">https:\/\/api.slack.com\/apps<\/a> \u0438 \u0434\u043e\u0431\u0430\u0432\u0438\u043c \u043d\u0430\u0448\u0435\u0433\u043e \u0431\u043e\u0442\u0430, \u043d\u0430\u0436\u0430\u0432 \u043d\u0430 <strong>Create an App<\/strong>. \u0412\u044b\u0431\u0435\u0440\u0435\u043c <strong>From an app manifest <\/strong>\u0438 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u043c \u0440\u0430\u0431\u043e\u0447\u0435\u0435 \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u043e \u0434\u043b\u044f \u0431\u043e\u0442\u0430.<\/p>\n<p>\u0421\u043e\u0437\u0434\u0430\u0434\u0438\u043c yaml \u043c\u0430\u043d\u0438\u0444\u0435\u0441\u0442.<\/p>\n<pre><code class=\"python\">_metadata:    major_version: 1    minor_version: 1 display_information:    name: &lt;YOUR_BOT_NAME> features: app_home:   home_tab_enabled: true    messages_tab_enabled: true    messages_tab_read_only_enabled: false    ...      interactivity:     is_enabled: true     request_url: &lt;ONCALL_ENGINE_PUBLIC_URL>\/slack\/interactive_api_endpoint\/   org_deploy_enabled: false   socket_mode_enabled: false<\/code><\/pre>\n<p><code>&lt;YOUR_BOT_NAME><\/code> &#8212; \u0438\u043c\u044f \u0432\u0430\u0448\u0435\u0433\u043e \u0431\u043e\u0442\u0430, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 <code>test_bot_rb<\/code> .<br \/><code>&lt;ONCALL_ENGINE_PUBLIC_URL><\/code> &#8212; \u0440\u0430\u043d\u0435\u0435 \u0441\u043e\u0437\u0434\u0430\u043d\u043d\u044b\u0438\u0306 url \u0430\u0434\u0440\u0435\u0441 \u0434\u043b\u044f \u043a\u043e\u043d\u0442\u0435\u0438\u0306\u043d\u0435\u0440\u0430 <strong>engine<\/strong>, \u0432 \u043d\u0430\u0448\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435 <code>https:\/\/galgameth-fcm-96.loca.lt\/<\/code> .<\/p>\n<p>\u041d\u0430\u0436\u0438\u043c\u0430\u0435\u043c <strong>Next &#8212; Create<\/strong>.<strong> <\/strong>\u0412\u044b\u043f\u043e\u043b\u043d\u0438\u043c \u0432\u0435\u0440\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u044e \u0434\u043b\u044f \u043d\u0430\u0448\u0435\u0433\u043e \u0431\u043e\u0442\u0430: <em>test_bot_rb\/Features\/App manifest. <\/em>\u041d\u0430\u0436\u043c\u0435\u043c <strong>Click here to verify <\/strong>\u0438 \u0437\u0430\u0432\u0435\u0440\u0448\u0438\u043c \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0306\u043a\u0443 \u0431\u043e\u0442\u0430. <\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/dc7\/1e3\/b8e\/dc71e3b8e6ff6f22b0dde644f508e8a8.png\" alt=\"Click here to verify\" title=\"Click here to verify\" width=\"1014\" height=\"362\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/dc7\/1e3\/b8e\/dc71e3b8e6ff6f22b0dde644f508e8a8.png\"\/><figcaption>Click here to verify<\/figcaption><\/figure>\n<p>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u043c \u043d\u0430\u0448 \u0431\u043e\u0442 \u0432 \u0440\u0430\u0431\u043e\u0447\u0435\u0435 \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u043e <em>test_bot_rb\/Settings\/Basic informations <\/em><\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/037\/156\/fd1\/037156fd17fb63aabc6b8b210d46bbe7.png\" alt=\"\u041f\u0440\u0438\u043c\u0435\u043d\u0438\u0442\u044c\" title=\"\u041f\u0440\u0438\u043c\u0435\u043d\u0438\u0442\u044c\" width=\"900\" height=\"458\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/037\/156\/fd1\/037156fd17fb63aabc6b8b210d46bbe7.png\"\/><figcaption>\u041f\u0440\u0438\u043c\u0435\u043d\u0438\u0442\u044c<\/figcaption><\/figure>\n<p>\u041f\u0440\u043e\u0432\u0435\u0440\u0438\u043c \u043d\u0430\u0448\u0438 \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0306\u043a\u0438 <\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/e72\/933\/bd6\/e72933bd69fa22f75424a1c68a24ac9b.png\" alt=\"Check\" title=\"Check\" width=\"986\" height=\"640\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/e72\/933\/bd6\/e72933bd69fa22f75424a1c68a24ac9b.png\"\/><figcaption>Check<\/figcaption><\/figure>\n<h4>\u041f\u0440\u043e\u0432\u0435\u0434\u0435\u043c \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u044e Slack \u0438 Grafana\/OnCall. <\/h4>\n<p>\u0417\u0430\u0438\u0306\u0434\u0435\u043c \u043d\u0430 \u043f\u043e\u0440\u0442 <code>localhost:3000<\/code> \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u043c \u0432\u0445\u043e\u0434 \u0432 Grafana. \u041f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u0440\u0430\u0437\u0434\u0435\u043b Grafana OnCall\/ChatOps \u0438 \u0432\u043f\u0435\u0440\u0432\u0443\u044e \u043e\u0447\u0435\u0440\u0435\u0434\u044c \u043f\u0440\u043e\u0438\u0437\u0432\u0435\u0434\u0435\u043c \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0306\u043a\u0443 <strong>ENV variables<\/strong>.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/b94\/009\/4c4\/b940094c4116eebe679399b20b75832c.png\" alt=\"ENV variables\" title=\"ENV variables\" width=\"1016\" height=\"210\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/b94\/009\/4c4\/b940094c4116eebe679399b20b75832c.png\"\/><figcaption>ENV variables<\/figcaption><\/figure>\n<p>\u041d\u0430\u043c \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0432\u043d\u0435\u0441\u0442\u0438 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u0434\u0430\u043d\u043d\u044b\u0435: <\/p>\n<ul>\n<li>\n<p><code>SLACK_CLIENT_OAUTH_ID<\/code> = Basic Information -> App Credentials -> Client ID;<\/p>\n<\/li>\n<li>\n<p><code>SLACK_CLIENT_OAUTH_SECRET<\/code> = Basic Information -> App Credentials -> Client Secret;<\/p>\n<\/li>\n<li>\n<p><code>SLACK_SIGNING_SECRET<\/code> = Basic Information -> App Credentials -> Signing Secret;<\/p>\n<\/li>\n<li>\n<p><code>SLACK_INSTALL_RETURN_REDIRECT_HOST<\/code> = &lt;&lt; OnCall external URL >>.<\/p>\n<\/li>\n<\/ul>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/03b\/dde\/28b\/03bdde28bacef7d6d1f336cfb057bbb1.png\" alt=\"App Credentials\" title=\"App Credentials\" width=\"932\" height=\"568\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/03b\/dde\/28b\/03bdde28bacef7d6d1f336cfb057bbb1.png\"\/><figcaption>App Credentials<\/figcaption><\/figure>\n<p>\u0412\u0435\u0440\u043d\u0435\u043c\u0441\u044f \u0432 \u0440\u0430\u0437\u0434\u0435\u043b <strong>ChatOps <\/strong>\u0438 \u043d\u0430\u0436\u043c\u0435\u043c <strong>Install Slack integration<\/strong>, \u0434\u0430\u043b\u0435\u0435 <strong>I\u2019ll check.. <\/strong>\u0438 <strong>\u0420\u0430\u0437\u0440\u0435\u0448\u0438\u0442\u044c. <\/strong>\u0412\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u0435 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435 \u201c<strong>\u041d\u0435 \u0443\u0434\u0430\u0435\u0442\u0441\u044f \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u0441\u0430\u0438\u0306\u0442\u0443<\/strong>\u201d, \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u044f \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0430. <\/p>\n<p>\u0412\u043d\u043e\u0432\u044c \u0432\u043e\u0438\u0306\u0434\u0438\u0442\u0435 \u0432 \u0440\u0430\u0437\u0434\u0435\u043b <strong>ChatOps <\/strong>\u0438 \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0306\u0442\u0435 \u0432\u0430\u0448 Slack integration.<br \/>\u0414\u043b\u044f \u0434\u0430\u043d\u043d\u043e\u0433\u043e \u0431\u043e\u0442\u0430 \u0431\u044b\u043b \u0441\u043e\u0437\u0434\u0430\u043d \u043a\u0430\u043d\u0430\u043b \u0432 Slack \u201cgrafana oncall\u201c. \u0412\u044b\u0431\u0435\u0440\u0435\u043c \u0434\u0430\u043d\u043d\u044b\u0438\u0306 \u043a\u0430\u043d\u0430\u043b \u0434\u043b\u044f \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0438\u0306 \u043e\u0442 OnCall.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/ae0\/719\/d6d\/ae0719d6d774cc2c2b61eb1f5cee93b9.png\" alt=\"\u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u0438\u043d\u0442\u0435\u0433\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0433\u043e Slack\" title=\"\u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u0438\u043d\u0442\u0435\u0433\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0433\u043e Slack\" width=\"726\" height=\"604\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/ae0\/719\/d6d\/ae0719d6d774cc2c2b61eb1f5cee93b9.png\"\/><figcaption>\u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u0438\u043d\u0442\u0435\u0433\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0433\u043e Slack<\/figcaption><\/figure>\n<h4>\u0421\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u0440\u0430\u0441\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0438\u0306 <\/h4>\n<p>\u041f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u0440\u0430\u0437\u0434\u0435\u043b <strong>Schedules <\/strong>\u0438 \u043d\u0430\u0436\u043c\u0435\u043c <strong>Add schedule for on-call rotation<\/strong>. \u0414\u043b\u044f \u043d\u0430\u0448\u0435\u0433\u043e \u0440\u0430\u0441\u043f\u0438\u0441\u0430\u043d\u0438\u044f \u0431\u0443\u0434\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u201cgoogle calendar\u201d.<br \/>\u0423\u043a\u0430\u0436\u0435\u043c \u043d\u0430\u0437\u0432\u0430\u043d\u0438\u0435 \u043d\u0430\u0448\u0435\u0433\u043e \u0440\u0430\u0441\u043f\u0438\u0441\u0430\u043d\u0438\u044f \u0438 \u0434\u043e\u0431\u0430\u0432\u0438\u043c ical url, \u0434\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u043a\u0430\u043b\u0435\u043d\u0434\u0430\u0440\u044c, \u0432\u044b\u0431\u0435\u0440\u0435\u043c \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u0443\u044e\u0449\u0438\u0438\u0306 \u043d\u0430\u0441 \u043a\u0430\u043b\u0435\u043d\u0434\u0430\u0440\u044c \u0438 \u0437\u0430\u0438\u0306\u0434\u0435\u043c \u0432 \u0435\u0433\u043e \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0306\u043a\u0438<\/p>\n<figure class=\"bordered full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/75c\/8df\/525\/75c8df525843ba5285114a213376a123.png\" alt=\"Settings and sharing\" title=\"Settings and sharing\" width=\"572\" height=\"226\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/75c\/8df\/525\/75c8df525843ba5285114a213376a123.png\"\/><figcaption>Settings and sharing<\/figcaption><\/figure>\n<p>\u0438 \u0441\u043a\u043e\u043f\u0438\u0440\u0443\u0435\u043c \u201cSecret address ical format\u201d. <\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/f55\/450\/5fb\/f554505fb9552197b0964581f779a510.png\" alt=\"Secret address ical format\" title=\"Secret address ical format\" width=\"1416\" height=\"396\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/f55\/450\/5fb\/f554505fb9552197b0964581f779a510.png\"\/><figcaption>Secret address ical format<\/figcaption><\/figure>\n<p>\u0412\u043d\u0435\u0441\u0435\u043c \u0434\u0430\u043d\u043d\u044b\u0435 \u0438 \u0437\u0430\u0432\u0435\u0440\u0448\u0438\u043c \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u0440\u0430\u0441\u043f\u0438\u0441\u0430\u043d\u0438\u044f \u043d\u0430\u0436\u0430\u0432 <strong>Create Schedule<\/strong>.<\/p>\n<figure class=\"bordered full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/aa9\/4a0\/1c2\/aa94a01c298d13b0b9a54782d785caf2.png\" alt=\"Nginx Schedule\" title=\"Nginx Schedule\" width=\"1202\" height=\"602\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/aa9\/4a0\/1c2\/aa94a01c298d13b0b9a54782d785caf2.png\"\/><figcaption>Nginx Schedule<\/figcaption><\/figure>\n<p>\u0421\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u0440\u0430\u0441\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u043f\u0440\u0438 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u0441 9:00 \u0434\u043e 14:00 \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u044f \u0431\u0443\u0434\u0443\u0442 \u043f\u0440\u0438\u0445\u043e\u0434\u0438\u0442\u044c \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044e \u201cRoman\u201d, \u0430 \u0441 14:00 \u0438 \u0434\u043e 21:00 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044e \u201cadmin\u201d.<\/p>\n<blockquote>\n<p>\u041f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c &#171;admin&#187; \u0441\u043e\u0437\u0434\u0430\u0435\u0442\u0441\u044f \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e, \u0434\u043e\u043f. \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u0441\u043e\u0437\u0434\u0430\u0435\u0442\u0441\u044f \u0432 \u0440\u0430\u0437\u0434\u0435\u043b\u0435 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u043e\u043c \u0430\u0434\u043c\u0438\u043d\u0438\u0441\u0442\u0440\u0430\u0442\u043e\u0440\u0443: <em>Server Admin\/Users &#8212; New user<\/em><\/p>\n<\/blockquote>\n<p>\u041f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u043a\u0430\u043b\u0435\u043d\u0434\u0430\u0440\u044c \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u043c \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0306\u043a\u0443 \u0440\u0430\u0441\u043f\u0438\u0441\u0430\u043d\u0438\u044f. \u0414\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0438\u0306 \u0432\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0433\u043e \u0443\u0447\u0430\u0441\u0442\u043a\u0430 \u043c\u044b \u0443\u043a\u0430\u0437\u0430\u043b\u0438 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0432\u0443\u044e\u0449\u0435\u0435 \u0438\u043c\u044f \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f Grafana. \u0414\u043b\u044f \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f admin \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0443\u043a\u0430\u0437\u0430\u043b\u0438 [L1], \u0447\u0442\u043e \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0440\u0430\u0437\u0434\u0435\u043b\u0438\u0442\u044c \u043d\u0430\u0448\u0438\u0445 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u0438\u0306 \u043f\u043e \u0443\u0440\u043e\u0432\u043d\u044f\u043c. \u041f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u0440\u0430\u0437\u0434\u0435\u043b Grafana OnCall\/Schedules \u0438 \u043d\u0430\u0436\u043c\u0435\u043c <strong>Reload <\/strong>\u0434\u043b\u044f \u043d\u0430\u0448\u0435\u0433\u043e \u0440\u0430\u0441\u043f\u0438\u0441 <\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/293\/db7\/51d\/293db751da0c23c638a5b384dde08530.png\" alt=\"Schedule: Nginx\" title=\"Schedule: Nginx\" width=\"1246\" height=\"766\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/293\/db7\/51d\/293db751da0c23c638a5b384dde08530.png\"\/><figcaption>Schedule: Nginx<\/figcaption><\/figure>\n<p>\u041d\u0430 \u0441\u043a\u0440\u0438\u043d\u0435 \u0432\u044b\u0448\u0435 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0430 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044f \u0438\u0437 \u043a\u0430\u043b\u0435\u043d\u0434\u0430\u0440\u044f, \u0430 \u0442\u0430\u043a\u0436\u0435 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c, \u043a\u043e\u0442\u043e\u0440\u043e\u043c\u0443 \u0432 \u0434\u0430\u043d\u043d\u044b\u0438\u0306 \u043c\u043e\u043c\u0435\u043d\u0442 \u0431\u0443\u0434\u0443\u0442 \u043f\u0440\u0438\u0445\u043e\u0434\u0438\u0442\u044c \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u044f (OnCall now). <\/p>\n<p>\u041e\u0431\u043d\u043e\u0432\u0438\u043c \u0440\u0430\u043d\u0435\u0435 \u0441\u043e\u0437\u0434\u0430\u043d\u043d\u043e\u0435 \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0435 \u0432 \u0440\u0430\u0437\u0434\u0435\u043b\u0435 <em>Grafana OnCall\/Integrations <\/em>\u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0432 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0306\u043a\u0438:<\/p>\n<ul>\n<li>\n<p>\u041d\u0430\u043f\u0440\u0430\u0432\u0438\u043c \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u044f \u0432 \u043a\u0430\u043d\u0430\u043b Slack: Grafana OnCall;<\/p>\n<\/li>\n<li>\n<p>\u0414\u043e\u0431\u0430\u0432\u0438\u043c \u201cNotify user from on-call schedule\u201d \u0438 \u0432\u044b\u0431\u0435\u0440\u0435\u043c \u043d\u0430\u0448\u0435 \u0440\u0430\u0441\u043f\u0438\u0441\u0430\u043d\u0438\u0435. <\/p>\n<\/li>\n<\/ul>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/92c\/f03\/543\/92cf0354391caa8e30694aaa22267fc4.png\" alt=\"New settings\" title=\"New settings\" width=\"1838\" height=\"536\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/92c\/f03\/543\/92cf0354391caa8e30694aaa22267fc4.png\"\/><figcaption>New settings<\/figcaption><\/figure>\n<p>\u0412\u044b\u043f\u043e\u043b\u043d\u0438\u043c \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u043d\u0430\u0448\u0435\u0433\u043e \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u044f \u043d\u0430\u0436\u0430\u0432 \u201c<strong>Send demo alert<\/strong>\u201d (\u0432\u0435\u0440\u0445\u043d\u0438\u0438\u0306 \u043f\u0440\u0430\u0432\u044b\u0438\u0306 \u0443\u0433\u043e\u043b \u0441\u043a\u0440\u0438\u043d\u0430 \u0432\u044b\u0448\u0435). \u041f\u0440\u043e\u0432\u0435\u0440\u0438\u043c \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u044f \u0432 Slack.<\/p>\n<p>\u041f\u0440\u043e\u0432\u0435\u0440\u0438\u043c \u0440\u0430\u0431\u043e\u0442\u0443 \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u044f \u043e\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0432 \u043a\u043e\u043d\u0442\u0435\u0438\u0306\u043d\u0435\u0440 <strong>Nginx<\/strong><\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/d93\/fa2\/dc9\/d93fa2dc90c3621271b3ec87f2937671.png\" alt=\"\u041f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u043d\u0430\u0448\u0435 \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0435 \u043e\u0442 \u0430\u043b\u0435\u0440\u0442\u0430: Nginx RUN or NOT\" title=\"\u041f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u043d\u0430\u0448\u0435 \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0435 \u043e\u0442 \u0430\u043b\u0435\u0440\u0442\u0430: Nginx RUN or NOT\" width=\"954\" height=\"676\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/d93\/fa2\/dc9\/d93fa2dc90c3621271b3ec87f2937671.png\"\/><figcaption>\u041f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u043d\u0430\u0448\u0435 \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0435 \u043e\u0442 \u0430\u043b\u0435\u0440\u0442\u0430: Nginx RUN or NOT<\/figcaption><\/figure>\n<p>\u041f\u043e\u0437\u0434\u0440\u0430\u0432\u043b\u044f\u044e, \u0432\u044b \u0434\u043e\u0448\u043b\u0438 \u0434\u043e \u043a\u043e\u043d\u0446\u0430!<br \/>\u041d\u0430\u0434\u0435\u044e\u0441\u044c \u0434\u0430\u043d\u043d\u0430\u044f \u0441\u0442\u0430\u0442\u044c\u044f \u0445\u043e\u0442\u044c \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u043f\u043e\u043c\u043e\u0433\u043b\u0430 \u0412\u0430\u043c \u0441 \u043e\u0441\u0432\u043e\u0435\u043d\u0438\u0435\u043c \u043f\u0440\u043e\u0434\u0443\u043a\u0442\u0430 Grafana\/OnCall.<\/p>\n<\/div>\n<\/div>\n<\/div>\n<div class=\"v-portal\" style=\"display:none;\"><\/div>\n<\/div>\n<p> <!----> <!----><br \/> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/post\/700472\/\"> https:\/\/habr.com\/ru\/post\/700472\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<div><\/div>\n<div id=\"post-content-body\">\n<div>\n<div class=\"article-formatted-body article-formatted-body article-formatted-body_version-2\">\n<div xmlns=\"http:\/\/www.w3.org\/1999\/xhtml\">\n<p><strong>Grafana OnCall<\/strong> &#8212; \u044d\u0442\u043e \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u043e\u043c\u043e\u0436\u0435\u0442 \u043e\u0440\u0433\u0430\u043d\u0438\u0437\u043e\u0432\u0430\u0442\u044c \u043d\u0430\u0434\u0435\u0436\u043d\u043e\u0435 \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0435 \u043f\u0440\u0438 \u0438\u043d\u0446\u0438\u0434\u0435\u043d\u0442\u0430\u0445 \u0434\u043b\u044f \u0432\u0430\u0448\u0435\u0439 \u043a\u043e\u043c\u0430\u043d\u0434\u044b, \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u044e\u0449\u0435\u0435 \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u044e \u0441\u043e Slack \u0438 Telegram.<\/p>\n<p>\u0411\u043e\u043b\u0435\u0435 \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u043e \u043e \u0434\u0430\u043d\u043d\u043e\u043c \u043f\u0440\u043e\u0434\u0443\u043a\u0442\u0443 \u043c\u043e\u0436\u043d\u043e \u0443\u0437\u043d\u0430\u0442\u044c \u0438\u0437 <a href=\"https:\/\/habr.com\/ru\/post\/688794\/\" rel=\"noopener noreferrer nofollow\">\u0441\u0442\u0430\u0442\u044c\u0438<\/a> \u0438\u043b\u0438 \u0438\u0437 <a href=\"https:\/\/www.youtube.com\/watch?v=7uSe1pulgs8&amp;ab_channel=Grafana\" rel=\"noopener noreferrer nofollow\">\u0432\u0438\u0434\u0435\u043e<\/a>. \u0426\u0435\u043b\u044c\u044e \u0436\u0435 \u0434\u0430\u043d\u043d\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0438 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u043e\u0439 \u043b\u0430\u0431\u043e\u0440\u0430\u0442\u043e\u0440\u043a\u0438 \u0432 \u0445\u043e\u0434\u0435 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0432\u044b \u0431\u043b\u0438\u0436\u0435 \u043f\u043e\u0437\u043d\u0430\u043a\u043e\u043c\u0438\u0442\u0435\u0441\u044c \u0441 \u043f\u0440\u043e\u0434\u0443\u043a\u0442\u043e\u043c \u0438 \u043f\u0440\u043e\u0439\u0434\u0435\u0442\u0435 \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u044d\u0442\u0430\u043f\u044b \u0440\u0430\u0431\u043e\u0442 \u0441 \u043d\u0438\u043c.<\/p>\n<p>\u0426\u0435\u043b\u044c \u043b\u0430\u0431\u043e\u0440\u0430\u0442\u043e\u0440\u043a\u0438, \u043a\u0430\u043a \u0438 \u0432\u0441\u0451 \u0432 \u044d\u0442\u043e\u043c \u043c\u0438\u0440\u0435, \u043a\u0440\u0430\u0439\u043d\u0435 \u043f\u0440\u043e\u0441\u0442\u0430 &#8212; \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440 nginx \u0438 \u0435\u0441\u043b\u0438 \u043e\u043d \u043e\u0442\u043a\u043b\u044e\u0447\u0435\u043d \u043f\u0440\u0438\u0441\u043b\u0430\u0442\u044c \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0435 \u0432 Slack. <br \/>\u0426\u0435\u043f\u043e\u0447\u043a\u0430 \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0439 \u0431\u0443\u0434\u0435\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0430\u044f: \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f Prometheus \u0431\u0443\u0434\u0435\u043c \u0441\u0447\u0438\u0442\u044b\u0432\u0430\u0442\u044c \u043c\u0435\u0442\u0440\u0438\u043a\u0438 Nginx \u0438 \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044c \u0438\u0445 \u0432 Grafana. Grafana \u0431\u0443\u0434\u0435\u0442 \u043e\u0442\u0441\u043b\u0435\u0436\u0438\u0432\u0430\u0442\u044c \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043c\u0435\u0442\u0440\u0438\u043a \u0438 \u0440\u0435\u0430\u0433\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043d\u0430 \u043d\u0438\u0445 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c (\u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0435 \u0432 Slack).<\/p>\n<blockquote>\n<p>Grafana &#8212; \u044d\u0442\u043e \u0441\u0435\u0440\u0432\u0438\u0441 \u043f\u043e \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044e \u043c\u0435\u0442\u0440\u0438\u043a\u0430\u043c\u0438 \u0438 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u0430\u043b\u0435\u0440\u0442\u043e\u0432. <br \/>Grafana OnCall &#8212; \u043f\u043b\u0430\u0433\u0438\u043d \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0449\u0438\u0439 \u043d\u0430\u0441\u0442\u0440\u0430\u0438\u0432\u0430\u0442\u044c \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0435 \u043e\u0431 \u0430\u043b\u0435\u0440\u0442\u0430\u0445 \u0431\u043e\u043b\u0435\u0435 \u0434\u0435\u0442\u0430\u043b\u044c\u043d\u043e.<\/p>\n<\/blockquote>\n<p>\u0420\u0430\u0437\u043e\u0431\u044c\u0435\u043c \u043d\u0430\u0448\u0443 \u0437\u0430\u0434\u0430\u0447\u0443 \u043d\u0430 \u0448\u0430\u0433\u0438:<\/p>\n<ul>\n<li>\n<p>\u0417\u0430\u043f\u0443\u0441\u0442\u0438\u043c Grafana\/OnCall \u0432 docker compose;<\/p>\n<\/li>\n<li>\n<p>\u0414\u043e\u0431\u0430\u0432\u0438\u043c \u043f\u043b\u0430\u0433\u0438\u043d \u201cGrafana\/OnCall\u201d \u0432 \u201cGrafana\/Grafana\u201d;<\/p>\n<\/li>\n<li>\n<p>\u0414\u043e\u0431\u0430\u0432\u0438\u043c \u0432 docker compose \u043a\u043e\u043d\u0442\u0435\u0438\u0306\u043d\u0435\u0440 \u201cnginx\u201d \u0438 \u201cprometheus\u201d;<\/p>\n<\/li>\n<li>\n<p>\u041e\u0442\u0441\u043b\u0435\u0434\u0438\u043c \u043c\u0435\u0442\u0440\u0438\u043a\u0438 \u043a\u043e\u043d\u0442\u0435\u0438\u0306\u043d\u0435\u0440\u0430 \u201cnginx\u201d \u043f\u0440\u0438 \u043f\u043e\u043c\u043e\u0449\u0438 \u201cprometheus\u201d \u0438 \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044c \u0438\u0445 \u0432 \u201cGrafana\/OnCall\u201d; <\/p>\n<\/li>\n<li>\n<p>\u041d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438\u0306 \u0440\u0435\u0430\u0433\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0434\u043b\u044f \u0438\u043d\u0446\u0438\u0434\u0435\u043d\u0442\u0430 <em>\u043e\u0441\u0442\u0430\u043d\u043e\u0432 \u0441\u0435\u0440\u0432\u0438\u0441\u0430 <\/em>Nginx;<\/p>\n<\/li>\n<li>\n<p>\u0421\u043e\u0437\u0434\u0430\u0442\u044c \u0431\u043e\u0442\u0430 \u0434\u043b\u044f Slack \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u044e c Grafana\/Oncall;<\/p>\n<\/li>\n<li>\n<p>\u0421\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u0440\u0430\u0441\u043f\u0438\u0441\u0430\u043d\u0438\u044f \u0434\u043b\u044f \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0438\u0306.<\/p>\n<\/li>\n<\/ul>\n<h3>Grafana\/OnCall \u0438 docker compose<\/h3>\n<p><a href=\"https:\/\/github.com\/grafana\/oncall\" rel=\"noopener noreferrer nofollow\">GitHub<\/a>. \u0414\u043b\u044f \u0434\u0430\u043d\u043d\u043e\u0438\u0306 \u0437\u0430\u0434\u0430\u0447\u0438 \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0441\u0440\u0435\u0434\u0443: hobby.<\/p>\n<p>\u0412\u044b\u043f\u043e\u043b\u043d\u0438\u043c \u043a\u043e\u043c\u0430\u043d\u0434\u0443: <\/p>\n<p><code>curl -fsSL https:\/\/raw.githubusercontent.com\/grafana\/oncall\/dev\/docker-compose.yml -o docker-compose.yml<\/code> <\/p>\n<p>\u0412\u044b\u043f\u043e\u043b\u043d\u0438\u043c \u043a\u043e\u043c\u0430\u043d\u0434\u0443: <\/p>\n<p><code>echo \"DOMAIN=http:\/\/localhost:8080 COMPOSE_PROFILES=with_grafana SECRET_KEY=my_random_secret_must_be_more_than_32_characters_long RABBITMQ_PASSWORD=rabbitmq_secret_pw MYSQL_PASSWORD=mysql_secret_pw\" > .env<\/code> <\/p>\n<p>\u0412\u044b\u043f\u043e\u043b\u043d\u0438\u043c \u043a\u043e\u043c\u0430\u043d\u0434\u0443:<\/p>\n<p><code>docker-compose up -d<\/code><\/p>\n<p> \u041e\u0442\u043a\u0440\u043e\u0435\u043c \u043f\u043e\u0440\u0442 3000 \u0432 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0435: <code>localhost:3000<\/code><\/p>\n<p>\u041b\u043e\u0433\u0438\u043d \u0438 \u043f\u0430\u0440\u043e\u043b\u044c &#8212; <strong>admin<\/strong>. \u041f\u043e\u0441\u043b\u0435 \u0432\u0445\u043e\u0434\u0430 \u043d\u0430\u043c \u043f\u0440\u0435\u0434\u043b\u043e\u0436\u0430\u0442 \u0438\u0437\u043c\u0435\u043d\u0438\u0442\u044c \u043f\u0430\u0440\u043e\u043b\u044c, \u044d\u0442\u043e\u0442 \u0448\u0430\u0433 \u043c\u043e\u0436\u043d\u043e \u043f\u0440\u043e\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u043d\u0430\u0436\u0430\u0432 \u043a\u043d\u043e\u043f\u043a\u0443 <strong>skip.<\/strong><\/p>\n<h3>\u041f\u043b\u0430\u0433\u0438\u043d \u201cGrafana\/OnCall\u201d \u0432 \u201cGrafana\/Grafana\u201d<\/h3>\n<p>\u041d\u0430\u0445\u043e\u0434\u044f\u0441\u044c \u043d\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0435 \u201cGrafana\u201d \u0432 \u043f\u0430\u043d\u0435\u043b\u0438 \u043c\u0435\u043d\u044e \u0432 \u043b\u0435\u0432\u043e\u0438\u0306 \u0447\u0430\u0441\u0442\u0438 \u044d\u043a\u0440\u0430\u043d\u0430 \u0432\u044b\u0431\u0435\u0440\u0438\u0442\u0435 \u201cConfiguration\u201d \u0438 \u043f\u0435\u0440\u0435\u0438\u0306\u0434\u0438\u0442\u0435 \u0432 \u0440\u0430\u0437\u0434\u0435\u043b \u201cPlugins\u201d. \u0412 \u043f\u043e\u0438\u0441\u043a\u043e\u0432\u043e\u0438\u0306 \u0441\u0442\u0440\u043e\u043a\u0435 \u043d\u0430\u0431\u0435\u0440\u0438\u0442\u0435 \u201cOnCall\u201d \u0438 \u0432\u044b\u0431\u0435\u0440\u0438\u0442\u0435 \u0435\u0433\u043e. <\/p>\n<figure class=\"full-width\"><figcaption>Grafana\/Configuration\/Plugins<\/figcaption><\/figure>\n<p>\u0414\u043b\u044f \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u043f\u043b\u0430\u0433\u0438\u043d\u0430 \u043f\u043e\u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u0442\u043e\u043a\u0435\u043d. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u0443: <\/p>\n<p><code>docker-compose run engine python manage.py issue_invite_for_the_frontend --override<\/code> <\/p>\n<p>\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u043d\u044b\u0438\u0306 \u0442\u043e\u043a\u0435\u043d \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0441\u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0438 \u0432\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0432 \u0433\u0440\u0430\u0444\u0443 \u201c<strong>Invite token<\/strong>\u201d, \u043a\u0430\u043a \u043f\u043e\u043a\u0430\u0437\u0430\u043d\u043e \u043d\u0430 \u0441\u043a\u0440\u0438\u043d\u0435 \u043d\u0438\u0436\u0435.<\/p>\n<figure class=\"bordered full-width\"><figcaption>Invite token<\/figcaption><\/figure>\n<p>\u041d\u0430\u0436\u043c\u0438\u0442\u0435 \u043a\u043d\u043e\u043f\u043a\u0443 \u201c<strong>Enable<\/strong>\u201d \u0434\u043b\u044f \u043f\u043b\u0430\u0433\u0438\u043d\u0430 OnCall, \u0443\u0431\u0435\u0434\u0438\u0442\u0435\u0441\u044c, \u0447\u0442\u043e \u0432\u0432\u0435\u043b\u0438 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u043d\u044b\u0438\u0306 \u0442\u043e\u043a\u0435\u043d \u0432 \u0433\u0440\u0430\u0444\u0443 \u201c<strong>Invite token<\/strong>\u201d \u0438 \u043d\u0430\u0436\u043c\u0438\u0442\u0435 \u201c<strong>Connect<\/strong>\u201d. \u041f\u043e\u0441\u043b\u0435 \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u043f\u043b\u0430\u0433\u0438\u043d Grafana\/OnCall \u043f\u043e\u044f\u0432\u0438\u0442\u0441\u044f \u0432 \u043c\u0435\u043d\u044e \u0431\u044b\u0441\u0442\u0440\u043e\u0433\u043e \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u0432 \u043b\u0435\u0432\u043e\u0438\u0306 \u0447\u0430\u0441\u0442\u0438 \u044d\u043a\u0440\u0430\u043d\u0430.<\/p>\n<h3>Nginx \u0438 Prometheus<\/h3>\n<p>\u0414\u043e\u0431\u0430\u0432\u0438\u043c \u0432 \u0444\u0430\u0438\u0306\u043b <code>docker-compose.yml<\/code> \u043a\u043e\u0434: <\/p>\n<pre><code class=\"python\">web:   image: nginx:1.23.1   ports:     - \"8000:80\"<\/code><\/pre>\n<p>\u0414\u043e\u0431\u0430\u0432\u0438\u043c \u0432 \u0444\u0430\u0438\u0306\u043b docker-compose.yml \u043a\u043e\u0434: <\/p>\n<pre><code class=\"python\">prometheus:   image: prom\/prometheus:latest   volumes:     - .\/prometheus.yml:\/etc\/prometheus\/prometheus.yml   container_name: prometheus   hostname: prometheus   command:     - --config.file=\/etc\/prometheus\/prometheus.yml   ports:     - 9090:9090 restart: unless-stopped networks:     - default<\/code><\/pre>\n<p>\u0412 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044e \u0432 \u0444\u0430\u0438\u0306\u043b\u043e\u043c <code>docker-compose.yml<\/code> \u0434\u043e\u0431\u0430\u0432\u0438\u043c \u043d\u043e\u0432\u044b\u0438\u0306 \u0444\u0430\u0439\u043b <code>prometheus.yml<\/code> \u0438 \u0434\u043e\u0431\u0430\u0432\u0438\u043c \u0432 \u043d\u0435\u0433\u043e \u043a\u043e\u0434: <\/p>\n<pre><code class=\"python\">global:   scrape_interval: 50s #\u043a\u0430\u043a \u0447\u0430\u0441\u0442\u043e \u043e\u0431\u043d\u043e\u0432\u043b\u044f\u0442\u044c \u0442\u0430\u0440\u0433\u0435\u0442   evaluation_interval: 60s #\u043a\u0430\u043a \u0447\u0430\u0441\u0442\u043e \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u044c \u043e\u0446\u0435\u043d\u043a\u0443 \u043f\u0440\u0430\u0432\u0438\u043b   scrape_timeout: 50s #\u0447\u0435\u0440\u0435\u0437 \u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0432\u0440\u0435\u043c\u0435\u043d\u0438 \u0434\u043e \u0438\u0441\u0442\u0435\u0447\u0435\u043d\u0438\u044f \u0441\u0440\u043e\u043a\u0430 \u043e\u0436\u0438\u0434\u0430\u043d\u0438\u044f \u0437\u0430\u043f\u0440\u043e\u0441\u0438\u0442\u044c \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0435  scrape_configs:   - job_name: 'prometheus'     static_configs:       - targets: [ 'localhost:9090' ]   - job_name: 'nginx'     metrics_path: \/metrics     static_configs:       - targets: [ 'web:8000' ]   - job_name: 'grafana'     metrics_path: \/metrics     static_configs:       - targets: [ 'grafana:3000' ]<\/code><\/pre>\n<p>\u0414\u043b\u044f \u043d\u0430\u0433\u043b\u044f\u0434\u043d\u043e\u0441\u0442\u0438 \u043c\u044b \u0434\u043e\u0431\u0430\u0432\u0438\u043c \u0434\u043b\u044f Prometheus 3 \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a\u0430 \u043c\u0435\u0442\u0440\u0438\u043a: Prometheus; Nginx \u0438 Grafana. \u0412\u043d\u043e\u0432\u044c \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u043c \u043a\u043e\u043c\u0430\u043d\u0434\u0443 : <\/p>\n<p><code>docker-compose up -d<\/code><\/p>\n<h3>\u041e\u0442\u0441\u043b\u0435\u0436\u0438\u0432\u0430\u043d\u0438\u0435 \u043c\u0435\u0442\u0440\u0438\u043a \u043a\u043e\u043d\u0442\u0435\u0438\u0306\u043d\u0435\u0440\u0430 Nginx \u043f\u0440\u0438 \u043f\u043e\u043c\u043e\u0449\u0438 Prometheus<\/h3>\n<p>\u041e\u0442\u043a\u0440\u043e\u0435\u043c \u043f\u043e\u0440\u0442 \u201cprometheus\u201d 9090 \u0432 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0435 (localhost:9090). \u0412 \u0432\u0435\u0440\u0445\u043d\u0435\u043c \u043c\u0435\u043d\u044e \u043e\u0442\u043a\u0440\u044b\u0432\u0448\u0435\u0433\u043e\u0441\u044f \u043e\u043a\u043d\u0430 \u0432\u044b\u0431\u0435\u0440\u0435\u043c \u201cStatus\/Targets\u201d, \u043f\u043e\u0434\u043e\u0436\u0434\u0435\u043c \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 \u043c\u0435\u0442\u0440\u0438\u043a. \u041f\u043e \u0438\u0442\u043e\u0433\u0443 \u043c\u044b \u0434\u043e\u043b\u0436\u043d\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435.<\/p>\n<figure class=\"full-width\"><figcaption>Prometheus 9090<\/figcaption><\/figure>\n<p>\u041a\u0430\u043a \u0432\u0438\u0434\u0438\u043c \u0434\u0432\u0430 \u0441\u0435\u0440\u0432\u0438\u0441\u0430 \u0438\u0437 \u0442\u0440\u0435\u0445 \u0432 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0438 <strong>\u201cup\u201d<\/strong>. \u041f\u0440\u0438\u0447\u0438\u043d\u0430 \u0432 \u0442\u043e\u043c, \u0447\u0442\u043e \u0434\u043b\u044f \u0441\u0435\u0440\u0432\u0438\u0441\u0430 Nginx \u043d\u0435 \u0432\u043a\u043b\u044e\u0447\u0435\u043d\u0430 \u0444\u0443\u043d\u043a\u0446\u0438\u044f \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u043c\u0435\u0442\u0440\u0438\u043a.<\/p>\n<p>\u0414\u043e\u0431\u0430\u0432\u0438\u043c \u0444\u0443\u043d\u043a\u0446\u0438\u044e \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u043c\u0435\u0442\u0440\u0438\u043a \u0434\u043b\u044f \u043d\u0430\u0448\u0435\u0433\u043e \u043a\u043e\u043d\u0442\u0435\u0438\u0306\u043d\u0435\u0440\u0430 Nginx. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043d\u0430\u043c \u043f\u043e\u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u0438\u0437\u043c\u0435\u043d\u0438\u0442\u044c \u0444\u0430\u0438\u0306\u043b \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438 Nginx <code>default.conf<\/code>.<\/p>\n<p>\u0421\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u0432 \u043d\u0430\u0448\u0435\u0438\u0306 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438 \u0444\u0430\u0438\u0306\u043b <code>default.conf<\/code> \u0438 \u0434\u043e\u0431\u0430\u0432\u0438\u043c \u0432 \u043d\u0435\u0433\u043e \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0438\u0306 \u043a\u043e\u0434:<\/p>\n<pre><code class=\"python\">server {   listen 80;   listen [::]:80;   server_name localhost;    #access_log \/var\/log\/nginx\/host.access.log main; 7   location \/ {     root \/usr\/share\/nginx\/html;     index index.html index.htm;   }  location \/metrics { # \u0422\u0435 \u0441\u0430\u043c\u044b\u0435 \u0441\u0442\u0440\u043e\u043a\u0438 \u043a\u043e\u0434\u0430,   stub_status on;   # \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u043d\u0430\u043c \u043d\u0435 \u0445\u0432\u0430\u0442\u0430\u043b\u043e }  #error_page 404 \/404.html;    error_page 500 502 503 504 \/50x.html;     location = \/50x.html {     root \/usr\/share\/nginx\/html;   }<\/code><\/pre>\n<p>\u0414\u043e\u043f\u043e\u043b\u043d\u0438\u043c \u043a\u043e\u0434 \u0434\u043b\u044f \u0444\u0430\u0438\u0306\u043b\u0430 <code>docker-compose.yml<\/code>: <\/p>\n<pre><code class=\"python\">web:  image: nginx:1.23.1  volumes:   - .\/default.conf:\/etc\/nginx\/conf.d\/default.conf  ports:   - \"8000:80\"<\/code><\/pre>\n<p>\u0418 \u0442\u0430\u043a \u043c\u044b \u043a\u0432\u043b\u044e\u0447\u0438\u043b\u0438 \u043e\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u043c\u0435\u0442\u0440\u0438\u043a \u0434\u043b\u044f \u043d\u0430\u0448\u0435\u0433\u043e Nginx, \u043e\u0434\u043d\u0430\u043a\u043e \u043d\u043e\u0432\u0430\u044f \u0441\u043b\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0441\u043e\u0441\u0442\u043e\u0438\u0442 \u0432 \u0442\u043e\u043c, \u0447\u0442\u043e \u0444\u043e\u0440\u043c\u0430\u0442 \u043c\u0435\u0442\u0440\u0438\u043a Nginx \u043d\u0435 \u043f\u043e\u0434\u0445\u043e\u0434\u0438\u0442 \u0434\u043b\u044f Prometheus. \u0414\u043b\u044f \u0440\u0435\u0448\u0435\u043d\u0438\u044f \u044d\u0442\u043e\u0438\u0306 \u0437\u0430\u0434\u0430\u0447\u0438 \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043a\u043e\u043d\u0442\u0435\u0438\u0306\u043d\u0435\u0440 nginx\/nginx-prometheus-exporter . <\/p>\n<p>\u0414\u043e\u0431\u0430\u0432\u0438\u043c \u0432 \u0444\u0430\u0438\u0306\u043b docker-compose.yml \u043d\u043e\u0432\u044b\u0438\u0306 \u0431\u043b\u043e\u0433 \u043a\u043e\u0434\u0430:<\/p>\n<pre><code class=\"python\">exporter:     image: nginx\/nginx-prometheus-exporter:0.11     ports:       - 9113:9113     command:       - -nginx.scrape-uri=http:\/\/web:80\/metrics<\/code><\/pre>\n<p>\u041d\u0435 \u0437\u0430\u0431\u0443\u0434\u0435\u043c \u043e\u0431\u043d\u043e\u0432\u0438\u0442\u044c \u0444\u0430\u0438\u0306\u043b <code>prometheus.yml<\/code>: <\/p>\n<pre><code class=\"python\">global:   scrape_interval: 50s   evaluation_interval: 60s   scrape_timeout: 50s    scrape_configs:   - job_name: 'prometheus'     static_configs:       - targets: [ 'localhost:9090' ]   - job_name: 'nginx'   metrics_path: \/metrics # \u041f\u0440\u0438\u043c\u0435\u0447\u0430\u043d\u0438\u0435. \u0415\u0441\u043b\u0438 \u043d\u0435 \u0443\u043a\u0430\u0437\u0430\u0442\u044c metrics_path, \u0442\u043e \u043f\u0440\u0438\u043c\u0435\u043d\u0438\u0442\u0441\u044f \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0439 \u043f\u0443\u0442\u044c \/metrics    static_configs:     - targets: [ 'exporter:9113' ] # \u0417\u0430\u043c\u0435\u043d\u0438\u043b\u0438 \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a \u043c\u0435\u0442\u0440\u0438\u043a \u043d\u0430 exporter   - job_name: 'grafana'   metrics_path: \/metrics   static_configs:     - targets: [ 'grafana:3000' ]<\/code><\/pre>\n<p>\u0412\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u0435 \u043e\u0441\u0442\u0430\u043d\u043e\u0432 \u0432\u0441\u0435\u0445 \u043a\u043e\u043d\u0442\u0435\u0438\u0306\u043d\u0435\u0440\u043e\u0432 \u0438 \u043f\u0435\u0440\u0435\u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u0435 docker-compose \u043a\u043e\u043c\u0430\u043d\u0434\u043e\u0438\u0306:<\/p>\n<p> <code>docker-compose up -d<\/code> <\/p>\n<p>\u041f\u043e\u0432\u0442\u043e\u0440\u043d\u043e \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u043c \u0432\u0445\u043e\u0434 \u043d\u0430 \u043f\u043e\u0440\u0442 <code>localhost:9090<\/code>. \u041f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u0440\u0430\u0437\u0434\u0435\u043b \u201c<em>Status\/Targets\u201d. <\/em>\u041d\u0430 \u044d\u0442\u043e\u0442 \u0440\u0430\u0437 \u0441\u0442\u0430\u0442\u0443\u0441\u044b \u0432\u0441\u0435\u0445 \u0440\u0435\u0441\u0443\u0440\u0441\u043e\u0432 \u0434\u043e\u043b\u0436\u043d\u044b \u0431\u044b\u0442\u044c \u0432 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0438  <strong>\u201cup\u201d<\/strong>.<\/p>\n<figure class=\"full-width\"><figcaption>Status\/Targets<\/figcaption><\/figure>\n<p>\u041f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043a\u0430\u043a\u0438\u0435 \u043c\u0435\u0442\u0440\u0438\u043a\u0438 Prometheus \u0441\u0447\u0438\u0442\u044b\u0432\u0430\u0435\u0442 \u0441 \u0441\u0435\u0440\u0432\u0438\u0441\u0430 Nginx. \u041e\u0442\u043a\u0440\u043e\u0435\u043c \u043f\u043e\u0440\u0442 9113 \u0432 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0435 <code>localhost:9113\/metrics<\/code>. \u0414\u043b\u044f \u043d\u0430\u0448\u0435\u0438\u0306 \u043a\u043e\u043d\u0435\u0447\u043d\u043e\u0438\u0306 \u0437\u0430\u0434\u0430\u0447\u0438 \u043d\u0430\u043c \u043f\u043e\u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u043e\u0442\u0441\u043b\u0435\u0436\u0438\u0432\u0430\u0442\u044c \u043c\u0435\u0442\u0440\u0438\u043a\u0443 <code>nginx_up<\/code> , \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u043e\u0442\u0432\u0435\u0447\u0430\u0435\u0442 \u0437\u0430 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0441\u0435\u0440\u0432\u0438\u0441\u0430 (up\/down).<\/p>\n<figure class=\"\"><figcaption><\/figcaption><\/figure>\n<h3>\u041d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438\u0306 \u0440\u0435\u0430\u0433\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0434\u043b\u044f \u0438\u043d\u0446\u0438\u0434\u0435\u043d\u0442\u0430 \u041e\u0441\u0442\u0430\u043d\u043e\u0432 \u0441\u0435\u0440\u0432\u0438\u0441\u0430 Nginx<\/h3>\n<p>\u0414\u043e\u0431\u0430\u0432\u0438\u043c \u043f\u043b\u0430\u0433\u0438\u043d Prometheus \u0432 Grafana. \u041e\u0442\u043a\u0440\u043e\u0435\u043c \u043f\u043e\u0440\u0442 3000 \u0432 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0435 <code>localhost:3000<\/code> \u0438 \u043f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u0440\u0430\u0437\u0434\u0435\u043b \u201c<em>Configurations\/Plugins<\/em>\u201d. \u0412\u044b\u043f\u043e\u043b\u043d\u0438\u043c \u043f\u043e\u0438\u0441\u043a: Prometheus.<\/p>\n<figure class=\"full-width\"><figcaption>Prometheus<\/figcaption><\/figure>\n<p>\u041d\u0430\u0436\u043c\u0435\u043c \u043d\u0430 \u043a\u043d\u043e\u043f\u043a\u0443 \u201cCreate a Prometheus data source\u201d \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u043c \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0306\u043a\u0443. \u041d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0437\u0430\u0434\u0430\u0442\u044c \u043f\u0443\u0442\u044c \u0434\u043e \u0441\u0435\u0440\u0432\u0438\u0441\u0430 Prometheus \u0432 \u0433\u0440\u0430\u0444\u0435 URL, \u043a\u0430\u043a \u043f\u043e\u043a\u0430\u0437\u0430\u043d\u043e \u043d\u0430 \u0441\u043a\u0440\u0438\u043d\u0435 \u043d\u0438\u0436\u0435. <\/p>\n<figure class=\"full-width\"><figcaption>Create a Prometheus data source<\/figcaption><\/figure>\n<p>\u041e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u0435 \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0306\u043a\u0438 \u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u043c \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0438 \u043d\u0430\u0436\u0438\u043c\u0430\u0435\u043c \u201cSave &amp; Test\u201d. <\/p>\n<figure class=\"\"><figcaption>Done<\/figcaption><\/figure>\n<p>\u0421\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u0446\u0435\u043f\u043e\u0447\u043a\u0443 \u044d\u0441\u043a\u0430\u043b\u0430\u0446\u0438\u0438 \u0434\u043b\u044f OnCall (\u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438\u0306 \u0440\u0435\u0430\u0433\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u043d\u0430 \u0438\u043d\u0446\u0438\u0434\u0435\u043d\u0442). \u041f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u0440\u0430\u0437\u0434\u0435\u043b \u201c<em>OnCall\/Escalations Chains<\/em>\u201d.<\/p>\n<figure class=\"full-width\"><figcaption>Escalations Chains<\/figcaption><\/figure>\n<p>\u041d\u0430\u0448 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438\u0306 \u0431\u0443\u0434\u0435\u0442 \u0443\u0432\u0435\u0434\u043e\u043c\u043b\u044f\u0442\u044c \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f admin \u043e\u0431 \u0438\u043d\u0446\u0438\u0434\u0435\u043d\u0442\u0435, \u0432\u044b\u0436\u0438\u0434\u0430\u0442\u044c 1 \u043c\u0438\u043d\u0443\u0442 \u0438 \u043f\u043e\u0432\u0442\u043e\u0440\u043d\u043e \u043d\u0430\u043f\u0440\u0430\u0432\u043b\u044f\u0442\u044c \u0443\u0432\u0435\u0434\u043e\u043c\u043b\u0435\u043d\u0438\u0435. <\/p>\n<blockquote>\n<p>\u041d\u0430 \u0434\u0430\u043d\u043d\u043e\u043c \u044d\u0442\u0430\u043f\u0435 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0439 \u043d\u0435 \u0431\u0443\u0434\u0435\u0442 \u043f\u043e\u0434\u0440\u0430\u0437\u0443\u043c\u0435\u0432\u0430\u0442\u044c\u0441\u044f \u043f\u0440\u0438\u043c\u0435\u043d\u0435\u043d\u0438\u044f Slack<\/p>\n<\/blockquote>\n<figure class=\"full-width\"><figcaption>My new EChain<\/figcaption><\/figure>\n<p>\u041f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u0440\u0430\u0437\u0434\u0435\u043b \u201cIntegrations\u201d \u0438 \u0441\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u043d\u043e\u0432\u0443\u044e \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u044e \u0434\u043b\u044f \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0438\u0306, \u043d\u0430\u0436\u0430\u0432 \u043a\u043d\u043e\u043f\u043a\u0443 \u201cNew Integration receiving alerts\u201d. \u0412\u044b\u0431\u0435\u0440\u0435\u043c \u201cGrafana Alerting\u201d \u043d\u0430\u0436\u0430\u0432 \u043a\u043d\u043e\u043f\u043a\u0443 \u201cQuick Connect\u201d.<\/p>\n<figure class=\"full-width\"><figcaption>Grafana Alerting<\/figcaption><\/figure>\n<p>\u0414\u0430\u043b\u0435\u0435 \u043d\u0430\u0436\u0438\u043c\u0430\u0435\u043c \u201cOpen Escalations Settings\u201d \u0438 \u0432\u044b\u0431\u0435\u0440\u0435\u043c \u0440\u0430\u043d\u0435\u0435 \u0441\u043e\u0437\u0434\u0430\u043d\u043d\u044b\u0438\u0306 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438\u0306 \u044d\u0441\u043a\u0430\u043b\u0430\u0446\u0438\u0438.<\/p>\n<figure class=\"bordered full-width\"><figcaption>Open Escalations Settings<\/figcaption><\/figure>\n<p>\u0414\u0430\u043b\u0435\u0435 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0432\u043d\u0435\u0441\u0442\u0438 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0306\u043a\u0438 \u201cContact points\u201d. \u041f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u0440\u0430\u0437\u0434\u0435\u043b \u201cAlerting\/Contact points\u201d.<\/p>\n<figure class=\"\"><figcaption>Contact points<\/figcaption><\/figure>\n<p>\u041f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0306\u043a\u0438 \u0442\u043e\u0447\u043a\u0438 \u0434\u043e\u0441\u0442\u0443\u043f\u0430.<\/p>\n<figure class=\"bordered\"><figcaption>Grafana Alerting<\/figcaption><\/figure>\n<p>\u0412 \u0433\u0440\u0430\u0444\u0435 URL \u0438\u0437\u043c\u0435\u043d\u0438\u043c \u043f\u0443\u0442\u044c \u0441 <code>localhost:8080<\/code> \u043d\u0430 <code>engine:8080<\/code>.  \u0414\u043b\u044f \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 \u0442\u043e\u0447\u043a\u0438 \u043a\u043e\u043d\u0442\u0430\u043a\u0442\u0430 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u0435 \u201cTest\/Sent test notification\u201d (\u0432 \u043f\u0440\u0430\u0432\u043e\u0438\u0306 \u0447\u0430\u0441\u0442\u0438 \u043e\u043a\u043d\u0430). \u0412\u044b \u0434\u043e\u043b\u0436\u043d\u044b \u0443\u0432\u0438\u0434\u0435\u0442\u044c \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435 \u043e\u0431 \u0443\u0441\u043f\u0435\u0448\u043d\u043e\u043c \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0438 \u0442\u0435\u0441\u0442\u0430. <br \/>\u041d\u0430\u0436\u0438\u043c\u0430\u0435\u043c \u201cSave Contact Point\u201d \u0438 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u043c \u043a \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0435 \u201cNotification policies\u201d, \u0434\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0432\u0443\u044e\u0449\u0438\u0438\u0306 \u0440\u0430\u0437\u0434\u0435\u043b.<\/p>\n<figure class=\"full-width\"><figcaption>Notification policies<\/figcaption><\/figure>\n<p>\u041f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u0442 \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0306\u043a\u0438 \u201cRoot policy &#8212; <em>default for all alerts<\/em>\u201d \u0438 \u043f\u043e\u043c\u0435\u043d\u044f\u0435\u043c \u201cDefault contact point\u201d \u043d\u0430 \u0441\u043e\u0437\u0434\u0430\u043d\u043d\u044b\u0438\u0306 \u043d\u0430\u043c\u0438 \u0440\u0430\u043d\u0435\u0435. \u0421\u043e\u0445\u0440\u0430\u043d\u0438\u043c \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f. <\/p>\n<p>\u041f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u0440\u0430\u0437\u0434\u0435\u043b \u201cAlert Rules\u201d \u0434\u043b\u044f \u0437\u0430\u0432\u0435\u0440\u0448\u0435\u043d\u0438\u044f \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043a. <br \/>\u041d\u0430\u0436\u043c\u0435\u043c \u043a\u043d\u043e\u043f\u043a\u0443 \u201cNew Alert Rules\u201d. \u0414\u043b\u044f \u043e\u0442\u0441\u043b\u0435\u0436\u0438\u0432\u0430\u043d\u0438\u0435 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u0441\u0435\u0440\u0432\u0438\u0441\u043e\u0432 \u0432\u044b\u0431\u0435\u0440\u0435\u043c \u043f\u043b\u0430\u0433\u0438\u043d Prometheus, Metric = <code>nginx_up<\/code>.<\/p>\n<figure class=\"full-width\"><figcaption><\/figcaption><\/figure>\n<p>\u041c\u0435\u0442\u0440\u0438\u043a\u0430 <code>nginx_up<\/code> \u043f\u0435\u0440\u0435\u0434\u0430\u0435\u0442 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 <strong>1 <\/strong>\u043f\u0440\u0438 \u0440\u0430\u0431\u043e\u0442\u0435 \u0441\u0435\u0440\u0432\u0438\u0441\u0430 \u0438 <strong>0 <\/strong>\u043f\u0440\u0438 \u0435\u0433\u043e \u043e\u0442\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0438. \u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u043d\u0430\u043c \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043f\u043e\u043b\u0443\u0447\u0430\u0442\u044c \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0435, \u043a\u043e\u0433\u0434\u0430 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043c\u0435\u0442\u0440\u0438\u043a\u0438 \u043d\u0435 \u0440\u0430\u0432\u043d\u043e <strong>1<\/strong>. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u043c \u043c\u043e\u0434\u0443\u043b\u044c \u201cB &#8212; expression\u201d \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c. <\/p>\n<figure class=\"full-width\"><figcaption>B &#8212; expression<\/figcaption><\/figure>\n<p>\u0412 \u0433\u0440\u0430\u0444\u0435 \u201cSet alert condition\u201d \u0432\u044b\u0431\u0435\u0440\u0435\u043c \u201cB &#8212; expression\u201d. \u0412\u044b\u043f\u043e\u043b\u043d\u0438\u043c \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0443 \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u043e\u0433\u043e Alert \u043d\u0430\u0436\u0430\u0432 \u043a\u043d\u043e\u043f\u043a\u0443 \u201cPreview alert\u201d \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u0432\u044b \u043d\u0435 \u0434\u043e\u043b\u0436\u043d\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u043e\u0448\u0438\u0431\u043a\u0443 \u0432 \u043f\u043e\u044f\u0432\u0438\u0432\u0448\u0435\u043c\u0441\u044f \u043e\u043a\u043d\u0435.<br \/>\u0417\u0430\u043f\u043e\u043b\u043d\u0438\u043c \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e \u0434\u043b\u044f \u0434\u0430\u043d\u043d\u043e\u0433\u043e \u043f\u0440\u0430\u0432\u0438\u043b\u0430 \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u044f.<\/p>\n<figure class=\"full-width\"><figcaption>Add details for your alert<\/figcaption><\/figure>\n<p>\u041d\u0430\u0436\u043c\u0435\u043c \u043a\u043d\u043e\u043f\u043a\u0443 \u201cSave and exit\u201d. <\/p>\n<p>\u041f\u0435\u0440\u0435\u0434 \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u043e\u0438\u0306 \u0441\u043e\u0437\u0434\u0430\u043d\u043d\u043e\u0433\u043e \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u044f \u043f\u0435\u0440\u0435\u0438\u0306\u0434\u0435\u043c \u0432 \u0440\u0430\u0437\u0434\u0435\u043b \u201cOnCall\/Alert Group\u201d. \u0412 \u0442\u0430\u0431\u043b\u0438\u0446\u0435 \u0431\u0443\u0434\u0435\u0442 \u0440\u0430\u043d\u0435\u0435 \u0441\u043e\u0437\u0434\u0430\u043d\u043d\u043e\u0435 \u043d\u0430\u043c\u0438 \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0435, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u043c\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u0438 \u043f\u0440\u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0438 \u0442\u0435\u0441\u0442\u0430 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438 \u201cContact point\u201d.<\/p>\n<figure class=\"full-width\"><figcaption>TestAlert<\/figcaption><\/figure>\n<h4>\u041f\u0440\u043e\u0432\u0435\u0440\u0438\u043c \u0440\u0430\u0431\u043e\u0442\u0443 \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u043e\u0433\u043e \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u044f<\/h4>\n<p>\u041f\u0440\u043e\u0438\u0437\u0432\u0435\u0434\u0435\u043c \u043e\u0441\u0442\u0430\u043d\u043e\u0432 \u043a\u043e\u043d\u0442\u0435\u0438\u0306\u043d\u0435\u0440\u0430 Nginx \u0438 \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u043c \u0440\u0430\u0431\u043e\u0442\u0443 \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u043e\u0433\u043e \u043d\u0430\u043c\u0438 Grafana\/OnCall. \u041e\u0442\u043a\u0440\u043e\u0435\u043c \u0432 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0435 \u043f\u043e\u0440\u0442 9113 <code>http:\/\/localhost:9113\/metrics<\/code> \u0438 \u0443\u0432\u0438\u0434\u0438\u043c \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0435 \u043e\u0442\u0441\u043b\u0435\u0436\u0438\u0432\u0430\u0435\u043c\u043e\u0438\u0306 \u043d\u0430\u043c\u0438 \u043c\u0435\u0442\u0440\u0438\u043a\u0438 <code>nginx_up<\/code>, \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440 \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u0440\u0430\u0432\u0435\u043d <strong>0<\/strong>.<br \/>\u041f\u0440\u043e\u0432\u0435\u0440\u0438\u043c \u043d\u0430\u043b\u0438\u0447\u0438\u044f \u043e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u044f \u0432 \u201cOnCall\/Alert Group\u201d. <\/p>\n<figure class=\"full-width\"><figcaption>Nginx_onoff<\/figcaption><\/figure>\n<blockquote>\n<p>\u041e\u043f\u043e\u0432\u0435\u0449\u0435\u043d\u0438\u0435 \u043d\u0435 \u043f\u0440\u0438\u0434\u0435\u0442 \u043c\u0433\u043d\u043e\u0432\u0435\u043d\u043d\u043e: Prometheus \u043e\u0431\u043d\u043e\u0432\u043b\u044f\u0435\u0442 \u043c\u0435\u0442\u0440\u0438\u043a\u0438 \u0440\u0430\u0437 \u0432 60s, \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u044b\u0438\u0306 \u043d\u0430\u043c\u0438 Alert rules \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442 \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0443 \u0440\u0430\u0437 \u0432 \u043c\u0438\u043d\u0443\u0442, \u043f\u043e\u0441\u043b\u0435 \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 \u0438 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f <strong>0 <\/strong>\u043e\u0442 \u043c\u0435\u0442\u0440\u0438\u043a\u0438 <code>nginx_up<\/code> \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044f Alert \u0438\u0437\u043c\u0435\u043d\u0438\u0442\u044c\u0441\u044f \u0441 \u201c<strong>Norm<\/strong>\u201d \u043d\u0430 \u201c<strong>Pending<\/strong>\u201d, \u043e\u0436\u0438\u0434\u0430\u044f \u0432 \u0442\u0435\u0447\u0435\u043d\u0438\u0438 5 \u043c\u0438\u043d\u0443\u0442 \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044f \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044f (<strong>=1<\/strong>) \u0438 \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u043e\u0441\u043b\u0435<\/p>\n<\/blockquote>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-341491","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/341491","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=341491"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/341491\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=341491"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=341491"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=341491"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}