Skip to content

Configure multiple certificates for the same domain name #1899

@alexandersm

Description

@alexandersm

Hello,

In the Nginx documentation at http://nginx.org/en/docs/http/ngx_http_ssl_module.html#ssl_certificate there is a possibility to specify ssl_certificate / ssl_certificate_key directives multiple times for the same domain name.

Is it possible to configure Nginx Ingress to use more than one TLS secret for the same domain name ?
I've tried the following configuration :

apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
  name: nginx-for-ingress-ingress
 
spec:
  ingressClassName: nginx
  tls:
    - hosts:
        -  my.domain.com
      secretName: test1

    - hosts:
        -  my.domain.com
      secretName: test2

  rules:
  - host: my.domain.com
    http:
      paths:
      - pathType: Prefix
        path: "/"
        backend:
          service:
            name: httpservice
            port:
              number: 9050

but then I checked resulting Nginx configuration inside the ingress pod and found out that only certificate and key from the second secret is used.

Thanks in advance for the help

Aha! Link: https://nginx.aha.io/features/IC-304

Metadata

Metadata

Assignees

No one assigned

    Labels

    proposalAn issue that proposes a feature request

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions