[December 2022] Internet Health Logger and Monitor

Let the hate for ISPs flow through you.

let-the-hate-flow-through-you-your-hate-has-made-you-powerful

My neighbors have been having internet outage issues the and came by to ask if I had expired any outages recently. I’ve been out of town for the holidays and decided to check my Ubiquiti router. Sadly the router only seems to display package loss stats for up to 24 hours. That’s when it struck me I have a project for devember.

I plan to build and dockize a python script that logs internet health data and a UI to display that information. I then plan to dockize it so I can easily deploy It to my home lab. Maybe in the future, (probably not this devember) I’ll even add the ability to automatically fire off a email complaining about excessive outages.

The following is a list of my prioritized goals:

  1. Create script that pings list of IPs, gets latency, and runs a speed test.
  2. Save that data in a database (probably MongoDB).
  3. Purge data after a default of 365 days.
  4. Create an API to retrieve data.
  5. Create a front-end to display data as graphs.
  6. Create and download reports off data.
  7. Dockize it

Probably won’t get to it before devember is over but allow users to draft email bodies and subjects to automatically be sent when high down times are detected to any email. (ISP, law firm, Local leaders, Congress critters, regulatory agencies, etc.)

Definitely won’t get to it before devember is over. Create a windows and Mac desktop installer for the normies (Maybe a project for next devember). Probably would need to figure out how to detect if the computer it’s installed on has a sleep timer enabled and warn the user to change the setting.

GitHub Link
dockerhub Link

GitHub Link UI
dockerhub Link UI

2 Likes

Just figured I’d post my compose setup for it:

  InternetHealthLogger:
    image: darthmanatee/internethealthlogger
    ports:
      - 8000:8000
    environment: 
      - DB_ADDRESS=192.168.1.68 #Set this to the address of your Mongo DB
      - DB_PORT=27017 #Set this to the port of your Mongo DB        
      - UI_ORIGIN=http://192.168.1.68:4200  #Set this to the IPAddress:PORT of the Internet Health Logger UI

  InternetHealthLoggerUI:
    image: darthmanatee/internethealthloggerui
    ports:
      - 4200:80
    environment:
      - API_URL=http://192.168.1.68:8000 #Set this to the IPAddress:PORT of the Internet Health Logger API
1 Like

Stole docker compose and added it to README.md’s:

version: "3.8"
services:

    mongodb_container:
        image: mongo:latest
        container_name: internethealthloggerdb
        ports:
          - 27017:27017
        volumes:
          - <set-where-you-want-volume-mounted>:/data/db
        restart: unless-stopped
    
    InternetHealthLogger:
        image: darthmanatee/internethealthlogger:latest
        container_name: internethealthloggerapi
        ports:
          - 8000:8000
        environment: 
          - DB_ADDRESS=10.100.100.5 #Set this to the address of your Mongo DB
          - DB_PORT=27017 #Set this to the port of your Mongo DB
          - UI_ORIGIN=http://10.100.100.5:4200  #Set this to the IPAddress:PORT of the Internet Health Logger UI
        restart: unless-stopped

    InternetHealthLoggerUI:
        image: darthmanatee/internethealthloggerui:latest
        container_name: internethealthloggerui
        ports:
          - 4200:80
        environment:
          - API_URL=http://10.100.100.5:8000 #Set this to the IPAddress:PORT of the Internet Health Logger API
        restart: unless-stopped