Live Demo: Check out the UI at mark7888.github.io/node-network-monitor
This is a simple system to monitor your internet speed over time. It runs speedtests automatically, stores the results, and shows you nice charts in a web dashboard.
The system has a few parts that work together:
- Speedtest nodes that run speed tests every 10 minutes (configurable)
- A data server that collects and stores all the measurements
- A web dashboard where you can see charts and stats
- Everything runs in Docker containers, so it's easy to set up
It's useful if you want to track your ISP's performance, see when your internet is slow, or just keep an eye on your connection quality.
If you don't have Docker and Docker Compose installed yet:
- Install Docker: https://docs.docker.com/engine/install/
- Install Docker Compose: https://docs.docker.com/compose/install/
Make sure both are working by running docker --version and docker compose version
Copy the example environment file and edit it with your settings:
cp .env.example .env
nano .env # or use your favorite editorYou need to set these values in the .env file:
# Database password (choose something secure)
POSTGRES_PASSWORD=your_secure_password_here
DB_PASSWORD=your_secure_password_here
# Admin credentials for the dashboard
ADMIN_USERNAME=admin
ADMIN_PASSWORD=your_admin_password
# JWT secret (use a random string)
JWT_SECRET=your_random_secret_key
# Node configuration
SPEEDTEST_NODE_NAME=my-home-node
SPEEDTEST_SERVER_API_KEY=temporary_key # We'll generate a real one after startingThe other settings have sensible defaults, but you can adjust them if needed.
Start all the services with Docker Compose:
docker-compose up -dThis will start:
- PostgreSQL database (port 5432)
- Data server API (port 8080)
- Web dashboard (port 3000)
- A speedtest node
Wait a minute for everything to start up, then check if it's running:
docker-compose psThe speedtest node needs a proper API key to send data to the server.
Easy way (using the web dashboard):
- Open http://localhost:3000 in your browser
- Log in with your admin credentials
- Go to the API Keys section
- Click "New Key" and give it a name (like "my-home-node")
- Copy the generated API key
Alternative (using curl):
First, get a login token:
curl -X POST http://localhost:8080/api/v1/admin/login \
-H "Content-Type: application/json" \
-d '{"username":"admin","password":"your_admin_password"}'Then create an API key:
curl -X POST http://localhost:8080/api/v1/admin/api-keys \
-H "Authorization: Bearer YOUR_TOKEN_HERE" \
-H "Content-Type: application/json" \
-d '{"name":"my-home-node"}'After generating the key:
Add it to your .env file under SPEEDTEST_SERVER_API_KEY and restart the node:
docker-compose restart network-monitor-nodeGo to http://localhost:3000 in your browser and log in with the admin credentials you set up. You should start seeing speedtest results after a few minutes.
View logs:
docker-compose logs -f # all services
docker-compose logs -f network-monitor-node # just the speedtest nodeStop everything:
docker-compose downUpdate to latest version:
docker-compose pull
docker-compose up -dWant to monitor your internet from multiple locations? You can run just the speedtest node on other computers and have them report to your main server.
-
Make sure Docker is installed
-
Create the required files by copying the content from this repo:
- Copy docker-compose.node.yml to a new file named
docker-compose.node.yml - Copy .env.example.node to a new file named
.env.example.node
- Copy docker-compose.node.yml to a new file named
-
Set up the configuration:
cp .env.example.node .env
nano .env # Edit with your settingsFill in these required values:
SPEEDTEST_NODE_NAME=bedroom-node # Give each node a unique name
SPEEDTEST_SERVER_URL=http://your-server-ip:8080 # Your main server's address
SPEEDTEST_SERVER_API_KEY=your_api_key_here # Generate this from the dashboard- Start the node:
docker-compose -f docker-compose.node.yml up -dThe node will start sending measurements to your main server. Remember to create a unique API key for each node from the admin dashboard!
Can't connect to the dashboard?
- Make sure all containers are running:
docker-compose ps - Check the logs:
docker-compose logs
No data showing up?
- Check if the node is running:
docker-compose logs network-monitor-node - Make sure you've set a valid API key in the
.envfile - The first measurement takes about 10 minutes to appear
Want to change settings?
- Edit the
.envfile - Run
docker-compose up -dto apply changes
Each component has its own README with more details:
- data-server/README.md - API documentation and advanced config
- speedtest-node/README.md - Node setup and troubleshooting
- frontend/README.md - Dashboard features
See the LICENSE file for details.