MCPcopy
hub / github.com/juanfont/headscale / TailscaleClient

Interface TailscaleClient

integration/tailscale.go:22–69  ·  view source on GitHub ↗

nolint

Source from the content-addressed store, hash-verified

20
21// nolint
22type TailscaleClient interface {
23 Hostname() string
24 Shutdown() (string, string, error)
25 Version() string
26 Execute(
27 command []string,
28 options ...dockertestutil.ExecuteCommandOption,
29 ) (string, string, error)
30 Login(loginServer, authKey string) error
31 LoginWithURL(loginServer string) (*url.URL, error)
32 Logout() error
33 Restart() error
34 Up() error
35 Down() error
36 IPs() ([]netip.Addr, error)
37 MustIPs() []netip.Addr
38 IPv4() (netip.Addr, error)
39 MustIPv4() netip.Addr
40 MustIPv6() netip.Addr
41 FQDN() (string, error)
42 MustFQDN() string
43 Status(...bool) (*ipnstate.Status, error)
44 MustStatus() *ipnstate.Status
45 Netmap() (*netmap.NetworkMap, error)
46 DebugDERPRegion(region string) (*ipnstate.DebugDERPRegionReport, error)
47 GetNodePrivateKey() (*key.NodePrivate, error)
48 Netcheck() (*netcheck.Report, error)
49 WaitForNeedsLogin(timeout time.Duration) error
50 WaitForRunning(timeout time.Duration) error
51 WaitForPeers(expected int, timeout, retryInterval time.Duration) error
52 Ping(hostnameOrIP string, opts ...tsic.PingOption) error
53 Curl(url string, opts ...tsic.CurlOption) (string, error)
54 CurlFailFast(url string) (string, error)
55 Traceroute(netip.Addr) (util.Traceroute, error)
56 ContainerID() string
57 MustID() types.NodeID
58 ReadFile(path string) ([]byte, error)
59 PacketFilter() ([]filter.Match, error)
60 ConnectToNetwork(network *dockertest.Network) error
61 DisconnectFromNetwork(network *dockertest.Network) error
62 ReconnectToNetwork(network *dockertest.Network) error
63
64 // FailingPeersAsString returns a formatted-ish multi-line-string of peers in the client
65 // and a bool indicating if the clients online count and peer count is equal.
66 FailingPeersAsString() (string, bool, error)
67
68 WriteLogs(stdout, stderr io.Writer) error
69}

Callers 163

snapshotClientFiltersFunction · 0.65
assertPingAllWithCollectFunction · 0.65
pingDerpAllHelperFunction · 0.65
isSelfClientFunction · 0.65
assertValidNetmapFunction · 0.65
AddAndLoginClientMethod · 0.95

Implementers 1

TailscaleInContainerintegration/tsic/tsic.go

Calls

no outgoing calls

Tested by

no test coverage detected