Rationalize config file locations and update documentation
All checks were successful
ci/woodpecker/tag/release Pipeline was successful

This commit is contained in:
2026-05-14 21:02:06 -05:00
parent 4ba8d771e0
commit dc8e1040f2
10 changed files with 217 additions and 21 deletions

View File

@@ -0,0 +1,18 @@
package config
// Default filesystem locations for pipeline configuration lookup when --config
// is omitted. Order is highest to lowest precedence.
const (
DefaultPipelineConfigPathUsrLocal = "/usr/local/etc/narratio/pipeline.yml"
DefaultPipelineConfigPathEtc = "/etc/narratio/pipeline.yml"
)
// DefaultPipelineConfigSearchPaths defines the default search order for
// pipeline.yml when callers do not provide an explicit path.
//
// Keep this in a variable so future defaults can be extended without changing
// call sites.
var DefaultPipelineConfigSearchPaths = []string{
DefaultPipelineConfigPathUsrLocal,
DefaultPipelineConfigPathEtc,
}