<p>When I define multiple containers in a pod/pod template like one container running nginx and another php-fpm, how can they access each other?</p>

<p>Do I have to define some links in the definition (I could not find docs explaining <em>all</em> available config options) or can they each other by default?</p>

<p>If yes what values do I have to put in the config files?
I read the sharing a network namespace but I'm not aware of what that really means?</p>

<p>I also could not find any example for that.</p>

<p>All the containers in a pod are bound to the same network namespace.</p>

<p>This means that (a) they all have the same ip address and (b) that <code>localhost</code> is the same across all the containers.  In other words, if you have Apache running in one container in a pod and MysQL running in another, you can access MySQL at <code>localhost:3306</code> from the Apache container (and you could access Apache at <code>localhost:80</code> from the MySQL container).</p>

<p>While the containers share networking, they do not share filesystems.  If you want to share files between containers you will need to make use of volumes.  There is a simple volume example <a href="https://github.com/GoogleCloudPlatform/kubernetes/tree/master/examples/walkthrough" rel="noreferrer">here</a>.</p>
