>>107698450
you have to expose one or more ports for each of those containers, and then you have to put both containers on the same (virtual) network. The easiest way to do that is to declare a bridge network and put both containers on it kinda like this
$ docker network create -d bridge my-net
$ docker run --network=my-net -it my-container-1
$ docker run --network=my-net -it my-container-2
>source: https://docs.docker.com/engine/network/#:~:text=You%20can%20create%20custom%2C%20user,IP%20addresses%20or%20container%20names.
I suggest though you use docker-compose if you want to have multiple containers talking to each other, makes it much easier.