I have a simple docker file running a node service that should connect to a mongodb.
Unfortunately, my services don’t seem to know about each other within the network of I defined.
Here’s an example of my docker-compose file
command: npm start
When I inspect the services, they have the network alias based on the service name…
However, my node api doesn’t seem to be able to resolve the host
I’ve been on a million threads online trying to figure this out and can’t seem to get it to work under no conditions.
I aim to have multiple node instances talking to a mongo instance each, and so I want each to have a different port (That’s why 27082 for example).
Any help would be much appreciated.