monitor

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Mar 26, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ComposeFileName            = "compose.yaml"
	OtelConfigFileName         = "otel-config.yaml"
	GrafanaDatasourcesFileName = "grafana-datasources.yaml"
	PrometheusFileName         = "prometheus.yaml"
	GrafanaDashboardsFileName  = "grafana-dashboards.yaml"
	GrafanaDashboardFileName   = "grafana-dashboard.json"
)

Template file names for writing to disk

Variables

View Source
var ComposeTemplate string
View Source
var GrafanaDashboardTemplate string
View Source
var GrafanaDashboardsTemplate string
View Source
var GrafanaDatasourcesTemplate string
View Source
var OtelConfigTemplate string
View Source
var PrometheusTemplate string

Functions

func RenderTemplate added in v0.1.6

func RenderTemplate(name, tmplContent string, data MonitorTemplateData) (string, error)

RenderTemplate renders a Go text/template with the given data.

Types

type MonitorTemplateData added in v0.1.6

type MonitorTemplateData struct {
	OtelCollectorPort     int
	OtelGRPCPort          int // independent of HTTP port — from config.GetOtelGRPCPort()
	LokiPort              int
	PrometheusPort        int
	JaegerPort            int
	GrafanaPort           int
	PrometheusMetricsPort int
	OtelCollectorInternal string
}

MonitorTemplateData provides values for rendering monitoring stack templates.

func NewMonitorTemplateData added in v0.1.6

func NewMonitorTemplateData(cfg *config.MonitoringConfig) MonitorTemplateData

NewMonitorTemplateData constructs template data from MonitoringConfig.

Jump to

Keyboard shortcuts

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