<p>I have created a cluster of three nodes: one master, two minions.
How to check the cluster IP in Kubernetes? 
Is it the IP of the master node?</p>

<p><strong>ClusterIP</strong> can mean 2 things: a type of service which is only accessible within a Kubernetes cluster, or the internal ("virtual") IP of components within a Kubernetes cluster. Assuming you're asking about finding the internal IP of a cluster, it can be accessed in 3 ways (using the <a href="http://kubernetes.io/v1.0/examples/simple-nginx.html" rel="noreferrer">simple-nginx example</a>):</p>

<ol>
<li><p>Via command line <code>kubectl</code> utility:</p>

<pre><code>$ kubectl describe service my-nginx
Name:           my-nginx
Namespace:      default
Labels:         run=my-nginx
Selector:       run=my-nginx
Type:           LoadBalancer
IP:         10.123.253.27
LoadBalancer Ingress:   104.197.129.240
Port:           &lt;unnamed&gt;   80/TCP
NodePort:       &lt;unnamed&gt;   30723/TCP
Endpoints:      10.120.0.6:80
Session Affinity:   None
No events.
</code></pre></li>
<li><p>Via the kubernetes API (here I've used <code>kubectl proxy</code> to route through localhost to my cluster):</p>

<pre><code>$ kubectl proxy &amp;
$ curl -G http://localhost:8001/api/v1/namespaces/default/services/my-nginx
{
  "kind": "Service",
  "apiVersion": "v1",
  "metadata": &lt;omitted&gt;,
  "spec": {
    "ports": [
      {
        "protocol": "TCP",
        "port": 80,
        "targetPort": 80,
        "nodePort": 30723
      }
    ],
    "selector": {
      "run": "my-nginx"
    },
    "clusterIP": "10.123.253.27",
    "type": "LoadBalancer",
    "sessionAffinity": "None"
  },
  "status": {
    "loadBalancer": {
      "ingress": [
        {
          "ip": "104.197.129.240"
        }
      ]
    }
  }
}
</code></pre></li>
<li><p>Via the <code>$&lt;NAME&gt;_SERVICE_HOST</code> environment variable within a Kubernetes container (in this example <code>my-nginx-yczg9</code> is the name of a pod in the cluster):</p>

<pre><code>$ kubectl exec my-nginx-yczg9 -- sh -c 'echo $MY_NGINX_SERVICE_HOST'
10.123.253.27
</code></pre></li>
</ol>

<p>More details on service IPs can be found in the <a href="http://kubernetes.io/v1.0/docs/user-guide/services.html" rel="noreferrer">Services in Kubernetes</a> documentation, and the previously mentioned <a href="http://kubernetes.io/v1.0/examples/simple-nginx.html" rel="noreferrer">simple-nginx example</a> is a good example of exposing a service outside your cluster with the <code>LoadBalancer</code> service type.</p>
