Run ISP speed tests and save results

Related tags

TestingSpeedmon
Overview

SpeedMon

GitHub commit activity Master Travis (.com) semver CodeFactor Grade

Screenshot

Automatically run periodic internet speed tests and save results to a variety of storage backends.

Supported Backends

  • InfluxDB v1
  • InfluxDB v2
  • Graphite

Speed tests are run using the official speedtest.net CLI tool.

Docker, Windows, and Linux are supported. Linux users are required to install the speedtest package first. It will automatically download on Windows.

Configuration

Speedmon can be configured from a configuration file or environment variables. The preferred method is via ENV.

Configuring From ENV

You only need to include the variables for the storage backends you wish to use.

General

DELAY
SERVERS (1234,5431,ect)

Influx v1

--Required--
INFLUXV1_URL
INFLUXV1_DATABASE_NAME
--Optional--
INFLUXV1_NAME
INFLUXV1_PORT
INFLUXV1_USER
INFLUXV1_PASSWORD
INFLUXV1_VERIFY_SSL
INFLUXV1_SSL

Influx v2

--Required--
INFLUXV2_URL
INFLUXV2_TOKEN
INFLUXV2_ORG
INFLUXV2_BUCKET
--Optional--
INFLUXV2_NAME
INFLUXV2_VERIFY_SSL

Graphite v2

--Required--
GRAPHITE_URL
GRAPHITE_PREFIX
--Optional--
GRAPHITE_NAME
GRAPHITE_PORT

Configuring From .ini

When initializing Speedmon looks for the SPEEDTEST_CONFIG ENV Variable to know what config file to load. If this variable is not provided, Speedmon will attempt to load settings from ENV.

Storage backends are dynamically loaded based on what is in the config file. You can safely delete the sections for backends not in use.

[GENERAL]
Delay = 360
Servers = 
[INFLUXV1]
Name = Whatever You want
Url = http://localhost
Port = 8086
Database_name = speedtests
User = 
Password =
SSL = False
Verify SSL = False
[INFLUXV2]
Name = Whatever You want
Url = http://localhost
Token =
Org = 
Bucket = 
Verify SSL = False
[Graphite]
Name = Whatever You want
Url = http://localhost
Port = 2003
Prefix = speedtest

Usage

With Docker

See ENV Variable List For Your Storage Backend

docker run -d \
--name="speedtest" \
--restart="always" \
--env INFLUXV2_URL=http://example.com \
--env INFLUXV2_TOKEN=my-long-token \
--env INFLUXV2_ORG=my-org \
--env INFLUXV2_BUCKET=speedtests \
--env DELAY=360 \
barrycarey/speedmon:latest

Using Optional Configuration File

If you do not want to configure Speedmon with ENV variables you can us configuration file

  1. Make a directory to hold the config.ini file. Navigate to that directory and download the sample config.ini in this repo.
mkdir speedmon
curl -o speedmon/config.ini https://raw.githubusercontent.com/barrycarey/Speedmon/master/config.ini
cd speedmon
  1. Modify the config file with your influxdb settings.
nano config.ini

Remove the unneeded storage backend sections. Modify the remaining settings to fit our requirements

[GENERAL]
Delay = 360
# Leave blank to auto pick server
Servers =


[INFLUXV2]
Name = Influx v2
URL = = http://localhost:8086
Token = abc12345676
Org = my-org
Bucket = speedtests
Verify_SSL = False


  1. Run the container, pointing to the directory with the config file. This should now pull the image from Docker hub.
docker run -d \
--name="speedtest" \
-v config.ini:/src/config.ini \
--restart="always" \
--env SPEEDTEST_CONFIG=config.ini
barrycarey/speedmon:latest

Before the first use run pip3 install -r requirements.txt

Enter your desired information in config.ini

Run influxspeedtest.py

Adding Additional Backends

If you wish to contribute support for additional backends the process is straight forward.

Add a new Package under speedmon.storage. Create a new Storage Handler that inherits from StorageHandlerBase. Create a new config that inherits from StorageConfig. Add the new storage backed to speedmon.storage.storage_config_map

Add the example config options to config.ini and name the section [HANDLERNAME]. This must match the name you specified in the map

The handler will automatically be loaded and initialized if the config options are available in the config.ini or ENV vars

Owner
Matthew Carey
IT Technician by day, wannabe developer at night.
Matthew Carey
Spam the buzzer and upgrade automatically - Selenium

CookieClicker Usage: Let's check your chrome navigator version : Consequently, you have to : download the right chromedriver in the follow link : http

Iliam Amara 1 Nov 22, 2021
A small automated test structure using python to test *.cpp codes

Get Started Insert C++ Codes Add Test Code Run Test Samples Check Coverages Insert C++ Codes you can easily add c++ files in /inputs directory there i

Alireza Zahiri 2 Aug 03, 2022
Argument matchers for unittest.mock

callee Argument matchers for unittest.mock More robust tests Python's mocking library (or its backport for Python 3.3) is simple, reliable, and easy

Karol Kuczmarski 77 Nov 03, 2022
Django test runner using nose

django-nose django-nose provides all the goodness of nose in your Django tests, like: Testing just your apps by default, not all the standard ones tha

Jazzband 880 Dec 15, 2022
MongoDB panel for the Flask Debug Toolbar

Flask Debug Toolbar MongoDB Panel Info: An extension panel for Rob Hudson's Django Debug Toolbar that adds MongoDB debugging information Author: Harry

Cenk Altı 4 Dec 11, 2019
Thin-wrapper around the mock package for easier use with pytest

pytest-mock This plugin provides a mocker fixture which is a thin-wrapper around the patching API provided by the mock package: import os class UnixF

pytest-dev 1.5k Jan 05, 2023
Test scripts etc. for experimental rollup testing

rollup node experiments Test scripts etc. for experimental rollup testing. untested, work in progress python -m venv venv source venv/bin/activate #

Diederik Loerakker 14 Jan 25, 2022
An interactive TLS-capable intercepting HTTP proxy for penetration testers and software developers.

mitmproxy mitmproxy is an interactive, SSL/TLS-capable intercepting proxy with a console interface for HTTP/1, HTTP/2, and WebSockets. mitmdump is the

mitmproxy 29.7k Jan 02, 2023
Pynguin, The PYthoN General UnIt Test geNerator is a test-generation tool for Python

Pynguin, the PYthoN General UnIt test geNerator, is a tool that allows developers to generate unit tests automatically.

Chair of Software Engineering II, Uni Passau 997 Jan 06, 2023
HTTP client mocking tool for Python - inspired by Fakeweb for Ruby

HTTPretty 1.0.5 HTTP Client mocking tool for Python created by Gabriel Falcão . It provides a full fake TCP socket module. Inspired by FakeWeb Github

Gabriel Falcão 2k Jan 06, 2023
A simple script to login into twitter using Selenium in python.

Quick Talk A simple script to login into twitter using Selenium in python. I was looking for a way to login into twitter using Selenium in python. Sin

Lzy-slh 4 Nov 20, 2022
A complete test automation tool

Golem - Test Automation Golem is a test framework and a complete tool for browser automation. Tests can be written with code in Python, codeless using

486 Dec 30, 2022
UUM Merit Form Filler is a web automation which helps automate entering a matric number to the UUM system in order for participants to obtain a merit

About UUM Merit Form Filler UUM Merit Form Filler is a web automation which helps automate entering a matric number to the UUM system in order for par

Ilham Rachmat 3 May 31, 2022
A feature flipper for Django

README Django Waffle is (yet another) feature flipper for Django. You can define the conditions for which a flag should be active, and use it in a num

952 Jan 06, 2023
Nokia SR OS automation

Nokia SR OS automation Nokia is one of the biggest vendors of the telecommunication equipment, which is very popular in the Service Provider segment.

Karneliuk.com 7 Jul 23, 2022
A wrapper for webdriver that is a jumping off point for web automation.

Webdriver Automation Plus ===================================== Description: Tests the user can save messages then find them in search and Saved items

1 Nov 08, 2021
A library for generating fake data and populating database tables.

Knockoff Factory A library for generating mock data and creating database fixtures that can be used for unit testing. Table of content Installation Ch

Nike Inc. 30 Sep 23, 2022
pytest splinter and selenium integration for anyone interested in browser interaction in tests

Splinter plugin for the pytest runner Install pytest-splinter pip install pytest-splinter Features The plugin provides a set of fixtures to use splin

pytest-dev 238 Nov 14, 2022
Selenium Manager

SeleniumManager I'm fed up with always having to struggle unnecessarily when I have to use Selenium on a new machine, so I made this little python mod

Victor Vague 1 Dec 24, 2021
a plugin for py.test that changes the default look and feel of py.test (e.g. progressbar, show tests that fail instantly)

pytest-sugar pytest-sugar is a plugin for pytest that shows failures and errors instantly and shows a progress bar. Requirements You will need the fol

Teemu 963 Dec 28, 2022