MCPcopy
hub / github.com/caddyserver/caddy / getLastConfig

Function getLastConfig

caddy.go:1281–1286  ·  view source on GitHub ↗

getLastConfig returns the last-known config file and adapter.

()

Source from the content-addressed store, hash-verified

1279
1280// getLastConfig returns the last-known config file and adapter.
1281func getLastConfig() (file, adapter string, fn reloadFromSourceFunc) {
1282 lastConfigMu.RLock()
1283 f, a, cb := lastConfigFile, lastConfigAdapter, reloadFromSourceCallback
1284 lastConfigMu.RUnlock()
1285 return f, a, cb
1286}
1287
1288// lastConfigMatches returns true if the provided source file and/or adapter
1289// matches the recorded last-config. Matching rules (in priority order):

Callers 2

trapSignalsPosixFunction · 0.85
lastConfigMatchesFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected