Categories
Kong

Using Kong and Lua to change occurances of a url in the response body

Using the response transformer advanced plugin for kong, it looks like it is possible to replace urls in the body of an api. The use case: you have an api that you have set to return hypermedia links as absolute urls to other resources. The problem is that you have given the other party access […]

Categories
API Kong

Kong: Name resolution failed

Sometimes when calling a service on kong you might get a response like this HTTP/1.1 503 Service Temporarily Unavailable Connection: keep-alive Content-Length: 36 Content-Type: application/json; charset=utf-8 Date: Thu, 02 Apr 2020 09:28:06 GMT Server: kong/2.0.1 X-Kong-Response-Latency: 12 { “message”: “name resolution failed” } What does it mean? Kong cannot access the upstream. Make sure the […]

Categories
DevOps Kong

Kong: Failure to get a peer from the ring-balancer

Ever seen this error when calling a kong endpoing or making an http request served by kong: HTTP/1.1 503 Service Temporarily Unavailable Connection: keep-alive Content-Length: 59 Content-Type: application/json; charset=utf-8 Date: Wed, 28 Aug 2019 08:08:01 GMT Server: kong/0.14.1 { “message”: “failure to get a peer from the ring-balancer” } What does it mean? It means […]

Categories
DevOps GNU/Linux Kong Security Server

Generate a letencrypt ssl certificate for kong api gateway

So you have installed kong and you are ready for it to go into production. Whoops, nossl certificate yet? It is important that you add it as credentials will be moving between your gateway and credentials could be acquired by any party in between the client and your server. But the standalone nginx plugin for […]