The hub encompassing all code for Project Prometheus 2022-23.
- Git
- Python3
- Telegraf
- Grafana
- VS Code
- If you don't have python3, download at https://www.python.org/downloads/
- Install HomeBrew package manager at https://brew.sh/, this will make the other steps easier
- Clone the git repository/download the zip and unzip it
- Install grafana https://grafana.com/grafana/download?platform=mac
- Login to grafana at localhost:3000 (in browser) using username and password of
admin, then skip creating a new password (If this doesn't work, runbrew services restart grafana. Also if you would like to stop the process run 'brew services stop grafana`.) - Go to Configuration → API Keys → Add API Key and give it admin perms, name it anything, and copy this
- Go into the
.conffiles in the files you downloaded from this repository, and replace the bearer key with your API key - Install telegraf by running
brew install telegrafin terminal - Inside of grafana, go to Dashboards → Import or look for any plus symbol that lets you upload a JSON file. Then copy or import the json labeled
dashboard_gs.jsoninside of the/ground-systemsfolder you downloaded cdinto theground-systems/telegraf_configsfolder- Run
telegraf --config prometheus.confandtelegraf --config lc.confin separate terminal instances - Test: Run
ground-systems/dummy_data.pyfrom VS Code using python3. If that doesn't work, run it from terminal by cding into ground-systems and runningpython3 ground-systems/dummy_data.py. Check Grafana, it should be displaying data. - When you actually need to run stuff, run
main.pyinstead of dummy data.
- Download the new repository, and replace main.py, dummy_data.py, and the grafana dashboards in your old repository with the new versions. (Do not just replace the old repo on your machine or you'll have to redo the API key which is annoying)
- Follow step 9 to load in the new dashboard
- Follow steps 10-11 to run telegraf
- Follow steps 12-13 to run it
- If you don't have python3, download at https://www.python.org/downloads/ or download the VScode extension
- Clone the git repository/download the zip and unzip it
- Install Grafana https://grafana.com/grafana/download?platform=windows
- Download Telegraf by copying and pasting the following commands in Powershell
cd ~/Downloads
wget https://dl.influxdata.com/telegraf/releases/telegraf-1.22.4_windows_amd64.zip -UseBasicParsing -OutFile telegraf-1.22.4_windows_amd64.zip
Expand-Archive .\telegraf-1.22.4_windows_amd64.zip -DestinationPath 'C:\Program Files\InfluxData\telegraf'
IMPORTANT: If you have to extract the zip files manually ensure that the above file path is the destination
- Login to grafana at localhost:3000 (in browser) using username and password of
admin, then skip creating a new password - Go to Configuration → API Keys → Add API Key and give it admin perms, name it anything, and copy this
- Go into the
.conffiles in the files you downloaded from this repository, and replace the bearer key with your API key (just lc.conf and prometheus.conf Authorization = "API KEY HERE") - Inside of grafana, go to Dashboards → Import or look for any plus symbol that lets you upload a JSON file. Then copy or import the json labeled
dashboard_gs.jsoninside of the/ground-systemsfolder you downloaded cdinto theground-systems/windowsfolder in two powershell instances- Run
.\start-telegraf.ps1in one instance and.\start-telegraf-2.ps1in the other - Test: Run
ground-systems/dummy_data.pyfrom VS Code using python3 in terminal or the extension start button. If that doesn't work, run it from powershell by cding into ground-systems and runningpython3 dummy_data.py. Check Grafana, it should be displaying random data. When you actually need to run stuff, runmain.pyinstead