forked from moira-alert/doc
-
Notifications
You must be signed in to change notification settings - Fork 0
/
api.example.yml
96 lines (96 loc) · 4.06 KB
/
api.example.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
# Use fields MasterName and SentinelAddrs to enable Redis Sentinel support,
# use Host and Port fields otherwise.
redis:
# Sentinel cluster name
master_name: ""
# Sentinel address list, format: {host1_name:port};{ip:port}
sentinel_addrs: ""
# Node ip-address or host name
host: "moira-redis"
# Node port
port: "6379"
# Database id
dbid: 0
# Redis client connection pool size
connection_limit: 512
graphite:
# If true, graphite sender will be enabled.
enabled: true
# If true, runtime stats will be captured and sent to graphite. Note: It takes to call stoptheworld() with configured "graphite.interval" to capture runtime stats (https://golang.org/src/runtime/mstats.go)
runtime_stats: false
# Graphite relay URI, format: ip:port
uri: "graphite-relay:2003"
# Moira metrics prefix. Use 'prefix: {hostname}' to use hostname autoresolver.
prefix: DevOps.moira
# Metrics sending interval
interval: 60s
api:
# Api local network address. Default is ':8081' so api will be available at http://moira.company.com:8081/api
listen: ":8081"
# If true, CORS for cross-domain requests will be enabled. This option can be used only for debugging purposes.
enable_cors: false
# Web_UI config file path. If file not found, api will return 404 in response to "api/config"
web_config_path: "/etc/moira/web.json"
web:
# Moira administrator email address
supportEmail: "[email protected]"
# List of enabled contact types
contacts:
- type: mail
label: E-mail
validation: "^.+@.+\\..+$"
- type: pushover
label: Pushover
placeholder: "Pushover user key"
- type: slack
label: Slack
validation: "^[@#][a-zA-Z0-9-_]+"
placeholder: "Slack #channel or @user"
- type: telegram
label: Telegram
placeholder: "#channel, @username or group"
help: "### To make things work you should:\n### In personal chat:\n - start conversation with bot [@YourMoiraBot](https://t.me/YourMoiraBot);\n - execute command `/start`;\n - type your login in above field as `@login`.\n\n### In group chat:\n - invite bot [@YourMoiraBot](https://t.me/YourMoiraBot) into chat;\n - execute command `/start@YourMoiraBot`;\n - bot will send you chat name, you should type it without extra characters in above field.\n\n### In channel:\n - add bot [@YourMoiraBot](https://t.me/YourMoiraBot) into channel;\n - promote bot as channel administrator;\n - type channel name in above field as `#channel`.\n"
- type: twilio sms
label: Twilio SMS
validation: "^\\+79\\d{9}$"
placeholder: "Phone number format +79*********"
- type: twilio voice
label: Twilio voice
validation: "^\\+79\\d{9}$"
placeholder: "Phone number format +79*********"
- type: webhook
label: My Webhook
validation: "^(http|https):\\/\\/.*(example.com|example.org)(:[0-9]{2,5})?\\/"
placeholder: "https://example.com/webhooks/moira"
help: "### Domains whitelist:\n - example.com\n - example.org"
- type: pagerduty
label: PagerDuty
placeholder: "Integration key"
- type: opsgenie
label: OpsGenie
placeholder: "Responder Name or ID"
- type: victorops
label: VictorOps
placeholder: "Routing key"
- type: discord
label: Discord
placeholder: "Discord channel (eg: general-text) or user (eg: @user)"
log:
log_file: stdout
log_level: info
# This section configures remote triggers Checker.
# See https://moira.readthedocs.io/en/latest/installation/configuration.html#remote-triggers-checker for futher information
remote:
enabled: false
# URL of Graphite HTTP API: graphite-web, carbonapi, etc.
# Specify full URL including '/render'
url: "http://graphite.example.com/render"
# Auth username. Only Basic-auth supported
user: devops
# Auth password. Only Basic-auth supported
password: verySecurePassword
# Min period to perform triggers re-check.
# Note: Reducing of this value leads to increasing of CPU and memory usage values and extra load on Graphite HTTP API
check_interval: 60s
# Maximum timeout for HTTP-request made to Graphite HTTP API
timeout: 60s