<p>I have a k8s cluster mounted in a Amazon EC2 instance, and i want configure the CI with GitLab. To do that, GitLab requested me the Kubernetes API URL.</p>

<p>I ran <code>kubectl cluster-info</code> to get the requested information and i can see 3 rows:</p>

<ul>
<li>Kubernetes master <a href="https://10.10.1.253:6443" rel="nofollow noreferrer">https://10.10.1.253:6443</a></li>
<li>coredns <a href="https://10.10.1.253:6443" rel="nofollow noreferrer">https://10.10.1.253:6443</a></li>
<li>kubernetes-dashboard <a href="https://10.10.1.253:6443" rel="nofollow noreferrer">https://10.10.1.253:6443</a></li>
</ul>

<p>I suppose that need the Kubernetes master URL but, is a private IP. How i can expose the API correctly ?</p>

<p>Any ideas ?</p>

<p>For better security keep the IPs of the kubernetes master nodes private and use LoadBalancer provided by AWS to expose the Kubernetes API Server. You could also configure TLS termination at the LoadBalancer.</p>
