Ping Hosts and URLs and keep stats on successes and failures
Project description
Ping Hosts and URLs and keep stats on successes and failures
Run this as a daemon on your box and check in to see if there are problems.
Intended to be a slightly different approach to blackbox_exporter.
Installing
pip install pingertron
Running
pingertron probes.yaml
ICMP usually needs root access to send packets:
sudo pingertron probes.yaml
There is an example probes.yaml you can use as a basis for your own.
probes.yaml
Specify one or more probes to run using probes.yaml.
This file is re-read on each evaluation cycle, so you can update it without restarting the process.
Example probes.yaml:
interval_seconds: 60 # seconds between each batch of probes being sent
probes:
- protocol: http # one of icmp or http
description: my probe # optional description
# probe specific properties
# HTTP Probe
- protocol: http
# description: my HTTP probe # optional description
url: https://example.com/ # URL to probe, http or https
method: GET # HTTP method to use
expected_status_code: 200 # HTTP status code you expect, usually 200
# ICMP Probe
- protocol: icmp
# description: my ICMP probe # optional description
hostname: 10.0.0.1 # Hostname or IP to ping.
The canonical definition of what goes into this file can be found in probes_config.py.
Developing
devenv
If you use devenv:
direnv allow .
poetry
If you use poetry:
poetry install
poetry run pingertron
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pingertron-0.1.0.tar.gz
(4.5 kB
view hashes)
Built Distribution
Close
Hashes for pingertron-0.1.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5cee55dc10a0ed5ac4551822c3f0e6b202edbcdebc2dfd7cb02384dcc4189d9f |
|
MD5 | 432aee6c6f4a4a5b8bcabf6659a2cc74 |
|
BLAKE2b-256 | ef5b0b64742f8998298b0b7ab1353eb4814d68c03c5e415a749ac31c5fb5dc8c |