5
0
mirror of https://github.com/cwinfo/yggdrasil-go.git synced 2024-11-15 06:10:29 +00:00
yggdrasil-go/src/yggdrasil/config/config.go

26 lines
2.3 KiB
Go
Raw Normal View History

2018-04-19 14:30:40 +00:00
package config
2018-04-25 14:11:11 +00:00
// NodeConfig defines all configuration values needed to run a signle yggdrasil node
2018-04-19 14:30:40 +00:00
type NodeConfig struct {
2018-05-09 12:54:31 +00:00
Listen string `comment:"Listen address for peer connections (default is to listen for all\nconnections over IPv4 and IPv6)"`
AdminListen string `comment:"Listen address for admin connections (default is to listen only\nfor local connections)"`
Peers []string `comment:"List of connection strings for static peers (i.e. tcp://a.b.c.d:e)"`
2018-05-22 22:43:29 +00:00
AllowedBoxPubs []string `json:"AllowedEncryptionPublicKeys" comment:"List of peer encryption public keys to allow UDP incoming TCP connections from\n(if left empty/undefined then connections will be allowed by default)"`
BoxPub string `json:"EncryptionPublicKey" comment:"Your public encryption key (your peers may ask you for this to put\ninto their AllowedEncryptionPublicKeys configuration)"`
BoxPriv string `json:"EncryptionPrivateKey" comment:"Your private encryption key (do not share this with anyone!)"`
SigPub string `json:"SigningPublicKey" comment:"Your public signing key"`
SigPriv string `json:"SigningPrivateKey" comment:"Your private signing key (do not share this with anyone!)"`
Multicast bool `json:"MulticastEnabled,omitempty" comment:"Enable or disable automatic peer discovery on the same LAN using multicast"`
LinkLocal []string `json:"MulticastInterfaces" comment:"Regexes for which interfaces multicast peer discovery should be enabled\non. If none specified, multicast peer discovery is disabled"`
2018-05-09 12:54:31 +00:00
IfName string `comment:"Local network interface name for TUN/TAP adapter, or \"auto\", or \"none\""`
IfTAPMode bool `comment:"Set local network interface to TAP mode rather than TUN mode (if supported\nby your platform, option will be ignored if not)"`
IfMTU int `comment:"Maximux Transmission Unit (MTU) size for your local network interface"`
2018-05-09 13:03:28 +00:00
Net NetConfig `comment:"Extended options for interoperability with other networks"`
2018-04-19 14:30:40 +00:00
}
2018-04-25 14:11:11 +00:00
// NetConfig defines network/proxy related configuration values
2018-04-19 14:30:40 +00:00
type NetConfig struct {
2018-05-09 13:03:28 +00:00
Tor TorConfig `comment:"Experimental options for configuring peerings over Tor"`
I2P I2PConfig `comment:"Experimental options for configuring peerings over I2P"`
2018-04-19 14:30:40 +00:00
}