From 18d49da9da1ea5103512d6065d6dc38882477b21 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20de=20Metz?= Date: Wed, 25 May 2016 21:08:58 +0200 Subject: [PATCH] Add listen config. --- agent/agent.go | 2 +- internal/config/config.go | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/agent/agent.go b/agent/agent.go index 4ce7a3aab..2806c0013 100644 --- a/agent/agent.go +++ b/agent/agent.go @@ -328,7 +328,7 @@ func (a *Agent) Run(shutdown chan struct{}) error { // channel shared between all input threads for accumulating metrics metricC := make(chan telegraf.Metric, 10000) webserver := webserver.NewWebserver() - webserver.ServiceAddress = ":1619" + webserver.ServiceAddress = a.Config.Agent.WebhookServiceAddress for _, input := range a.Config.Inputs { // Start service of any ServicePlugins diff --git a/internal/config/config.go b/internal/config/config.go index daaaa10fc..0d0ebca72 100644 --- a/internal/config/config.go +++ b/internal/config/config.go @@ -122,6 +122,9 @@ type AgentConfig struct { Quiet bool Hostname string OmitHostname bool + + // + WebhookServiceAddress string } // Inputs returns a list of strings of the configured inputs.