home: imp docs

This commit is contained in:
Stanislav Chzhen 2024-02-07 14:52:12 +03:00
parent 739b158de7
commit 21ad1ecf7b
2 changed files with 6 additions and 3 deletions

View File

@ -259,7 +259,8 @@ type tlsConfigSettings struct {
}
type queryLogConfig struct {
// DirPath is the custom directory for logs.
// DirPath is the custom directory for logs. If it's empty the default
// directory will be used. See [homeContext.getDataDir].
DirPath string `yaml:"dir_path"`
// Ignored is the list of host names, which should not be written to log.
@ -281,7 +282,8 @@ type queryLogConfig struct {
}
type statsConfig struct {
// DirPath is the custom directory for statistics.
// DirPath is the custom directory for statistics. If it's empty the
// default directory will be used. See [homeContext.getDataDir].
DirPath string `yaml:"dir_path"`
// Ignored is the list of host names, which should not be counted.

View File

@ -580,7 +580,8 @@ func checkStatsAndQuerylogDirs(
return statsDir, querylogDir, nil
}
// checkDir checks if the path is a directory.
// checkDir checks if the path is a directory. It's used to check for
// misconfiguration at startup.
func checkDir(path string) (err error) {
var fi os.FileInfo
if fi, err = os.Stat(path); err != nil {