<p>Every time I deploy a new build in kubernates. I am getting different EXTERNAL-IP which in below case is afea383cbf72c11e8924c0a19b12bce4-xxxxx.us-east-1.elb.amazonaws.com</p>

<pre><code>$ kubectl get services -o wide -l appname=${APP_FULLNAME_SYSTEST},stage=${APP_SYSTEST_ENV}
NAME                                        TYPE           CLUSTER-IP      EXTERNAL-IP                                                               PORT(S)         AGE       SELECTOR
test-systest-lb-https   LoadBalancer   123.45.xxx.21   afea383cbf72c11e8924c0a19b12bce4-xxxxx.us-east-1.elb.amazonaws.com   443:30316/TCP   9d        appname=test-systest,stage=systest
</code></pre>

<p>How can I have a static external IP (elb) so that I can link that to route 53. Do I have to include something on my Kubernates deployment yml file. </p>

<p>Additional details: I am using below loadbalancer </p>

<pre><code>spec:
  type: LoadBalancer
  ports:
  - name: http
    port: 443
    targetPort: 8080
    protocol: TCP
  selector:
    appname: %APP_FULL_NAME%
    stage: %APP_ENV%
</code></pre>

<p>If you are just doing new builds of a single Deployment then you should check what your pipeline is doing to the Service. You want to do a <code>kubectl apply</code> and a rolling update on the Deployment (provided the strategy is set on the Deployment) without modifying the Service (so not a <code>delete</code> and a <code>create</code>). If you do <code>kubectl get services</code> you should see its age (your output shows 9d so that's all good) and <code>kubectl describe service &lt;service_name&gt;</code> will show any events on it.</p>

<p>I'm guessing do just want an external IP entry you can point to like 'afea383cbf72c11e8924c0a19b12bce4-xxxxx.us-east-1.elb.amazonaws.com' and <a href="https://stackoverflow.com/questions/38063891/how-to-get-permanent-ip-address-of-a-kubernetes-load-balancer-service-on-aws">not a truly static IP</a>. If you do want a true static IP you won't get it like this but you <a href="https://aws.amazon.com/blogs/opensource/network-load-balancer-support-in-kubernetes-1-9/" rel="nofollow noreferrer">can now try NLB</a>.</p>

<p>If you mean you want multiple Deployments (different microservices) to share a single IP then you could install an ingress controller and expose that with an ELB. Then when you deploy new apps you use an Ingress resource for each to tell the controller to expose them externally. So you can then put all your apps on the same external IP but routed under different paths or subdomains. The <a href="https://medium.com/kokster/how-to-setup-nginx-ingress-controller-on-aws-clusters-7bd244278509" rel="nofollow noreferrer">nginx ingress controller is a good option</a>.</p>
