Last active
May 29, 2018 12:13
-
-
Save lazyfrosch/a02ccd11ac1e8612f52832228291b710 to your computer and use it in GitHub Desktop.
Wrapper for CheckCommand in Icinga Director
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
plugin_dir=${0%/*} | |
vip="$1" | |
shift | |
command="$1" | |
shift | |
if [ ! "$vip_exists" ]; then | |
echo "Everything is fine." | |
exit 0 | |
fi | |
exec ${plugin_dir}/${command} "$@" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
object CheckCommand "vip-disk" { | |
import "plugin-check-command" | |
import "disk" | |
command = [ | |
PluginDir + "/check_vip_app", | |
"$app_vip$", | |
"check_disk" | |
] | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Command Name: vip-disk | |
Imports: disk | |
Command Line: check_vip_app $app_vip$ check_disk |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment