RightScale server status to zabbix
Ruby
Switch branches/tags
Nothing to show
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
lib
.gitignore
Gemfile
Gemfile.lock
README.md
rs-zabbix.config.yaml.sample
rs-zabbix.rb

README.md

rs-zabbix

Reads server status data from RightScale and stores it to zabbix via trapper.

Installation

Clone/Fork project

Depencies

bundle install

Configuration for the script

Copy the sample config file without the ".sample" suffix.

Example usage

ruby rs-zabbix.rb

Check out -h parameter to see all options

Add as a cronjob to be run automatically as frequently as you need.

Configuration required in Zabbix

Zabbix item

Host: Select host or template to bind the item into
Description: Rightscale Server Status
Type: Zabbix Trapper
Key: rightscale.server.status (or the custome one if you have defined)
Type of information: Text

Fill out rest of the settings the way your project requires.

Zabbix trigger to be notified of non operational servers

Name: {HOSTNAME} status in RightScale is: {ITEM.LASTVALUE}
Expression: {<Your Template or server name>:rightscale.server.status.str("operational")}=0

Zabbix trigger to notify you from non operational notifyscript:

Name: RightScale Server Status data not updated on {HOSTNAME}
Expression: {<Your Template or server name>:rightscale.server.status.nodata(7200)}=1

License

Included Ruby API Wrapper for RightScale API is Copyright 2009 RightScale, Inc. (lib/RightAPI.rb)

Rest of the code:

(The MIT License)

Copyright(c) 2012 Applifier Ltd.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the 'Software'), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.