mirror of
https://github.com/eosswedenorg/thalos
synced 2026-06-18 04:40:03 +02:00
app/log/config.go: add mapstructure tags
This commit is contained in:
parent
106e88f2f4
commit
b517943fee
1 changed files with 4 additions and 4 deletions
|
|
@ -10,16 +10,16 @@ import (
|
|||
// Config represents configuration parameters for a log.
|
||||
type Config struct {
|
||||
// Filename where the log is stored.
|
||||
Filename string `yaml:"filename"`
|
||||
Filename string `yaml:"filename" mapstructure:"filename"`
|
||||
|
||||
// Directory where the log files are stored.
|
||||
Directory string `yaml:"directory"`
|
||||
Directory string `yaml:"directory" mapstructure:"directory"`
|
||||
|
||||
// Maximum filesize, the log is rotated when this size is exceeded.
|
||||
MaxFileSize types.Size `yaml:"maxfilesize"`
|
||||
MaxFileSize types.Size `yaml:"maxfilesize" mapstructure:"maxfilesize"`
|
||||
|
||||
// Maximum lifetime of the file before it is rotated.
|
||||
MaxTime time.Duration `yaml:"maxtime"`
|
||||
MaxTime time.Duration `yaml:"maxtime" mapstructure:"maxtime"`
|
||||
}
|
||||
|
||||
func (c Config) GetFilename() string {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue