MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / tailnetDnsName

Function tailnetDnsName

e2e/scripts/cli.ts:126–135  ·  view source on GitHub ↗
(ts: string)

Source from the content-addressed store, hash-verified

124};
125
126const tailnetDnsName = async (ts: string): Promise<string | undefined> => {
127 const { ok, out } = await sh(ts, ["status", "--json"]);
128 if (!ok) return undefined;
129 try {
130 const dns = (JSON.parse(out) as { Self?: { DNSName?: string } }).Self?.DNSName;
131 return dns?.replace(/\.$/, "");
132 } catch {
133 return undefined;
134 }
135};
136
137// --- up --------------------------------------------------------------------
138

Callers 1

runFunction · 0.85

Calls 2

shFunction · 0.70
replaceMethod · 0.65

Tested by

no test coverage detected