MCPcopy Create free account
hub / github.com/CrunchyData/postgres-operator / PGExporterContainerImage

Function PGExporterContainerImage

internal/config/config.go:71–80  ·  view source on GitHub ↗

PGExporterContainerImage returns the container image to use for the PostgreSQL Exporter.

(cluster *v1beta1.PostgresCluster)

Source from the content-addressed store, hash-verified

69// PGExporterContainerImage returns the container image to use for the
70// PostgreSQL Exporter.
71func PGExporterContainerImage(cluster *v1beta1.PostgresCluster) string {
72 var image string
73 if cluster.Spec.Monitoring != nil &&
74 cluster.Spec.Monitoring.PGMonitor != nil &&
75 cluster.Spec.Monitoring.PGMonitor.Exporter != nil {
76 image = cluster.Spec.Monitoring.PGMonitor.Exporter.Image
77 }
78
79 return defaultFromEnv(image, "RELATED_IMAGE_PGEXPORTER")
80}
81
82// CollectorContainerImage returns the container image to use for the
83// collector container.

Callers 3

VerifyImageValuesFunction · 0.85

Calls 1

defaultFromEnvFunction · 0.70

Tested by 1