Merge pull request #10152 from zouyee/log

optimize error logs by providing absolute file paths
This commit is contained in:
Maksym Pavlenko 2024-04-30 18:22:01 +00:00 committed by GitHub
commit 9e1ad56b41
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -308,7 +308,7 @@ func loadHostDir(ctx context.Context, hostsDir string) ([]hostConfig, error) {
hosts, err := parseHostsFile(hostsDir, b)
if err != nil {
log.G(ctx).WithError(err).Error("failed to decode hosts.toml")
log.G(ctx).WithError(err).Errorf("failed to decode %s", filepath.Join(hostsDir, "hosts.toml"))
// Fallback to checking certificate files
return loadCertFiles(ctx, hostsDir)
}