A silly go program that runs "rups" and uses flot to create an html file showing some cpu usage history in plot form.
This is one of the most basic plots you can create with flot (it does not do flot justice), but it gets the point across.
After running rups2html the resulting json file can be parsed by index.html and will display a plot for server, tiled. Check it out in action.
=========
"rups" is expected to be defined as a short script that looks like this:
date
rup SERVER1 SERVER2 SERVER3 ....
date gives the timestamp to mark the data points and the loads across the supplied servers are parsed out of rup's output
=========
I also find that doing something like this is quite helpful:
function checkAndRunrups2html() {
if [ "$(pidof rups2html)" ]; then
echo "rups2html is already running"
else
echo "starting rups2html"
(cd ~/gopath/src/github.com/skiesel/rups2html; ~/gopath/bin/rups2html -scpremote="SERVER:path/to/rups.json" &)
fi
}
alias rups2html="checkAndRunrups2html"
=========