Skip to content
This repository was archived by the owner on Oct 3, 2019. It is now read-only.

dmarcos-au/buildlight

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

====================================================================================
Java program that displays Jenkins build statuses using Delcom Gen 2 lights.
GREEN=Success, RED=Failure, BLUE=Building
This program is designed for Windows and make use of the USBCMDAP.exe Delcom windows driver utility.
====================================================================================

Build program
-------------
1. Install java (6 or 7) and ant on your machine
2. Go to the root of the directory and run 'ant all'

Run Program
-----------
1. Go to <root>/dist
2. Add a config file of your choice in <root>/dist/config e.g. myconfig.properties
   jenkins.url=jenkins.mydomain.com    # URL to Jenkins server
   jenkins.job.name=myapp-build-job    # list of jobs to monitor, separated by comma
   light.position=1                    # position of the light to operate on
   update.frequency=3                  # the refresh frequency in seconds
3. Run the command '<root>/dist/buildlight.bat myconfig'

About the Windows driver
------------------------
Delcom Gen II light work with pre-installed native Windows HCI USB driver.
To check that the USBCMDAP.exe usitlity work fine on your machine do the following:

1. Plug in a Delcom Gen II USB light
2. Go to <root>/dist
3. Run the command ./bin/USBCMDAP.exe E
4. Make sure the light is found (program should return TID=2 and SID=<something>)

If the light cannot be found (no output), you need to update the USB HCI Windows driver

About  monitoring several job with one light
--------------------------------------------
The config value jenkins.job.name lets you specify a comma separated list of jobs.
If one specifies jobs A, B, C, then the logic will be:
1. If one of the job is running, then the light will be BLUE
2. Else if one of the job has failed, then the light will be RED
3. Else (i.e. all jobs are successful), then the light will be GREEN

About using several lights
--------------------------
The program works with several lights plugged to several USB ports.
You can therefore monitor several builds (or set of builds) using different lights.
To do that, run one program for each light, with a different config for light.position: 1, 2, 3, etc...
The position references the order in which the Delcom light appears when running 'USBCMDAP.exe E'.
You will therefore need to find out yourself what physical light 1, 3, or 3 corresponds to.



About

CI buildlight java project

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Java 88.6%
  • Groovy 10.8%
  • Shell 0.6%