Skip to content

Commit

Permalink
Fix vet issues.
Browse files Browse the repository at this point in the history
  • Loading branch information
blakerouse committed Jul 28, 2020
1 parent 7b21e09 commit 2f34799
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 1 deletion.
1 change: 1 addition & 0 deletions x-pack/elastic-agent/pkg/agent/control/addr.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import (
"github.com/elastic/beats/v7/x-pack/elastic-agent/pkg/agent/application/paths"
)

// Address returns the address to connect to Elastic Agent daemon.
func Address() string {
data := paths.Data()
return fmt.Sprintf("unix://%s", filepath.Join(data, "agent.sock"))
Expand Down
2 changes: 1 addition & 1 deletion x-pack/elastic-agent/pkg/agent/control/addr_windows.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import (
"github.com/elastic/beats/v7/x-pack/elastic-agent/pkg/agent/application/paths"
)

// Address control address for both server and client.
// Address returns the address to connect to Elastic Agent daemon.
func Address() string {
data = paths.Data()
return fmt.Sprintf(`\\.\pipe\elastic-agent-%s`, sha256.Sum256(data))
Expand Down
2 changes: 2 additions & 0 deletions x-pack/elastic-agent/pkg/agent/control/server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,14 @@ import (
"github.com/elastic/beats/v7/x-pack/elastic-agent/pkg/core/logger"
)

// Server is the daemon side of the control protocol.
type Server struct {
logger *logger.Logger
listener net.Listener
server *grpc.Server
}

// New creates a new control protocol server.
func New(log *logger.Logger) *Server {
return &Server{
logger: log,
Expand Down

0 comments on commit 2f34799

Please sign in to comment.