mirror of
https://github.com/traefik/traefik.git
synced 2025-09-28 09:11:24 +02:00
Moved /api/cluster/leadership handler under public routes (requires no authentication)
This commit is contained in:
parent
a179c3b399
commit
ff32529345
@ -744,9 +744,6 @@ func (s *Server) addInternalRoutes(entryPointName string, router *mux.Router) {
|
|||||||
|
|
||||||
if s.globalConfiguration.API != nil && s.globalConfiguration.API.EntryPoint == entryPointName {
|
if s.globalConfiguration.API != nil && s.globalConfiguration.API.EntryPoint == entryPointName {
|
||||||
s.globalConfiguration.API.AddRoutes(router)
|
s.globalConfiguration.API.AddRoutes(router)
|
||||||
if s.leadership != nil {
|
|
||||||
s.leadership.AddRoutes(router)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -754,6 +751,10 @@ func (s *Server) addInternalPublicRoutes(entryPointName string, router *mux.Rout
|
|||||||
if s.globalConfiguration.Ping != nil && s.globalConfiguration.Ping.EntryPoint != "" && s.globalConfiguration.Ping.EntryPoint == entryPointName {
|
if s.globalConfiguration.Ping != nil && s.globalConfiguration.Ping.EntryPoint != "" && s.globalConfiguration.Ping.EntryPoint == entryPointName {
|
||||||
s.globalConfiguration.Ping.AddRoutes(router)
|
s.globalConfiguration.Ping.AddRoutes(router)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if s.globalConfiguration.API != nil && s.globalConfiguration.API.EntryPoint == entryPointName && s.leadership != nil {
|
||||||
|
s.leadership.AddRoutes(router)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (s *Server) addACMERoutes(entryPointName string, router *mux.Router) {
|
func (s *Server) addACMERoutes(entryPointName string, router *mux.Router) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user