Communication between containers in the same pod

for my sample apps i need these container (A and B) in the same pod communicate using container name, i found links that it need sharing volume between these two container for communicate

is there any way that less “extra configuration” to do it ?

i’ve been tested it using telnet from containerB like

telnet containerA 80

but it return bad address, so i think dns cant resolve containerA address

help pls

Did not try myself, but what if you telnet localhost 80? Containers in a Pod share their networking. See https://kubernetes.io/docs/concepts/workloads/pods/pod-overview/#networking

yep i’ve tried it before, it return

connection closed by foreign host