Skip to content

A nagios plugin to check if gem updates are available

License

Notifications You must be signed in to change notification settings

doppelar0n/check_gem

Folders and files

NameName
Last commit message
Last commit date

Latest commit

author
aaronaut
Nov 6, 2024
580d372 · Nov 6, 2024

History

4 Commits
Nov 6, 2024
Nov 6, 2024
Nov 5, 2024
Nov 6, 2024
Nov 6, 2024

Repository files navigation

check_gem

check_gem is a nagios plugin to check if gem updates are available. gem outdated returns a list of gems for which updates are available.

Install

copy the check_gem plugin into your plugin directory, usually /usr/lib/nagios/plugins/:

sudo cp check_gem /usr/lib/nagios/plugins/

Make sure the script is executable:

sudo chmod +x /usr/lib/nagios/plugins/check_gem

Usage

Run the script with the following parameters:

/usr/lib/nagios/plugins/check_gem -w 5 -c 20

Options

  • -w, --warning <number> Minimum number of gem packages available for upgrade to return WARNING status. Default: 1
  • -c, --critical <number> Minimum number of gem packages available for upgrade to return CRITICAL status. Default: 10
  • -h, --help Display this help message.

Example

/usr/lib/nagios/plugins/check_gem -w 5 -c 15
CRITICAL - 16 gem(s) need updates

Test

Run test with:

docker run -it -v "$PWD:/code" bats/bats:latest /code/test

License

This project is licensed under the MIT License. See the LICENSE file for more information.

Releases

No releases published

Packages

No packages published

Languages