Oron Golan
Oron Golan

Reputation: 371

Set ssl_certificate path in conf.d in Nginx ingress controller

I need to set in Nginx ingress controller the conf.d file. The fields that I need to change is ssl_certificate and ssl_certificate_key.

I will be happy for yaml example.

Upvotes: 0

Views: 226

Answers (1)

Ignacio Millán
Ignacio Millán

Reputation: 8026

You can set these fields with configuration parameters of Nginx ingress controller.

There is a nginx ingress controller argument to do this:

--default-ssl-certificate: namespace/tls-secret

This sets a default certificate in case the ingress resource doesn't specify one.

Also you can set a tls secret per ingress resource:

spec:
  tls:
  - hosts:
    - my.host.com
    secretName: tls-secret

Both those solutions sets ssl_certificate and ssl_certificate_key in the nginx config

Upvotes: 1

Related Questions