Skip to content
Snippets Groups Projects
Commit 5450189c authored by jurgenhaas's avatar jurgenhaas
Browse files

ansible-inventories/arocom#2969 Add support for custom recipients

parent 4083d5e5
No related branches found
No related tags found
No related merge requests found
...@@ -724,3 +724,23 @@ role_recipients_kavenegar[sitemgr]="${DEFAULT_RECIPIENT_KAVENEGAR}" ...@@ -724,3 +724,23 @@ role_recipients_kavenegar[sitemgr]="${DEFAULT_RECIPIENT_KAVENEGAR}"
role_recipients_pd[sitemgr]="${DEFAULT_RECIPIENT_PD}" role_recipients_pd[sitemgr]="${DEFAULT_RECIPIENT_PD}"
role_recipients_custom[sitemgr]="${DEFAULT_RECIPIENT_CUSTOM}" role_recipients_custom[sitemgr]="${DEFAULT_RECIPIENT_CUSTOM}"
# -----------------------------------------------------------------------------
# custom recipients
{% for role in netdata_role_recipients %}
role_recipients_email[{{ role }}]="{{ netdata_role_recipients[role]['email']|default('disabled') }}"
role_recipients_pushover[{{ role }}]="{{ netdata_role_recipients[role]['pushover']|default('disabled') }}"
role_recipients_pushbullet[{{ role }}]="{{ netdata_role_recipients[role]['pushbullet']|default('disabled') }}"
role_recipients_telegram[{{ role }}]="{{ netdata_role_recipients[role]['telegram']|default('disabled') }}"
role_recipients_slack[{{ role }}]="{{ netdata_role_recipients[role]['slack']|default('disabled') }}"
role_recipients_alerta[{{ role }}]="{{ netdata_role_recipients[role]['alerta']|default('disabled') }}"
role_recipients_flock[{{ role }}]="{{ netdata_role_recipients[role]['flock']|default('disabled') }}"
role_recipients_discord[{{ role }}]="{{ netdata_role_recipients[role]['discord']|default('disabled') }}"
role_recipients_hipchat[{{ role }}]="{{ netdata_role_recipients[role]['hipchat']|default('disabled') }}"
role_recipients_twilio[{{ role }}]="{{ netdata_role_recipients[role]['twilio']|default('disabled') }}"
role_recipients_messagebird[{{ role }}]="{{ netdata_role_recipients[role]['messagebird']|default('disabled') }}"
role_recipients_kavenegar[{{ role }}]="{{ netdata_role_recipients[role]['kavenegar']|default('disabled') }}"
role_recipients_pd[{{ role }}]="{{ netdata_role_recipients[role]['pd']|default('disabled') }}"
role_recipients_custom[{{ role }}]="{{ netdata_role_recipients[role]['custom']|default('disabled') }}"
{% endfor %}
# netdata python.d.plugin configuration for httpcheck
#
# This file is in YaML format. Generally the format is:
#
# name: value
#
# There are 2 sections:
# - global variables
# - one or more JOBS
#
# JOBS allow you to collect values from multiple sources.
# Each source will have its own set of charts.
#
# JOB parameters have to be indented (using spaces only, example below).
# ----------------------------------------------------------------------
# Global Variables
# These variables set the defaults for all JOBs, however each JOB
# may define its own, overriding the defaults.
# update_every sets the default data collection frequency.
# If unset, the httpcheck default is used, which is at 3 seconds.
# update_every: 1
# priority controls the order of charts at the netdata dashboard.
# Lower numbers move the charts towards the top of the page.
# If unset, the default for python.d.plugin is used.
# priority: 60000
# chart_cleanup sets the default chart cleanup interval in iterations.
# A chart is marked as obsolete if it has not been updated
# 'chart_cleanup' iterations in a row.
# They will be hidden immediately (not offered to dashboard viewer,
# streamed upstream and archived to backends) and deleted one hour
# later (configurable from netdata.conf).
# -- For this plugin, cleanup MUST be disabled, otherwise we lose response
# time charts
chart_cleanup: 0 chart_cleanup: 0
redirect: no redirect: no
# Autodetection and retries do not work for this plugin
# ----------------------------------------------------------------------
# JOBS (data collection sources)
#
# The default JOBS share the same *name*. JOBS with the same name
# are mutually exclusive. Only one of them will be allowed running at
# any time. This allows autodetection to try several alternatives and
# pick the one that works.
#
# Any number of jobs is supported.
#
# -------------------------------
# ATTENTION: Any valid configuration will be accepted, even if initial connection fails!
# -------------------------------
#
# There is intentionally no default config, e.g. for 'localhost'
# job_name:
# name: myname # [optional] the JOB's name as it will appear at the
# # dashboard (by default is the job_name)
# # JOBs sharing a name are mutually exclusive
# update_every: 3 # [optional] the JOB's data collection frequency
# priority: 60000 # [optional] the JOB's order on the dashboard
# retries: 60 # [optional] the JOB's number of restoration attempts
# timeout: 1 # [optional] the timeout when connecting, supports decimals (e.g. 0.5s)
# url: http[s]://host-ip-or-dns[:port][path]
# # [required] the remote host url to connect to. If [:port] is missing, it defaults to 80
# # for HTTP and 443 for HTTPS. [path] is optional too, defaults to /
# redirect: yes # [optional] If the remote host returns 3xx status codes, the redirection url will be
# # followed (default).
# status_accepted: # [optional] By default, 200 is accepted. Anything else will result in 'bad status' in the
# # status chart, however: The response time will still be > 0, since the
# # host responded with something.
# # If redirect is enabled, the accepted status will be checked against the redirected page.
# - 200 # Multiple status codes are possible. If you specify 'status_accepted', you would still
# # need to add '200'. E.g. 'status_accepted: [301]' will trigger an error in 'bad status'
# # if code is 200. Do specify numerical entries such as 200, not 'OK'.
# regex: None # [optional] If the status code is accepted, the content of the response will be searched for this
# # regex (if defined). Be aware that you may need to escape the regex string. If redirect is enabled,
# # the regex will be matched to the redirected page, not the initial 3xx response.
# Simple example:
#
# jira:
# url: https://jira.localdomain/
# Complex example:
#
# cool_website:
# url: http://cool.website:8080/home
# status_accepted:
# - 200
# - 204
# regex: <title>My cool website!<\/title>
# timeout: 2
# This plugin is intended for simple cases. Currently, the accuracy of the response time is low and should be used as reference only.
{% for item in netdata_httpcheck|default([]) %} {% for item in netdata_httpcheck|default([]) %}
{% if not item.disabled|default(false) and item.username is not defined %} {% if not item.disabled|default(false) and item.username is not defined %}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment