【问题标题】:Is there an k8s annotation for setting the name of an auto-created LB in AWS是否有用于在 AWS 中设置自动创建的 LB 名称的 k8s 注释
【发布时间】:2020-11-19 20:02:03
【问题描述】:

对于 AWS 云,我可以创建一个 Kubernetes 入口 yaml 包含

apiVersion: networking.k8s.io/v1beta1
kind: Ingress
metadata:
  annotations:
    alb.ingress.kubernetes.io/actions.ssl-redirect: '{"Type": "redirect", "RedirectConfig":
      { "Protocol": "HTTPS", "Port": "443", "StatusCode": "HTTP_301"}}'
    alb.ingress.kubernetes.io/certificate-arn: <<<my-cert-arn>>>
    alb.ingress.kubernetes.io/healthcheck-path: /
    alb.ingress.kubernetes.io/listen-ports: '[{"HTTP": 80}, {"HTTPS":443}]'
    alb.ingress.kubernetes.io/scheme: internet-facing
    alb.ingress.kubernetes.io/shield-advanced-protection: "true"
    alb.ingress.kubernetes.io/ssl-policy: ELBSecurityPolicy-TLS-1-2-2017-01
    alb.ingress.kubernetes.io/tags: environment=prod,client=templar-order,name=templar-prod-app
    alb.ingress.kubernetes.io/target-type: ip

tags 在 AWS 控制台中通过,但未设置负载均衡器名称。

我有read the docs。我可以使用什么注释来设置负载均衡器名称,这里:

【问题讨论】:

    标签: amazon-web-services kubernetes kubernetes-ingress


    【解决方案1】:

    很遗憾,此功能尚不支持,因此您无法使用注释更改 lb 名称。

    名称正在生成here:

        func (gen *NameGenerator) NameLB(namespace string, ingressName string) string {
        .....
        }
    

    不过,github 上有 feature request,看起来很有希望。您可能希望关注该案例以获取更新。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2023-03-20
      • 2019-02-08
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2021-09-07
      • 1970-01-01
      相关资源
      最近更新 更多