net/netmon: publish events to event bus
Updates #15160 Signed-off-by: David Anderson <dave@tailscale.com>
This commit is contained in:
committed by
M. J. Fromberger
parent
6d6f69e735
commit
5399fa159a
@@ -10,6 +10,7 @@ import (
|
||||
"strings"
|
||||
|
||||
"tailscale.com/types/logger"
|
||||
"tailscale.com/util/eventbus"
|
||||
)
|
||||
|
||||
// unspecifiedMessage is a minimal message implementation that should not
|
||||
@@ -24,7 +25,7 @@ type devdConn struct {
|
||||
conn net.Conn
|
||||
}
|
||||
|
||||
func newOSMon(logf logger.Logf, m *Monitor) (osMon, error) {
|
||||
func newOSMon(_ *eventbus.Bus, logf logger.Logf, m *Monitor) (osMon, error) {
|
||||
conn, err := net.Dial("unixpacket", "/var/run/devd.seqpacket.pipe")
|
||||
if err != nil {
|
||||
logf("devd dial error: %v, falling back to polling method", err)
|
||||
|
||||
Reference in New Issue
Block a user