[LiskHQ/lisk] Use DNS name instead of IP addresses for seed nodes in config.json (#2325)

jondubois commented on this pull request.

> @@ -199,7 +201,37 @@ d.run(() => {
if (!appConfig.nethash) {
throw Error(‘Failed to assign nethash from genesis block’);
}
— cb(null, appConfig);
+
+ // In case domain names are used, resolve those to IP addresses.

@fchavant Only on startup; it’s basically a preprocessing step done to the config file before it’s used by the node. The internal logic only knows about IP addresses.

As part of the discovery process, peers still need to report their IPv4 addresses (we don’t want peers to report themselves by domain name). If we allow peers to report anything (domain name, IPv4 or IPv6 addresses), our life will get a lot more difficult. Potentially, we could stop relying on the ip address as an identifier, but that change would be a lot more significant and I’m not sure if that would be a good idea.