mirror of
https://github.com/coredns/coredns.git
synced 2025-11-01 18:53:43 -04:00
plugin/etcd: fix etcd connection leakage when reload (#6646)
Signed-off-by: zhongyuanjun <zhongyuanjun@bytedance.com> Co-authored-by: zhongyuanjun <zhongyuanjun@bytedance.com>
This commit is contained in:
@@ -21,6 +21,8 @@ func setup(c *caddy.Controller) error {
|
||||
return plugin.Error("etcd", err)
|
||||
}
|
||||
|
||||
c.OnShutdown(e.OnShutdown)
|
||||
|
||||
dnsserver.GetConfig(c).AddPlugin(func(next plugin.Handler) plugin.Handler {
|
||||
e.Next = next
|
||||
return e
|
||||
|
||||
Reference in New Issue
Block a user