Kong与AWS应用程序负载平衡器
我正试图创建一个alb-ingress-controller,并指向孔 - 普罗克西。由于Kong Controller仅支持Classic Loadbalancer和网络LoadBalancer,因此
我遵循了[https://discuss.konghq.com/t/kong-with-with-application-load-load-balancer/6568]的所有上述步骤指向Kong-Proxy服务。
假设我想为某些应用程序创建一个入口资源,以前我正在使用Kong Ingress创建这样的Ingress
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: foo
namespace: default
spec:
ingressClassName: kong
rules:
- http:
paths:
- path: /foo
pathType: Prefix
backend:
service:
name: foo-service
port:
number: 5000
,因为我们拥有Kong Proxy的ALB,我正在创建这样的入口,
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: foo
namespace: default
annotations:
kubernetes.io/ingress.class: alb
alb.ingress.kubernetes.io/scheme: internet-facing
alb.ingress.kubernetes.io/certificate-arn: "certificate arn here"
alb.ingress.kubernetes.io/listen-ports: '[{"HTTP": 80}, {"HTTPS": 443}]'
alb.ingress.kubernetes.io/target-type: ip
spec:
rules:
- http:
paths:
- path: /foo
pathType: Prefix
backend:
service:
name: foo-service
port:
number: 5000
我的疑问是如何进行此操作穿过孔门户?因为这似乎是另一种Abs Intress资源。
我是新手,所以如果我在这里犯了任何错误,请启发我
I was trying to create an alb-ingress-controller and point to kong-proxy. Since kong controller supports only classic loadbalancer and network loadbalancer
I followed all the mentioned steps from [https://discuss.konghq.com/t/kong-with-aws-application-load-balancer/6568] and created an alb ingress which points to the kong-proxy service.
Suppose i want to create an ingress resource for some application, previously i was creating using the kong ingress for example like this
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: foo
namespace: default
spec:
ingressClassName: kong
rules:
- http:
paths:
- path: /foo
pathType: Prefix
backend:
service:
name: foo-service
port:
number: 5000
Now since we have an alb infront of the kong proxy, i am creating the ingress like this
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: foo
namespace: default
annotations:
kubernetes.io/ingress.class: alb
alb.ingress.kubernetes.io/scheme: internet-facing
alb.ingress.kubernetes.io/certificate-arn: "certificate arn here"
alb.ingress.kubernetes.io/listen-ports: '[{"HTTP": 80}, {"HTTPS": 443}]'
alb.ingress.kubernetes.io/target-type: ip
spec:
rules:
- http:
paths:
- path: /foo
pathType: Prefix
backend:
service:
name: foo-service
port:
number: 5000
My doubt is how will this go through the kong gateway? Because it just seems like an another alb ingress resource.
I am new to this, so please enlighten me ,if i made any mistakes here
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您的Alb Intress应该指向Kong代理。该请求将通过您的
alb - > Kong -Proxy-> foo-service
。上面的入口将意味着Ingress Controller使用以下内容配置ALB:
http:80
和https:443
http:80
将将流量转发到kong-target-group
https:443
的规则将具有指定的SSL证书集https:443
规则向Kong-Target-Group
Kong-Target-group
将使用Kong-Proxy服务的NodePort,并将您的K8S群集节点作为注册目标Your alb ingress should point to the kong proxy. The request will go through your
alb -> kong-proxy -> foo-service
.The above ingress will mean that the ingress controller configures the alb with the following:
HTTP : 80
andHTTPS : 443
HTTP : 80
rules that will forward traffic to thekong-target-group
HTTPS : 443
will have the specified SSL certificate setHTTPS : 443
rules that will forward traffic to thekong-target-group
kong-target-group
will use the NodePort of the kong-proxy service and will have your k8s cluster nodes as the registered targets