title: How to access kubernetes services externally on bare-metal cluster
body: <p>I have a api-service with type 'ClusterIp' which is working fine and is accessible on the node with clusterip. I want to access it externally . It's a baremetal installation with kubeadm . I cannot use Loadbalancer or Nodeport. </p>
  
  <p>If I use nginx-ingress that too I will use as 'ClusterIP' so how to get the service externally accessible in either api service or nginx-ingress case . </p>
  
  <pre><code>NAME                   TYPE        CLUSTER-IP       EXTERNAL-IP   PORT(S)          AGE
  api                    ClusterIP   10.97.48.17      &lt;none&gt;        80/TCP           41s
  ingress-nginx          ClusterIP   10.107.76.178    &lt;none&gt;        80/TCP           3h49m
  </code></pre>
  
  <p>Changes to solve the issue:</p>
  
  <ol>
  <li>nginx configuration on node</li>
  </ol>
  
  <p>in /etc/nginx/sites-available </p>
  
  <pre><code> upstream backend {
         server node1:8001;
         server node2:8001;
         server node3:8001;
          }
      server_name _;
  
      location / {
              proxy_pass http://backend;
              # First attempt to serve request as file, then
              # as directory, then fall back to displaying a 404.
              try_files $uri $uri/ =404;
      }
  </code></pre>
  
  <ol start="2">
  <li>Ran my two services as DaemonSet</li>
  </ol>