Skip to content

Icinga2 plugin to check the status of job(s) within AWX!

License

Notifications You must be signed in to change notification settings

iTeV/check_awx_jobs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 

Repository files navigation

check_awx_jobs

check_awx_jobs is a icinga2 plugin that can be used to check the status of job(s) in AWX.

Usage

This plugin makes use of token authentication against the API of AWX. To create a token, please follow this documentation.

Arguments

Argument Description Required
--host The FQDN of the AWX host. Yes
--jobs Which job ID's to check. If you want to check multiple jobs, then put the ID's comma-separated. Yes
--token Token to authenticate against AWX Yes
--verify Whether to verify the HTTPS connection (if any) No

Exit states

The plugin will only go in CRITICAL state when the last run of a job resulted into a failure.

Examples

icinga2 CheckCommand definition:

object CheckCommand "check_awx_jobs" {
    import "plugin-check-command"

    command = [ PluginDir + "/check_awx_jobs" ]
    arguments = {
        "--host" = { value = "$awx_host$" }
        "--jobs" = { value = "$awx_jobs$" }
        "--token" = { value = "$awx_token$" }
    }   
}

Variable definition:

awx_host = "http://awx.foobar"
awx_jobs = 1 # If you want to check multiple jobs, then put the job ids in a comma separated format: 1,3,3,7
awx_token = "verisekjoertoken"

If you think the code can be improved, then dont hesitate to open a PR! :)

About

Icinga2 plugin to check the status of job(s) within AWX!

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages