Stream logs from syslog

This commit is contained in:
nemunaire 2026-01-01 21:43:50 +07:00
commit f4481bca62
5 changed files with 287 additions and 5 deletions

View file

@ -14,6 +14,10 @@ type Config struct {
UseARPDiscovery bool
DHCPLeasesPath string
ARPTablePath string
SyslogEnabled bool
SyslogPath string
SyslogFilter string
SyslogSource string
}
// ConsolidateConfig fills an Options struct by reading configuration from
@ -28,6 +32,10 @@ func ConsolidateConfig() (opts *Config, err error) {
UseARPDiscovery: true,
DHCPLeasesPath: "/var/lib/dhcp/dhcpd.leases",
ARPTablePath: "/proc/net/arp",
SyslogEnabled: false,
SyslogPath: "/var/log/messages",
SyslogFilter: "daemon.info iwd:",
SyslogSource: "iwd",
}
declareFlags(opts)