Skip to content

Latest commit

 

History

History
36 lines (30 loc) · 1.01 KB

README.md

File metadata and controls

36 lines (30 loc) · 1.01 KB

Speedtest by Ookla® - NodeJS Logger

This script will test your internet speed and send it to an API for storage.

Dependency

You need Ookla®'s Speedtest CLI tool.

Download and installation guide

How to use

Define environment file

Assuming you have pulled the repository, you now have to define the environment file.

# Make a copy of the example file
cp example.env .env

What you need to define

STORE_URL: The URL to the enpoint in which you can store the test result.
SPEEDTEST_CLI_UNIT_FORMAT: The format in which you wish the bandwidth result to be.
SPEEDTEST_CLI_OUTPUT_FORMAT: The format in which you wish the output to be.

Optional enviroment variables

If you set the ENV variable to development, the NodeJS app will console out relevant data for debugging purposes.

Install packages 🧶

yarn install

Build your NodeJS logger 🧶

yarn build

Run the logger 🚀

node dist/speedtest.js