-
Notifications
You must be signed in to change notification settings - Fork 90
Configuration
All settings are in config/parameters.yml
.
db:
host: localhost
port: 3306
name: pinba
user: user
pass: password
In section db
you must define database connection settings. Pinboard connects to the same database as Pinba.
Pinboard can keep a log of slow and heavy (for memory and CPU) requests which displays in sections "Request time", "Memory peak usage" and "CPU peak usage" for each monitoring site.
logging:
# in seconds
long_request_time:
global: 1.0
"supersite1.com": 0.8
"superfastsite2.com": 0.3
# max memory usage in kB
heavy_request:
global: 30000
"coolsite.ru": 5000
"heavysite.ru": 30000
heavy_cpu_request:
global: 1
"elseonesite.com": 5
Parameters global
are used as default for all monitoring sites. For example above all requests with execution time more than 1 second, which used memory more than 30000 kB and which used CPU more than 1 will saved in log.
For any site you can define personal settings by adding corresponding parameters in sections long_request_time
, heavy_request
and heavy_cpu_request
.
If no settings in section logging
Pinboard uses following parameters:
long_request_time: 1.0
heavy_request: 30000
heavy_cpu_request: 1
pagination:
row_per_page: 50
In section pagination
you can define number of records per page in sections "Request time", "Memory peak usage" and "Error statuses".
If no settings in section pagination
Pinboard uses following parameter:
row_per_page: 50
records_lifetime: P1M
You can define how long Pinboard will save hosts statistic. Default period is a one month. Period defines in ISO8601 format (see ISO8601 on Wikipedia).
Old data cleaning occurs when you run a command ./console aggregate
on crontab.
In section "Security" you can define settings for user authentication and authorization.
secure:
enable: true
users:
username1:
password: my_sha512_password
username2:
password: my_sha512_password
hosts: 'mysite\.com$'
Parameter enable
switch on/off the authentication and the authorization on site.
In section users
define who has the access to the site.
In password
need to define user password, the encrypted algorithm is sha512 with 5000 iterations and encode to base64 the password hash.
In hosts
define a regular expression which controls the access to hosts information. By default, the user has the access to all hosts.
Use special console command for user adding. Details in Security.
Pinboard can send e-mail messages for:
-
pages with HTTP status code 5xx
-
detection of a drawdown of indicators
notification: enable: true ignore: - (foo|otp).example.com$ - second-example.ru$ sender: [email protected] global_email: [email protected] border: req_time: global: 1.5 somesite.com: 2 list: - hosts: example.com$ email: - [email protected] - [email protected] - hosts: forum.example.com$ email: [email protected]
If section notification
is not specified, notification will not be sent.
Parameter enable
switch on and off notification sending.
In section ignore
you can specify a list of sites which are ignored when sending a notifications. If a site matches any specified regular expression, notification will not be sent.
Parameter sender
- this email address will be used as the sender of notifications.
Parameter global_email
defines email for all messages. If the parameter is not specified, will use only emails listed below.
In section list
you can list the correspondence between the sites and email. If the error occurs at a site that equal to regexp expression hosts
, notification will be sent to email
. You can define multiple emails for one site.
Parameter border
defines settings for detecting of the drawdown of indicators. Now Intaro Pinboard monitors 2 indicators: max time of the 90% and 95% fastest requests. Settings for this indicators defines in section req_time
. Subsection global
defines the general border value for all sites. For any site you can define personal settings by adding corresponding parameter. If one of indicator exceeds border value Intaro Pinboard will send notification message. If indicator back to stable state Intaro Pinboard will send second notification message.
By default all email sended throw mail()
function. You can define sending throw SMTP server.
smtp:
server: localhost
port: 25
username: [email protected]
password: my_password
encryption: null
auth_mode: null
In section smtp
you can define parameters of your smtp server - server adress, port, username, password, encryption type (null, ssl, tls), authentication mode.