30 lines
652 B
Go
30 lines
652 B
Go
package server
|
|
|
|
import (
|
|
"context"
|
|
|
|
"github.com/qdm12/gluetun/internal/configuration/settings"
|
|
"github.com/qdm12/gluetun/internal/models"
|
|
)
|
|
|
|
type VPNLooper interface {
|
|
GetStatus() (status models.LoopStatus)
|
|
ApplyStatus(ctx context.Context, status models.LoopStatus) (
|
|
outcome string, err error)
|
|
GetSettings() (settings settings.VPN)
|
|
}
|
|
|
|
type DNSLoop interface {
|
|
ApplyStatus(ctx context.Context, status models.LoopStatus) (
|
|
outcome string, err error)
|
|
GetStatus() (status models.LoopStatus)
|
|
}
|
|
|
|
type PortForwardedGetter interface {
|
|
GetPortForwarded() (portForwarded uint16)
|
|
}
|
|
|
|
type PublicIPLoop interface {
|
|
GetData() (data models.PublicIP)
|
|
}
|