Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/doppelar0n/check_gem
A nagios plugin to check if gem updates are available
https://github.com/doppelar0n/check_gem
Last synced: about 2 months ago
JSON representation
A nagios plugin to check if gem updates are available
- Host: GitHub
- URL: https://github.com/doppelar0n/check_gem
- Owner: doppelar0n
- License: mit
- Created: 2024-11-05T23:44:38.000Z (2 months ago)
- Default Branch: main
- Last Pushed: 2024-11-06T00:20:58.000Z (2 months ago)
- Last Synced: 2024-11-06T01:23:13.950Z (2 months ago)
- Language: Shell
- Size: 2.93 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# 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/`:
```bash
sudo cp check_gem /usr/lib/nagios/plugins/
```Make sure the script is executable:
```bash
sudo chmod +x /usr/lib/nagios/plugins/check_gem
```## Usage
Run the script with the following parameters:
```bash
/usr/lib/nagios/plugins/check_gem -w 5 -c 20
```### Options
- `-w`, `--warning ` Minimum number of gem packages available for upgrade to return `WARNING` status. Default: 1
- `-c`, `--critical ` Minimum number of gem packages available for upgrade to return `CRITICAL` status. Default: 10
- `-h`, `--help` Display this help message.## Example
```bash
/usr/lib/nagios/plugins/check_gem -w 5 -c 15
CRITICAL - 16 gem(s) need updates
```### Test
Run test with:
```bash
docker run -it -v "$PWD:/code" bats/bats:latest /code/test
```## License
This project is licensed under the MIT License. See the [LICENSE](LICENSE) file for more information.