mirror of
https://github.com/netbirdio/netbird.git
synced 2024-11-22 16:13:31 +01:00
Allow route updates even if some domains failed resolution (#2368)
This commit is contained in:
parent
24e031ab74
commit
57624203c9
@ -189,9 +189,14 @@ func (r *Route) startResolver(ctx context.Context) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (r *Route) update(ctx context.Context) error {
|
func (r *Route) update(ctx context.Context) error {
|
||||||
if resolved, err := r.resolveDomains(); err != nil {
|
resolved, err := r.resolveDomains()
|
||||||
|
if err != nil {
|
||||||
|
if len(resolved) == 0 {
|
||||||
return fmt.Errorf("resolve domains: %w", err)
|
return fmt.Errorf("resolve domains: %w", err)
|
||||||
} else if err := r.updateDynamicRoutes(ctx, resolved); err != nil {
|
}
|
||||||
|
log.Warnf("Failed to resolve domains: %v", err)
|
||||||
|
}
|
||||||
|
if err := r.updateDynamicRoutes(ctx, resolved); err != nil {
|
||||||
return fmt.Errorf("update dynamic routes: %w", err)
|
return fmt.Errorf("update dynamic routes: %w", err)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user