Hi, On 12/8/20 4:01 AM, fun...@gmail.com wrote:
someone can help me?
If you want to verify that your target always returns one of the two status codes, then define a custom blackbox_exporter http module with valid_status_codes: [301, 302].
I assume you will also have a Location: header in this case. If this should be checked as well, you might want to use fail_if_header_not_matches additionally. no_follow_redirects: true might also be necessary.
If you are just looking for such a metric, probe_http_status_code may be what you want.
Kind regards, Christian -- You received this message because you are subscribed to the Google Groups "Prometheus Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to prometheus-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/prometheus-users/a68da866-1b5b-4d28-71c7-c8ddb5c68e4c%40hoffmann-christian.info.