From 13bcc4da44446d837c2fec15588ac9d1f994ba58 Mon Sep 17 00:00:00 2001 From: Steven Allen Date: Mon, 25 May 2020 14:05:24 -0700 Subject: [PATCH 1/2] go-ipfs-config: feat: add peering service config section --- config/config.go | 1 + config/peering.go | 9 +++++++++ 2 files changed, 10 insertions(+) create mode 100644 config/peering.go diff --git a/config/config.go b/config/config.go index 9af0cf68f19..5f6be8e5ac5 100644 --- a/config/config.go +++ b/config/config.go @@ -27,6 +27,7 @@ type Config struct { Swarm SwarmConfig AutoNAT AutoNATConfig Pubsub PubsubConfig + Peering Peering Provider Provider Reprovider Reprovider diff --git a/config/peering.go b/config/peering.go new file mode 100644 index 00000000000..21724686629 --- /dev/null +++ b/config/peering.go @@ -0,0 +1,9 @@ +package config + +import "github.com/libp2p/go-libp2p-core/peer" + +// Peering configures the peering service. +type Peering struct { + // Peer lists all peers with which this peer peers. + Peers []peer.AddrInfo +} From 75bde89788a3feac84fb258b9edc2d09ac24ce0b Mon Sep 17 00:00:00 2001 From: Steven Allen Date: Mon, 25 May 2020 19:14:40 -0700 Subject: [PATCH 2/2] go-ipfs-config: doc: improve wording for peering config Co-authored-by: Will --- config/peering.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config/peering.go b/config/peering.go index 21724686629..242ce2d9898 100644 --- a/config/peering.go +++ b/config/peering.go @@ -4,6 +4,6 @@ import "github.com/libp2p/go-libp2p-core/peer" // Peering configures the peering service. type Peering struct { - // Peer lists all peers with which this peer peers. + // Peers lists the nodes to attempt to stay connected with. Peers []peer.AddrInfo }