Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var EmptySrcErr = errors.New("empty src template")
Functions ¶
func ProcessOnce ¶
func UnmarshalJsonArray ¶
func UnmarshalJsonObject ¶
Types ¶
type Config ¶
type Config struct { ParentDir string ConfDir string TemplateDir string Prefix string Noop bool StoreClient store.StoreClient KeepTempFile bool }
Template global config , value init from topod config
type TemplateResource ¶
type TemplateResource struct { CheckCmd string `toml:"check_cmd"` Dest string `toml:"dest"` FileMode os.FileMode Gid int Keys []string `toml:"keys"` Mode string `toml:"mode"` Prefix string `toml:"prefix"` ReloadCmd string `toml:"reload_cmd"` Src string `toml:"src"` TempFile *os.File Backup bool `toml:"backup"` BackupDir string `toml:"backupdir"` Uid int // contains filtered or unexported fields }
Template file parsed config, part of vars from template global config above, some from xxx_xxx.toml config file
func NewConfigTemplate ¶
func NewConfigTemplate(path string, config *Config) (*TemplateResource, error)
* New template resource from toml config file in conf.d
Click to show internal directories.
Click to hide internal directories.