Environment
AWS EKS k8 v1.27
Kuma Mesh 2.3.x
Hello,
it there a coherent working example of Kong Ingress Controller and Kuma Service Mesh?
So far I have not been able to set it up to work together whilst individually they work.
I have a simple service called echo001 which I would like to expose using Kong Ingress Controller.
Here is the code
apiVersion: v1
kind: Namespace
metadata:
name: kong
labels:
kuma.io/sidecar-injection: enabled
---
apiVersion: v1
kind: Service
metadata:
name: echo001
namespace: kong
labels:
app: echo
spec:
ports:
- port: 8080
name: high
protocol: TCP
targetPort: 8080
- port: 80
name: low
protocol: TCP
targetPort: 8080
selector:
app: echo
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: echo001
namespace: kong
labels:
app: echo
spec:
replicas: 1
selector:
matchLabels:
app: echo
strategy: {}
template:
metadata:
creationTimestamp: null
labels:
app: echo
spec:
containers:
- image: gcr.io/kubernetes-e2e-test-images/echoserver:2.2
name: echo
ports:
- containerPort: 8080
env:
- name: NODE_NAME
valueFrom:
fieldRef:
fieldPath: spec.nodeName
- name: POD_NAME
valueFrom:
fieldRef:
fieldPath: metadata.name
- name: POD_NAMESPACE
valueFrom:
fieldRef:
fieldPath: metadata.namespace
- name: POD_IP
valueFrom:
fieldRef:
fieldPath: status.podIP
resources: {}
the state is
NAMESPACE NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
default kubernetes ClusterIP 10.100.0.1 <none> 443/TCP 4h5m
kong echo001 ClusterIP 10.100.7.32 <none> 8080/TCP,80/TCP 58m
kube-system kube-dns ClusterIP 10.100.0.10 <none> 53/UDP,53/TCP 4h4m
kuma-system kuma-control-plane ClusterIP 10.100.240.200 <none> 5680/TCP,5681/TCP,5682/TCP,443/TCP,5676/TCP,5678/TCP 3h50m
after running
kumactl install gateway kong | kubectl apply -f -
NAMESPACE NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
default kubernetes ClusterIP 10.100.0.1 <none> 443/TCP 4h6m
kong echo001 ClusterIP 10.100.7.32 <none> 8080/TCP,80/TCP 60m
kube-system kube-dns ClusterIP 10.100.0.10 <none> 53/UDP,53/TCP 4h6m
kuma-gateway kong-proxy LoadBalancer 10.100.110.218 a390e39ae50bb4f6daaea11d8f50330a-7e17d553675eb7a3.elb..amazonaws.com 80:30576/TCP,443:31221/TCP 7s
kuma-gateway kong-validation-webhook ClusterIP 10.100.142.207 <none> 443/TCP 7s
kuma-system kuma-control-plane ClusterIP 10.100.240.200 <none> 5680/TCP,5681/TCP,5682/TCP,443/TCP,5676/TCP,5678/TCP 3h52m
How to proceed from here?
When I check Gateway inside the management UI, there’s nothing. Also, if I understand it correctly, kong-proxy is now also a service inside the mesh and as such it should appear under Services tab inside the management UI.
Since it is a mesh service, should we create a traffic policy to enable the communication between kong-proxy and echo001 services?
Do we need to apply kuma.io/gateway: enabled
to kong-proxy’s pods or it is done by the installer?