agent: Allow 'consul' service to be targeted for events. Fixes #344
This commit is contained in:
parent
2c1add1c67
commit
1759f36d43
|
@ -157,6 +157,11 @@ func (a *Agent) shouldProcessUserEvent(msg *UserEvent) bool {
|
|||
}
|
||||
|
||||
if msg.ServiceFilter != "" {
|
||||
// Handle "consul" service on server nodes
|
||||
if a.server != nil && msg.ServiceFilter == "consul" {
|
||||
return true
|
||||
}
|
||||
|
||||
re, err := regexp.Compile(msg.ServiceFilter)
|
||||
if err != nil {
|
||||
a.logger.Printf("[ERR] agent: Failed to parse service filter '%s' for event '%s': %v",
|
||||
|
|
Loading…
Reference in New Issue