When the node is shutting down, new connections can still be received.
If this happens we can end up writing into the datastore when it's
been closed which throws an error.
Instead, if we're not running, have the connection manager close new
incoming connections.
BREAKING CHANGES:
top level types were updated, multiaddr@9.0.0 is used, dialer and keychain internal property names changed and connectionManager minPeers is not supported anymore