DEV Community

Beyza
Beyza

Posted on

Create ELK Kibana Watcher and Send Email Reports as PNG

A tutorial on the process of sending a Kibana dashboard to email addresses as a (PNG) image is not readily available. After extensive experimentation and research, I have produced a comprehensive guide on this topic. The tutorial outlines the step-by-step instructions for this task, and will provide a much-needed resource for those interested in achieving this objective.

Steps:

  1. Go to Your account/Contacts
  2. Add your email here Image description
  3. Confirm the email coming from Elastic.
  4. Go to Stack Manager > Watcher
  5. Create a new Watcher
  6. Edit yout watch
  7. Example:
{
  "trigger": {
    "schedule": {
      "interval": "24h"
    }
  },
  "input": {
    "none": {}
  },
  "condition": {
    "always": {}
  },
  "actions": {
    "email_admin": {
      "email": {
        "profile": "standard",
        "attachments": {
          "error_report.png": {
            "reporting": {
              "url": "reporting-url (1)",
              "interval": "260s",
              "auth": {
                "basic": {
                  "username": "user (2)",
                  "password": "passw (3)"
                }
              }
            }
          }
        },
        "to": [
          "'me <me@mail.com>, you <you@mail.com>'"
        ],
        "subject": "Monitoring Report"
      }
    }
  }
}
Enter fullscreen mode Exit fullscreen mode

There are some fields that you need to fill:

STEP (1)
Go one of your dashboards
Click Share > PNG Reports > Advanced Options > Copy Post Url

Image description

STEP (2) and (3)
Create user with privileges,
go to: management/security/users

Create a user

Image description

(UTC timezone)

Save your watcher and exit to main page. That way you will get PNG reports to your email everyday.

Main Source:
https://www.elastic.co/guide/en/elasticsearch/reference/current/trigger-schedule.html

Top comments (0)