abstract-socket-proxy

command module
v0.0.0-...-f5b174b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 5, 2021 License: Apache-2.0 Imports: 20 Imported by: 0

README

abstract-socket-proxy

An Prometheus proxy for abstract socket address

Working as a node agent/proxy, scrapes metrics from found Unix socket, and returns to Prometheus.

How to use

$ abstract-socket-proxy --pattern "@/containerd-shim/k8s.io/(?P<sandbox>[0-9a-zA-Z]*)/shim-monitor.sock@"

This will read /proc/net/unix and match lines by the pattern option, and get metrics through the socket.

You can specify the metrics path by -metrics-path option, the default value is /metrics.

The pattern option dosn't only used to filter sockets, but also can be used to parse the file path and convert the named pattern to metrics labels. For the upon pattern, the proxy will also add a label "sandbox": "matched-string" to metrics scraped from the target socket path.

Todos

  • support normal Unix domain socket.

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL