##Preview
See images below
Simple Dashing widget (and associated job) to query an Icinga monitoring system and display the hosts and services status summary
Widget background colour is changes on the following priority :- Default is OK - background is green. For host state unknown or service state warning - background is Yellow. For host state down or service state critical - background is Red.
The highest state overrides lower state settings, i.e., with a warning state and a critical state, the critical state wins and the background will be coloured red.
##Usage
To use this widget, copy icinga.html
, icinga.coffee
, and icinga.scss
into the /widgets/icinga
directory. Put the icinga.rb
file in your /jobs
folder. Copy the icinga.yml
into the root of your dashing application.
Alternatively install using the following command, then create your own icinga.yml configuration file
dashing install a99df410ed9060724b24
To include the widget in a dashboard, add the following snippets to the dashboard layout file:
<li data-row="1" data-col="1" data-sizex="1" data-sizey="1">
<div data-id="icinga_host_status" data-view="Icinga" data-title="Host Status"></div>
</li>
<li data-row="1" data-col="2" data-sizex="1" data-sizey="1">
<div data-id="icinga_service_status" data-view="Icinga" data-title="Service Status"></div>
</li>
##Settings
You'll need to configure the icinga.yml
file with the base uri of your icinga server. I.e. https://icinga.myhost.com/
Add the authorisation key to use when accessing the api - this can be set in the icinga control panel.
If you want, change the refresh rate.
Hello
I have this error :
scheduler caught exception:
undefined method
[]' for nil:NilClass /usr/home/dashing/dashing-icinga-master/jobs/icinga.rb:105:in
count_summary'/usr/home/dashing/dashing-icinga-master/jobs/icinga.rb:151:in
block in <top (required)>' /usr/local/lib/ruby/gems/2.1/gems/rufus-scheduler-2.0.24/lib/rufus/sc/jobs.rb:230:in
call'/usr/local/lib/ruby/gems/2.1/gems/rufus-scheduler-2.0.24/lib/rufus/sc/jobs.rb:230:in
trigger_block' /usr/local/lib/ruby/gems/2.1/gems/rufus-scheduler-2.0.24/lib/rufus/sc/jobs.rb:204:in
block in trigger'/usr/local/lib/ruby/gems/2.1/gems/rufus-scheduler-2.0.24/lib/rufus/sc/scheduler.rb:430:in
call' /usr/local/lib/ruby/gems/2.1/gems/rufus-scheduler-2.0.24/lib/rufus/sc/scheduler.rb:430:in
block in trigger_job'Thanks