mirror of
https://github.com/ipfs/kubo.git
synced 2026-02-23 19:37:46 +08:00
core: set local listening addresses
This commit is contained in:
parent
87c4fb2fea
commit
a10fb7aa4b
@ -127,6 +127,11 @@ func NewIpfsNode(ctx context.Context, cfg *config.Config, online bool) (n *IpfsN
|
||||
}
|
||||
n.AddChildGroup(n.Network.CtxGroup())
|
||||
|
||||
// explicitly set these as our listen addrs.
|
||||
// (why not do it inside inet.NewNetwork? because this way we can
|
||||
// listen on addresses without necessarily advertising those publicly.)
|
||||
n.Peerstore.AddAddresses(n.Identity, n.Network.ListenAddresses())
|
||||
|
||||
// setup diagnostics service
|
||||
n.Diagnostics = diag.NewDiagnostics(n.Identity, n.Network)
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user