I have two Docker containers, one running the NATS I/O server and the other acting as a client. Both containers are isolated from each other. I want the client to connect to the NATS server, but I'm unsure which address I should use to establish the connection.
The line causing confusion in my client code is:
s = natsConnection_ConnectTo(&conn, "nats://localhost:4222");
What address should I use to make the client successfully connect to the NATS server running in the separate Docker container?
Any help would be appreciated!