I have created docker image for angular and .net core api and deployed in the azure kubernetes. I have used Ingress controller for angular to expose outside of the cluster. I would like to know how to make a http call from angular app to core api which is exposed as ClusterIP service(Without exposing outside).
For Example: http://xxxxxxxxxx/api/test (from angular app) here what is the value of xxxxxxxxxxx.? Or How can we make a call.?
Could you please suggest with example.?
Every service you create in kubernetes has a dns name (two actually):
they will always resolve to the proper ip address to talk to your service (as long as kubernetes functions properly).
so just create a service for your api and use this notation to access it.
Reading: https://kubernetes.io/docs/concepts/services-networking/service/