This commit is contained in:
Kolossos 2020-06-20 22:24:25 +02:00
parent 9cbcdf3f1c
commit 1b2f1ace05
1 changed files with 3 additions and 2 deletions

View File

@ -229,10 +229,11 @@ def write_csv(res):
def to_grafana(res):
try:
os.system("curl -i -XPOST '172.23.92.63:8086/write?db=mydb&u=admin&p=PASSWORD' --data-binary 'weight,location=bees01 value="str(res))+"'")
os.system("curl -i -XPOST '"+grafanaurl+"' --data-binary 'weight,location=bees01 value="str(res))+"'")
except:
print("no access to grafana?")
pass
time.sleep(5)
x_value=0
do_measurement()