Documentation
¶
Index ¶
- func DNSProviderConfigured() bool
- func GetBool(key string, defaultValue bool) bool
- func GetString(key, defaultValue string) string
- func KeepAliveInterval() time.Duration
- func MagicDNSSuffix() string
- type Auth
- type AuthProvider
- type Config
- type DERP
- type DERPServer
- type DNS
- type DNSProvider
- type Database
- type Duration
- type Keys
- type Logging
- type PollNet
- type ServerKeys
- type SystemAdminPolicy
- type Tls
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DNSProviderConfigured ¶ added in v0.6.0
func DNSProviderConfigured() bool
func KeepAliveInterval ¶
func MagicDNSSuffix ¶ added in v0.2.0
func MagicDNSSuffix() string
Types ¶
type Auth ¶ added in v0.3.0
type Auth struct { Provider AuthProvider `json:"provider,omitempty"` SystemAdminPolicy SystemAdminPolicy `json:"system_admins"` }
type AuthProvider ¶
type Config ¶
type Config struct { ListenAddr string `json:"listen_addr,omitempty"` StunListenAddr string `json:"stun_listen_addr,omitempty"` MetricsListenAddr string `json:"metrics_listen_addr,omitempty"` PublicAddr string `json:"public_addr,omitempty"` StunPublicAddr string `json:"stun_public_addr,omitempty"` Tls Tls `json:"tls,omitempty"` PollNet PollNet `json:"poll_net,omitempty"` Keys Keys `json:"keys,omitempty"` Database Database `json:"database,omitempty"` Auth Auth `json:"auth,omitempty"` DNS DNS `json:"dns,omitempty"` DERP DERP `json:"derp,omitempty"` Logging Logging `json:"logging,omitempty"` PublicUrl *url.URL `json:"-"` // contains filtered or unexported fields }
func LoadConfig ¶
func (*Config) DefaultDERPMap ¶ added in v0.15.0
func (*Config) ReadServerKeys ¶
func (c *Config) ReadServerKeys(defaultKeys *domain.ControlKeys) (*ServerKeys, error)
type DERP ¶ added in v0.15.0
type DERP struct { Server DERPServer `json:"server,omitempty"` Sources []string `json:"sources,omitempty"` }
type DERPServer ¶ added in v0.15.0
type DNS ¶ added in v0.2.0
type DNS struct { MagicDNSSuffix string `json:"magic_dns_suffix"` Provider DNSProvider `json:"provider,omitempty"` }
type DNSProvider ¶ added in v0.3.0
type DNSProvider struct { Name string `json:"name"` PluginPath string `json:"plugin_path"` Zone string `json:"zone"` Configuration json.RawMessage `json:"config"` }
type Database ¶
type Database struct { Type string `json:"type,omitempty"` Url string `json:"url,omitempty"` MaxOpenConns int `json:"max_open_conns,omitempty"` MaxIdleConns int `json:"max_idle_conns,omitempty"` ConnMaxLifetime Duration `json:"conn_max_life_time,omitempty"` ConnMaxIdleTime Duration `json:"conn_max_idle_time,omitempty"` }
type Duration ¶ added in v0.17.0
func (Duration) MarshalJSON ¶ added in v0.17.0
func (*Duration) UnmarshalJSON ¶ added in v0.17.0
type ServerKeys ¶
type ServerKeys struct { SystemAdminKey *key.ServerPrivate ControlKey tkey.MachinePrivate LegacyControlKey tkey.MachinePrivate }
type SystemAdminPolicy ¶
type Tls ¶
type Tls struct { Disable bool `json:"disable"` ForceHttps bool `json:"force_https"` CertFile string `json:"cert_file,omitempty"` KeyFile string `json:"key_file,omitempty"` AcmeEnabled bool `json:"acme,omitempty"` AcmeEmail string `json:"acme_email,omitempty"` AcmeCA string `json:"acme_ca,omitempty"` }
Click to show internal directories.
Click to hide internal directories.