mirror of
https://github.com/coredns/coredns.git
synced 2025-10-30 17:53:21 -04:00
mw/proxy: simplify google code (#1019)
* mw/proxy: simplify google code Minimize bootstrap code a bit, and block on the first resolve of the google https endpont. Add more logging and include actual error in the returned errors. Also re-resolve every 120 seconds, instead of 300 (might eventually make this an option). * fix test
This commit is contained in:
@@ -30,7 +30,8 @@ func setup(c *caddy.Controller) error {
|
||||
|
||||
c.OnStartup(OnStartupMetrics)
|
||||
|
||||
for _, u := range upstreams {
|
||||
for i := range upstreams {
|
||||
u := upstreams[i]
|
||||
c.OnStartup(func() error {
|
||||
return u.Exchanger().OnStartup(P)
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user