Open davidawad opened 3 years ago
This seems to be a deliberate consequence of the following lines in Node.installDockerConfig()
:
val dockerConf = config
.withValue("p2pAddress", ConfigValueFactory.fromAnyRef("$containerName:$p2pPort"))
.withValue("rpcSettings.address", ConfigValueFactory.fromAnyRef("$containerName:${rpcSettings.port}"))
.withValue("rpcSettings.adminAddress", ConfigValueFactory.fromAnyRef("$containerName:${rpcSettings.adminPort}"))
...
so partyc
is the container name and not the hostname.
docker-compose relies on aliases to map the containers to IP addresses internally (https://docs.docker.com/compose/networking/). However you should still be able to run the nodes using their generated Dockerform configuration on another machine. The host paths need to be updated in docker-compose.yml
file because absolute file paths are used to map content from host to the container. Other than this update the configuration should be same. Make sure that the nodes
is the same as on the machine where it was generated.
I have a config for Party C (in this case) that I'm running through the dockerForm task.
When I used this config on my local machine to generate a config to be run on ANOTHER machine, I noticed that the the node-info file generated expects all docker containers to be on the same machine.
If we look at the additional node info struct on the other side we get something like this which contains the invalid hostname of partyc, but in fact if this node config folder was copied onto another machine it can't resolve.
note that there's a
partyc
as the hostname and not the actual IP I provided in thep2pAddress
.