chore(updater): move updater packages to pkg/updaters/<name>

This commit is contained in:
Quentin McGaw
2026-04-23 03:47:57 +00:00
parent 5b01324d5f
commit 13503b0ae0
268 changed files with 1602 additions and 1026 deletions
+36
View File
@@ -0,0 +1,36 @@
package common
import (
"context"
"net/netip"
pubipmodels "github.com/qdm12/gluetun/pkg/publicip/models"
"github.com/qdm12/gluetun/pkg/updaters/models"
"github.com/qdm12/gluetun/pkg/updaters/resolver"
)
type Fetcher interface {
FetchServers(ctx context.Context, minServers int) (servers []models.Server, err error)
Version() uint16
Name() string
}
type ParallelResolver interface {
Resolve(ctx context.Context, settings resolver.ParallelSettings) (
hostToIPs map[string][]netip.Addr, warnings []string, err error)
}
type Unzipper interface {
FetchAndExtract(ctx context.Context, url string) (
contents map[string][]byte, err error)
}
type Warner interface {
Warn(s string)
}
type IPFetcher interface {
String() string
CanFetchAnyIP() bool
FetchInfo(ctx context.Context, ip netip.Addr) (result pubipmodels.PublicIP, err error)
}