|
Event
|
util.check-http-follow-redirect
|
Verifies that redirection links can be followed in a set number of requests.
|
Usage check-head-redirect.rb \(options\):
- -A, --auth-first-only: Use basic auth on first request only.
- -aws-access-key-id: AWS Access Key. Either set ENV\["AWS\_ACCESS\_KEY\_ID"\] or provide it as an option on agent.
- -r -aws-region: AWS Region \(defaults to us-east-1\).
- --aws-secret-access-key: AWS Secret Access Key. Either set ENV\["AWS\_SECRET\_ACCESS\_KEY"\] or provide it as an option on agent.
- -R --redirect: Follow first <N> redirects
- -g --get-redirects: Follow first <N> redirects with GET requests.
- -s, --s3-config-bucket: S3 config bucket to get configuration.
- -k, --s3-config-key: S3 config key to get configuration.
- -u, --url: URL needs to be updated in `Monitoring HTTP Entrypoint/cmdb_ci_endpoint_http_list.do` for the CI.
The Aws-region, aws-secret-key, aws-access-key ,s3-config, s3-config-key parameters are useful if you do not want to configure connection information in other check parameters. If a bucket and key have access to the environment in which the Sensu check executes in, provide an AWS key and token and the checks pull the specified JSON file from S3 and merge the JSON config into the current check configuration.
Usage example: `command: check-head-redirect.rb -R 10 -u 'https://servicenow.com'`
|
Check Head Redirect OK
|
|
Event
|
util.check-http-response
|
Verifies URL response time and raises a CRITICAL/WARNING event if elapsed time exceeds provided CRITICAL/WARNING thresholds. Otherwise, it raises an OK event.
|
Usage: check-head-redirect.rb \(options\)
- -R, --redirect: Follow first <N> redirects.
- -w --timeout\_warning: Set the timeout threshold for warning in milliseconds.
- -c --timeout\_critical: Set the timeout threshold for critical in milliseconds.
- -u, --url URL needs to be updated in `Monitoring HTTP Entrypoint/cmdb_ci_endpoint_http_list.do` for the CI.
Usage example: `command: check-head-redirect.rb -R 10 -u 'https://servicenow.com' -w 3000 -c 5000`
|
Check Head Redirect OK
|