Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
122fade954
commit
cb1243e4ed
1 file changed
+22
@@ -39,6 +39,13 @@ type Edge struct {
|
|||||||
OrgIDs []string `json:"orgIds"` // orgs allowed to use this edge; empty = all
|
OrgIDs []string `json:"orgIds"` // orgs allowed to use this edge; empty = all
|
||||||
IPs []string `json:"ips"` // addresses the edge reported it can bind
|
IPs []string `json:"ips"` // addresses the edge reported it can bind
|
||||||
LastSeen time.Time `json:"lastSeen"`
|
LastSeen time.Time `json:"lastSeen"`
|
||||||
|
|
||||||
|
// Version is the release the program reports (e.g. v0.1.5). AutoUpdate says whether it may update
|
||||||
|
// itself; only then will it act on UpdateRequested. UpdateMsg is the outcome of the last requested update.
|
||||||
|
Version string `json:"version,omitempty"`
|
||||||
|
AutoUpdate bool `json:"autoUpdate,omitempty"`
|
||||||
|
UpdateRequested bool `json:"updateRequested,omitempty"`
|
||||||
|
UpdateMsg string `json:"updateMsg,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// Site is a bamboo agent: a private network that holds the real services.
|
// Site is a bamboo agent: a private network that holds the real services.
|
||||||
@@ -56,6 +63,13 @@ type Site struct {
|
|||||||
|
|
||||||
TunnelIP string `json:"tunnelIp,omitempty"` // the site's address inside the tunnel network
|
TunnelIP string `json:"tunnelIp,omitempty"` // the site's address inside the tunnel network
|
||||||
PublicKey string `json:"publicKey,omitempty"` // WireGuard public key, reported by the agent
|
PublicKey string `json:"publicKey,omitempty"` // WireGuard public key, reported by the agent
|
||||||
|
|
||||||
|
// Version is the release the program reports (e.g. v0.1.5). AutoUpdate says whether it may update
|
||||||
|
// itself; only then will it act on UpdateRequested. UpdateMsg is the outcome of the last requested update.
|
||||||
|
Version string `json:"version,omitempty"`
|
||||||
|
AutoUpdate bool `json:"autoUpdate,omitempty"`
|
||||||
|
UpdateRequested bool `json:"updateRequested,omitempty"`
|
||||||
|
UpdateMsg string `json:"updateMsg,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// Domain is a base domain an org owns. Hostnames of web/tls mappings must sit under one.
|
// Domain is a base domain an org owns. Hostnames of web/tls mappings must sit under one.
|
||||||
@@ -216,6 +230,7 @@ type EdgeConfig struct {
|
|||||||
Local []string `json:"local"` // site IDs the edge dials directly on its own machine
|
Local []string `json:"local"` // site IDs the edge dials directly on its own machine
|
||||||
AcmeEmail string `json:"acmeEmail"`
|
AcmeEmail string `json:"acmeEmail"`
|
||||||
AcmeStages bool `json:"acmeStaging"`
|
AcmeStages bool `json:"acmeStaging"`
|
||||||
|
Update bool `json:"update,omitempty"` // an administrator asked this edge to update itself now
|
||||||
|
|
||||||
MailEgress []MailPolicy `json:"mailEgress"`
|
MailEgress []MailPolicy `json:"mailEgress"`
|
||||||
}
|
}
|
||||||
@@ -289,6 +304,9 @@ type EdgeReport struct {
|
|||||||
Stats map[string]Stat `json:"stats"` // deltas since last report
|
Stats map[string]Stat `json:"stats"` // deltas since last report
|
||||||
Containers []Container `json:"containers"`
|
Containers []Container `json:"containers"`
|
||||||
MailChecks map[string]MailCheck `json:"mailChecks"` // by mail-egress ID
|
MailChecks map[string]MailCheck `json:"mailChecks"` // by mail-egress ID
|
||||||
|
Version string `json:"version,omitempty"`
|
||||||
|
AutoUpdate bool `json:"autoUpdate,omitempty"`
|
||||||
|
UpdateMsg string `json:"updateMsg,omitempty"` // outcome of the last requested update
|
||||||
}
|
}
|
||||||
|
|
||||||
// EdgeRef tells a site where to dial.
|
// EdgeRef tells a site where to dial.
|
||||||
@@ -306,6 +324,7 @@ type SiteConfig struct {
|
|||||||
SiteID string `json:"siteId"`
|
SiteID string `json:"siteId"`
|
||||||
TunnelIP string `json:"tunnelIp"` // this site's WireGuard address
|
TunnelIP string `json:"tunnelIp"` // this site's WireGuard address
|
||||||
Edges []EdgeRef `json:"edges"`
|
Edges []EdgeRef `json:"edges"`
|
||||||
|
Update bool `json:"update,omitempty"` // an administrator asked this agent to update itself now
|
||||||
|
|
||||||
MailEgress []MailSpec `json:"mailEgress"`
|
MailEgress []MailSpec `json:"mailEgress"`
|
||||||
}
|
}
|
||||||
@@ -316,6 +335,9 @@ type SiteReport struct {
|
|||||||
MailEgress map[string]string `json:"mailEgress"` // egress ID -> "" (listening) or an error
|
MailEgress map[string]string `json:"mailEgress"` // egress ID -> "" (listening) or an error
|
||||||
Connected []string `json:"connected"`
|
Connected []string `json:"connected"`
|
||||||
Containers []Container `json:"containers"`
|
Containers []Container `json:"containers"`
|
||||||
|
Version string `json:"version,omitempty"`
|
||||||
|
AutoUpdate bool `json:"autoUpdate,omitempty"`
|
||||||
|
UpdateMsg string `json:"updateMsg,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// HostMatches reports whether host matches an exact name or a "*.example.com" pattern.
|
// HostMatches reports whether host matches an exact name or a "*.example.com" pattern.
|
||||||
|
|||||||
Reference in new issue
Block a user