I have set up the Kong API gateway following the docker documentation here. With the curl command below, I can confirm that Kong is up and responding via localhost.
curl -i http://localhost:8001/services HTTP/1.1 200 OK Date: Thu, 13 May 2021 15:39:32 GMT Content-Type: application/json; charset=utf-8 Connection: keep-alive Access-Control-Allow-Origin: http://localhost:8002 X-Kong-Admin-Request-ID: xeUkwshQPRXA5T9bPQmxsmPcspJCGU2L vary: Origin Access-Control-Allow-Credentials: true Content-Length: 23 X-Kong-Admin-Latency: 5 Server: kong/18.104.22.168-enterprise-edition
My question is how to invoke the gateway API from an external client and configure Kong to route to DNS/URL and not just localhost from the same machine?
A client should be able to make a GET request to http://my-kong-domain.com/serviceA/route and have Kong proxy this request to the relevant upstream service ie a backend microservice.
I have a DNS A record setup pointing my-kong-domain.com → the server of my Kong sever
I have searched online and through the documentation but it is evident I missing something here so thanks in advance for any assistance.