Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultYamlPaths = []YAMLCertRef{ { CertMatchExpr: "$.clusters[:].cluster[\"certificate-authority-data\"]", IDMatchExpr: "$.clusters[:].name", Format: YAMLCertFormatBase64, }, { CertMatchExpr: "$.clusters[:].cluster[\"certificate-authority\"]", IDMatchExpr: "$.clusters[:].name", Format: YAMLCertFormatFile, }, { CertMatchExpr: "$.users[:].user[\"client-certificate-data\"]", IDMatchExpr: "$.users[:].name", Format: YAMLCertFormatBase64, }, { CertMatchExpr: "$.users[:].user[\"client-certificate\"]", IDMatchExpr: "$.users[:].name", Format: YAMLCertFormatFile, }, }
DefaultYamlPaths : Pre-written paths for some k8s config files
View Source
var Version = "0.0.0"
Version is the exporter semantic version and is set at link time
Functions ¶
This section is empty.
Types ¶
type Exporter ¶
type Exporter struct { ListenAddress string Files []string Directories []string YAMLs []string YAMLPaths []YAMLCertRef TrimPathComponents int MaxCacheDuration time.Duration ExposeRelativeMetrics bool ExposeErrorMetrics bool ExposeLabels []string KubeSecretTypes []string KubeIncludeNamespaces []string KubeExcludeNamespaces []string KubeIncludeLabels []string KubeExcludeLabels []string // contains filtered or unexported fields }
Exporter : Configuration (from command-line)
func (*Exporter) ConnectToKubernetesCluster ¶
ConnectToKubernetesCluster : Try connect to a cluster from inside if path is empty, otherwise try loading the kubeconfig at path "path"
func (*Exporter) DiscoverCertificates ¶
func (exporter *Exporter) DiscoverCertificates()
DiscoverCertificates : Parse all certs in a dry run with verbose logging
func (*Exporter) ListenAndServe ¶
ListenAndServe : Convenience function to start exporter
type YAMLCertFormat ¶
type YAMLCertFormat int
YAMLCertFormat : Type of cert encoding in YAML files
const ( YAMLCertFormatFile YAMLCertFormat = iota YAMLCertFormatBase64 = iota )
YAMLCertFormat : Impl
type YAMLCertRef ¶
type YAMLCertRef struct { CertMatchExpr string IDMatchExpr string Format YAMLCertFormat }
YAMLCertRef : Contains information to access certificates in yaml files
Click to show internal directories.
Click to hide internal directories.