1
0
mirror of https://github.com/ribbybibby/ssl_exporter.git synced 2025-07-12 23:50:14 +02:00
Files
ssl_exporter/prober/prober.go

26 lines
629 B
Go
Raw Permalink Normal View History

package prober
import (
2020-11-09 12:57:28 +00:00
"context"
"github.com/go-kit/log"
"github.com/prometheus/client_golang/prometheus"
2022-05-07 09:31:08 +01:00
"github.com/ribbybibby/ssl_exporter/v2/config"
)
var (
// Probers maps a friendly name to a corresponding probe function
Probers = map[string]ProbeFn{
2020-11-15 22:05:51 +00:00
"https": ProbeHTTPS,
"http": ProbeHTTPS,
"tcp": ProbeTCP,
"file": ProbeFile,
"http_file": ProbeHTTPFile,
2020-11-15 22:05:51 +00:00
"kubernetes": ProbeKubernetes,
"kubeconfig": ProbeKubeconfig,
}
)
// ProbeFn probes
type ProbeFn func(ctx context.Context, logger log.Logger, target string, module config.Module, registry *prometheus.Registry) error