Documentation
¶
Overview ¶
Package relayprofile describes application relay selection and saved service credentials.
Index ¶
Constants ¶
const MaxAccessKeyBytes = relayset.MaxAccessKeyBytes
const MaximumEndpoints = relayset.MaximumEndpoints
Variables ¶
var ErrCandidatesRequired = errors.New("relay intent excludes the built-in network but has no candidates")
Functions ¶
func PublicURLs ¶
func RegistrationURLs ¶
func RegistrationURLs(candidates []Registration) ([]string, error)
Types ¶
type AuthorizationSource ¶
type AuthorizationSource interface {
ReserveRegistrationAuthorization() serviceauthority.RegistrationAuthorization
}
type Candidate ¶
type Candidate struct {
Node NodeIdentity `json:"-"`
Role CredentialRole `json:"-"`
ManagedTurn bool `json:"managed_turn,omitempty"`
PublicURL string
ConsoleURL string `json:"-"`
OfferedFrontend string `json:"-"`
AccessKey string `json:"-"`
}
func (Candidate) Registration ¶
func (candidate Candidate) Registration() Registration
type CommunityRoute ¶ added in v0.1.7
type CredentialRole ¶ added in v0.1.7
type CredentialRole string
const ( Owner CredentialRole = "owner" Service CredentialRole = "service" Account CredentialRole = "account" )
type Intent ¶
type Intent struct {
// contains filtered or unexported fields
}
Intent separates a user's complete explicit set from configured candidates supplemented by the application network. The zero value requests planning.
func OnlyConfigured ¶
func UseExplicit ¶
func (Intent) Candidates ¶
func (Intent) CommunityAllowed ¶ added in v0.1.7
func (Intent) Mode ¶
func (i Intent) Mode() IntentMode
func (Intent) Validate ¶
Validate distinguishes an impossible selection from unavailable infrastructure: retrying cannot supply candidates when the caller excludes the built-in network.
func (Intent) WithoutCommunity ¶ added in v0.1.7
type NodeIdentity ¶ added in v0.1.7
type Registration ¶
type Registration struct {
Community *CommunityRoute `json:"-"`
PublicURL string
Authorization AuthorizationSource `json:"-"`
}
func Registrations ¶
func Registrations(profiles []Candidate) []Registration