breadlysm / SpeedFlux

Script to periodically run the Speedtest CLI application by Ookla and post results to InfluxDB.
MIT License
112 stars 68 forks source link

Feature influx2 #16

Closed breadlysm closed 3 years ago

breadlysm commented 3 years ago

While not completely necessary, I rewrote the config module. This will make for a smoother addition of influx2.

It now functions from a more global scope and is initialized during app startup. This has a few benefits.

  1. Config options are a lot more manageable and easily expanded. Still currently using env variables but now could easily be loaded from a settings file.
  2. Config data is no longer stored in memory. The config settings are always accessed dynamically. (It was bothering me to see full configs in clear text while debugging.)
  3. Cleaner config requests.

Downsides, The config request lines are a bit longer.