Unable to communicate between 2 service from different ubuntu22.04 nodes with ip adrress or taks.<service-name>

Docker swarm services are not connected/communicated between two different Ubuntu 22.04 machines (swarm nodes). Docker swarm services communication has a problem in Ubuntu 22.04.

curl -I '<IP address>'
curl: (28) Failed to connect to <contianer id> port 80: Connection timeout.

Please share details about your environment: what cloud or vm platform is used, what firewall ports have been opened on the manger node and the worker node?

Furthermore, is the curl command executed in a container attached to an overlay network?

Thanks for your quick reply.

We are using vm platform and vm’s are connected to the internal network. I feel not recommended to open specific firewall ports in our system.

Yes, Curl command was executed in a container and container’s connected via overlay network.

which one? I am asking because vpshere nsx is known to cause problem with default swarm installations.

I am not sure what you mean. I assume you are familiar with this part of the documentation that mentions which tcp and udp ports are required: https://docs.docker.com/engine/swarm/swarm-tutorial/#open-protocols-and-ports-between-the-hosts