MCPcopy Create free account
hub / github.com/prometheus/common / SetDirectory

Method SetDirectory

config/http_config.go:1361–1368  ·  view source on GitHub ↗

SetDirectory joins any relative file paths with dir.

(dir string)

Source from the content-addressed store, hash-verified

1359
1360// SetDirectory joins any relative file paths with dir.
1361func (c *TLSConfig) SetDirectory(dir string) {
1362 if c == nil {
1363 return
1364 }
1365 c.CAFile = JoinDir(dir, c.CAFile)
1366 c.CertFile = JoinDir(dir, c.CertFile)
1367 c.KeyFile = JoinDir(dir, c.KeyFile)
1368}
1369
1370// UnmarshalYAML implements the yaml.Unmarshaler interface.
1371func (c *TLSConfig) UnmarshalYAML(unmarshal func(any) error) error {

Callers

nothing calls this directly

Calls 1

JoinDirFunction · 0.85

Tested by

no test coverage detected