mirror of
https://github.com/AdguardTeam/AdGuardHome.git
synced 2024-11-25 06:25:44 +03:00
18 lines
284 B
Go
18 lines
284 B
Go
//go:build !windows
|
|
|
|
package aghos
|
|
|
|
import (
|
|
"log/syslog"
|
|
|
|
"github.com/AdguardTeam/golibs/log"
|
|
)
|
|
|
|
func configureSyslog(serviceName string) error {
|
|
w, err := syslog.New(syslog.LOG_NOTICE|syslog.LOG_USER, serviceName)
|
|
if err != nil {
|
|
return err
|
|
}
|
|
log.SetOutput(w)
|
|
return nil
|
|
}
|