如何在Istio中设置AWS ALB而不是ELB? [英] How to set AWS ALB instead of ELB in Istio?

查看:261
本文介绍了如何在Istio中设置AWS ALB而不是ELB?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试在Kubernetes AWS中设置ALB负载平衡器而不是默认的ELB负载平衡器.该负载平衡器必须连接到istio Ingressgateway.我在寻找解决方案,但仅找到

I am trying to setup ALB load balancer instead of default ELB loadbalancer in Kubernetes AWS.The loadbalancer has to be connected to the istio ingressgateway.I looked for solutions and only found one. But the istio version mentioned is V1 and there has been so many changes in istio now.I tried to change service type to nodeport in the chart (according to the blog)but still the service comes as a Loadbalancer.

有人可以提及为istio Ingressgateway配置ALB的步骤吗?

Can someone mention steps how to configure ALB for istio ingressgateway?

感谢阅读

推荐答案

第1步:将istioingresssgateway服务类型更改为nodeport

Step 1 : Change istioingresssgateway service type as nodeport

第2步:安装ALB入口控制器

Step 2 : Install ALB ingress controller

第3步:为istioingressgateway编写ingress.yaml,如下所示:

Step 3 : Write ingress.yaml for istioingressgateway as follows:

apiVersion: extensions/v1beta1
kind: Ingress
metadata:
  namespace: istio-system
  name: ingress
  labels:
    app: ingress
  annotations:
    kubernetes.io/ingress.class: alb
    alb.ingress.kubernetes.io/scheme: internet-facing
    alb.ingress.kubernetes.io/subnets: <subnet1>,<subnet2>
spec:
  rules:
    - http:
        paths:
          - path: /*
            backend:
              serviceName: istio-ingressgateway
              servicePort: 80

如果用:p标记vpc的子网,则可以避免

alb.ingress.kubernetes.io/subnets批注.

alb.ingress.kubernetes.io/subnets annotation can be avoided if you labelled subnet of vpc with :

kubernetes.io/cluster/:拥有

kubernetes.io/cluster/: owned

kubernetes.io/role/internal-elb:1(用于内部ELB)

kubernetes.io/role/internal-elb: 1 (for internal ELB)

kubernetes.io/role/elb:1(用于外部ELB)

kubernetes.io/role/elb: 1 (for external ELB)

否则,您可以提供两个子网值,并且每个子网应位于上述yaml中的不同可用区域中

or else you can provide two subnet values and each subnet should be in different availability zone in the above yaml

它在Istio 1.6中起作用

It worked in Istio 1.6

这篇关于如何在Istio中设置AWS ALB而不是ELB?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆