11 lines
601 B
Bash
11 lines
601 B
Bash
echo "airSensors,sensor_id=TLM0201 temperature=73.97038159354763,humidity=35.23103248356096,co=0.48445310567793615 1630525358
|
|
airSensors,sensor_id=TLM0202 temperature=75.30007505999716,humidity=35.651929918691714,co=0.5141876544505826 1630525358" | gzip > air-sensors.gzip
|
|
|
|
curl --request POST \
|
|
"http://localhost:8086/api/v2/write?org=YOUR_ORG&bucket=YOUR_BUCKET&precision=ns" \
|
|
--header "Authorization: Token YOUR_API_TOKEN" \
|
|
--header "Content-Encoding: gzip" \
|
|
--header "Content-Type: text/plain; charset=utf-8" \
|
|
--header "Accept: application/json" \
|
|
--data-binary @air-sensors.gzip
|