diff --git a/agent/node.go b/agent/node.go index 6de6e57d26..82b23763d6 100644 --- a/agent/node.go +++ b/agent/node.go @@ -377,6 +377,7 @@ func (n *Node) runAgent(ctx context.Context, db *bolt.DB, creds credentials.Tran if err != nil { return err } + defer conn.Close() agent, err := New(&Config{ Hostname: n.config.Hostname,