Here follows a crash course how-to visualize the health of your CI server or live system.
- Buy a TellStick from Kjell & Company, http://www.kjell.com/content/templates/shop_main_details.aspx?item=50200&path=&sms_ss=favorites&at_xt=4d336e97c742b49d,1.
- Buy a remote switch from Kjell & Company, http://www.kjell.com/content/templates/shop_main_details.aspx?item=50219&path=&sms_ss=favorites&at_xt=4d336ec00712cf8f,0.
- Buy your favorite lava lamp/warning light that will indicate the status of your project/live system.
- Install the TellStick software as described at http://www.telldus.se.
- Add the configuration for your remote switch to /etc/tellstick.conf (see example below). Remember to configure the remote switch in the same way.
- Write a program/script that turn on/turn off the remote switch depending on the status of your project (see example below)
- Optional, add the program to crontab in order to check the status at regular intervals (see example below).
- Done đ
tellstick.conf
deviceNode = "/dev/tellstick"
device {
id = 1
name = "enterprise"
protocol = "risingsun"
model = "codeswitch"
parameters {
house = "1"
unit = "1"
}
}
check_enterprise.sh
#!/bin/sh
success=`wget -qO – –http-user=<user> –http-password=<pwd> –auth-no-challenge https://<base>/hudson/job/enterprise/lastBuild/ | grep ‘Success’`
failed=`wget -qO – –http-user=<user> –http-password=<pwd> –auth-no-challenge https://<base>/hudson/job/enterprise/lastBuild/ | grep ‘Failed’`
if [ ! -z "${success}" ]; then
tdtool –on ‘enterprise’
fi
if [ ! -z "${failed}" ]; then
tdtool –off ‘enterprise’
fi
crontab entry:
* 8-16 * * 1-5 /home/magnus/bin/cron/check_enterprise.sh
A good day at work đ
Du fĂ„r visa en lavalampa med bubblor pĂ„ ocksĂ„, annars vet vi ju inte att det fungerar! đ
Var detta nĂ„got du drömde ihop elller har du fĂ„tt det att lira? Jag har problem med just den setupen du beskriver nĂ€mligen. Vad jag kan hitta sĂ„ skall det vara “HQ” som protocol för de dĂ€r kjellmottagarna, inte risingsun. Har testat bĂ„deoch, och HQ funkar i windows och osx-klienten tellduscenter, men de funkar inte under linuxkliente dĂ€r HQ helt enkelt inte verkar finnas..
.. Det Ă€r “fuhaote” man behöver anvĂ€nda för kjells 50219 med tellstick i linux/bsd. Se http://developer.telldus.com/wiki/TellStick_conf
Man anvĂ€nder alltsĂ„ “code” istĂ€llet för “house” och “unit”, och det Ă€r 10 siffror, ettor eller nollor dĂ€r en etta representerar “uppe/on” för motsvarande dipswitch pĂ„ mottagaren, och nolla tvĂ€rtom.