go-ipfs-config: daemon: config option for routing

License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
This commit is contained in:
Łukasz Magiera 2017-08-20 16:24:01 +02:00
parent ca129b458a
commit efb99b5e59
2 changed files with 11 additions and 5 deletions

View File

@ -1,7 +1,10 @@
package config
type Discovery struct {
MDNS MDNS
MDNS MDNS
//Routing sets default daemon routing mode.
Routing string
}
type MDNS struct {

View File

@ -38,10 +38,13 @@ func Init(out io.Writer, nBitsForKeypair int) (*Config, error) {
Datastore: datastore,
Bootstrap: BootstrapPeerStrings(bootstrapPeers),
Identity: identity,
Discovery: Discovery{MDNS{
Enabled: true,
Interval: 10,
}},
Discovery: Discovery{
MDNS: MDNS{
Enabled: true,
Interval: 10,
},
Routing: "dht",
},
// setup the node mount points.
Mounts: Mounts{