Skip to content

Can't have a certificate in both the default certificate and additional certificate for SNI #3070

@jebeaudet

Description

@jebeaudet

Describe the bug
Currently, using the certificate-arn annotation, it is not possible to have a certain certificate as the default certificate AND in the additional certificate list for SNI. Here is what I'm trying to do in the console (I've tried manually and it's permitted) :
elb

Steps to reproduce
Add an ingress with the following certificate-arn:

    alb.ingress.kubernetes.io/certificate-arn: arn:aws:acm:us-east-1:1234:certificate/bb08f8b3-967c-46d1-91f8-07b08a5dad9c,arn:aws:acm:us-east-1:1234:certificate/d4b002c2-5e06-4051-9d0f-8ccfa9cff5f1,arn:aws:acm:us-east-1:1234:certificate/bb08f8b3-967c-46d1-91f8-07b08a5dad9c

Expected outcome
A valid configuration like this (this was done manually in the aws console, you can see the same cert as the default and in the SNI section) :
Screen Shot 2023-02-21 at 2 53 10 PM

Environment

  • AWS Load Balancer controller version 2.4.6
  • Kubernetes version 1.22
  • Using EKS (yes/no), if so version? yes

Additional Context:
I think the problem comes from the code who's merging multiple potential ingress resources, it uses a set for the merge strategy and this end up in stripping an extra certificate here https://github.com/kubernetes-sigs/aws-load-balancer-controller/blob/main/pkg/ingress/model_builder.go#L328

Thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind/featureCategorizes issue or PR as related to a new feature.lifecycle/staleDenotes an issue or PR has remained open with no activity and has become stale.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions