Smokeping docker container
SmokePing keeps track of your network latency:
- Best of breed latency visualisation.
- Interactive graph explorer.
- Wide range of latency measurment plugins.
- Master/Slave System for distributed measurement.
- Highly configurable alerting system.
- Live Latency Charts with the most 'interesting' graphs.
When started the smokeping web inteface will listen on port 80 in the container at the '/smokeping/smokeping.cgi' URI.
sudo docker run --name smokeping -p 8000:80 -d dperson/smokeping
sudo docker run -it --rm dperson/smokeping -h
Usage: smokeping.sh [-opt] [command]
Options (fields in '[]' are optional, '<>' are required):
-h This help
-g "<user;pass>" Configure ssmtp so that email alerts can be sent
required arg: "<user>" - your gmail username
required arg: "<pass>" - your gmail password of app password
These are only set in your docker container
-e "<email>" Configure email address for owner of smokeping
required arg: "<email>" - your email address
-o "<name>" Configure name of the owner of smokeping
required arg: "<name>" - your name
-t "<site;name;target>[;alert]" Configure smokeping targets
required arg: "<site>" - name for site of tests
required arg: "<name>" - name for check
required arg: "<target>" - hostname or IP to check
possible arg: "[alert]" - send emails on failures (any val)
-T "" Configure timezone
possible arg: "[timezone]" - zoneinfo timezone for container
-w Wipe the targets clean
The 'command' (if provided and valid) will be run instead of smokeping
ENVIROMENT VARIABLES (only available with docker run)
WIPE- If set will wipe all targetsSSMTP_GMAILAs above configure the ssmtp daemon for gmail, set touser;passEMAIL- As above, your email address as the ownerbob@example.netOWNER- As above, your name as the ownerBob HopeTARGET- As above a target to check, set tosite;name;target[;alert]TIMEZONE- As above, set a zoneinfo timezone, IEEST5EDT
Any of the commands can be run at creation with docker run or later with
docker exec smokeping.sh (as of version 1.3 of docker).
sudo docker run -p 8000:80 -d dperson/smokeping -T EST5EDT
Will get you the same settings as
sudo docker run --name smokeping -p 8000:80 -d dperson/smokeping
sudo docker exec smokeping smokeping.sh -T EST5EDT ls -AlF /etc/localtime
sudo docker restart smokeping
IP=$(traceroute -n google.com |
egrep -v ' (10|172\.(1[6-9]|2[0-9]|3[01])|192.168)\.' |
awk '/[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+.*ms/ {print $2; exit}')
sudo docker run -p 8000:80 -d dperson/smokeping -w -t "ISP;NextHop;$IP"
OR
IP=$(traceroute -n google.com |
egrep -v ' (10|172\.(1[6-9]|2[0-9]|3[01])|192.168)\.' |
awk '/[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+.*ms/ {print $2; exit}')
sudo docker run -p 8000:80 -e WIPE=y -e TARGET="ISP;NextHop;$IP" \
-d dperson/smokeping
sudo docker exec <name_of_instance> smokeping.sh -t "<site;name;target>"
IE
sudo docker exec stunned_newton smokeping.sh -t "home;router;bob.dyndns.org"
sudo docker run -p 8000:80 -d dperson/smokeping -g "sampleuser;samplepass"
OR
sudo docker run -p 8000:80 -e SSMTP_GMAIL="sampleuser;samplepass" \
-d dperson/smokeping
sudo docker run -p 8000:80 -d dperson/smokeping -e "sampleuser@gmail.com"
OR
sudo docker run -p 8000:80 -e EMAIL="sampleuser@gmail.com" \
-d dperson/smokeping
sudo docker run -p 8000:80 -d dperson/smokeping -o "Sample User"
OR
sudo docker run -p 8000:80 -e OWNER="Sample User" -d dperson/smokeping
sudo docker run -p 8000:80 -d dperson/smokeping -T EST5EDT
OR
sudo docker run -p 8000:80 -e TIMEZONE=EST5EDT -d dperson/smokeping
If you wish to adapt the default configuration, use something like the following to copy it from a running container:
sudo docker cp smokeping:/etc/smokeping /some/path
You can use the modified configuration with:
sudo docker run --name smokeping -p 8000:80 -v /some/path:/etc/smokeping:ro\
-d dperson/smokeping
If you have any problems with or questions about this image, please contact me through a GitHub issue.
