Last active
February 13, 2016 05:50
-
-
Save koemu/baf02d03b6462d0b1d54 to your computer and use it in GitHub Desktop.
Get Raspberry pi temperature for Mackerel
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Please append this lines to your config file. | |
[plugin.metrics.raspberrypi_env_temp] | |
command = "/usr/local/bin/raspberrypi_env_temp.py" | |
type = "metric" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
DATE=$(date +%s) | |
echo -e "raspberry_pi.env.temp.cpu\t$(vcgencmd measure_temp | awk -F= '{print $2}' | awk -F\' '{print $1}')\t${DATE}" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment