Skip to content

Commit 7230699

Browse files
committed
fix: Update NIC OIDC template configmap customisation
1 parent ecbc5b3 commit 7230699

File tree

2 files changed

+26
-21
lines changed

2 files changed

+26
-21
lines changed

content/nic/changelog/_index.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,12 @@ For older releases, check the changelogs for previous years: [2024]({{< ref "/ni
2424

2525
{{< /details >}}
2626

27-
2827
## 5.3.0
2928

3029
09 Dec 2025
3130

3231
### {{% icon rocket %}} Features
32+
3333
- [8292](https://github.com/nginx/kubernetes-ingress/pull/8292) Add sslverify for jwksuri
3434
- [8447](https://github.com/nginx/kubernetes-ingress/pull/8447) Add support for ssl ciphers related annotations
3535
- [8340](https://github.com/nginx/kubernetes-ingress/pull/8340) Implement oidc front channel logout nginx directives
@@ -42,25 +42,28 @@ For older releases, check the changelogs for previous years: [2024]({{< ref "/ni
4242
- [8533](https://github.com/nginx/kubernetes-ingress/pull/8533) Extend cache policy for more configurable parameters
4343

4444
### {{% icon bug %}} Fixes
45+
4546
- [8299](https://github.com/nginx/kubernetes-ingress/pull/8299) Remove type field for objects with schema ref
4647
- [8455](https://github.com/nginx/kubernetes-ingress/pull/8455) Cleanup stale socket files on startup
4748

4849
### {{% icon arrow-up %}} Dependencies
50+
4951
- [8553](https://github.com/nginx/kubernetes-ingress/pull/8553) Bump Go dependencies
5052
- [8244](https://github.com/nginx/kubernetes-ingress/pull/8244), [8279](https://github.com/nginx/kubernetes-ingress/pull/8279), [8284](https://github.com/nginx/kubernetes-ingress/pull/8284), [8595](https://github.com/nginx/kubernetes-ingress/pull/8595), [8584](https://github.com/nginx/kubernetes-ingress/pull/8584), [8315](https://github.com/nginx/kubernetes-ingress/pull/8315), [8324](https://github.com/nginx/kubernetes-ingress/pull/8324), [8334](https://github.com/nginx/kubernetes-ingress/pull/8334), [8466](https://github.com/nginx/kubernetes-ingress/pull/8466), [8384](https://github.com/nginx/kubernetes-ingress/pull/8384), [8502](https://github.com/nginx/kubernetes-ingress/pull/8502), [8406](https://github.com/nginx/kubernetes-ingress/pull/8406), [8588](https://github.com/nginx/kubernetes-ingress/pull/8588), [8589](https://github.com/nginx/kubernetes-ingress/pull/8589), [8598](https://github.com/nginx/kubernetes-ingress/pull/8598), [8575](https://github.com/nginx/kubernetes-ingress/pull/8575), [8542](https://github.com/nginx/kubernetes-ingress/pull/8542), [8543](https://github.com/nginx/kubernetes-ingress/pull/8543), [8599](https://github.com/nginx/kubernetes-ingress/pull/8599), [8551](https://github.com/nginx/kubernetes-ingress/pull/8551), [8484](https://github.com/nginx/kubernetes-ingress/pull/8484), [8475](https://github.com/nginx/kubernetes-ingress/pull/8475), [8497](https://github.com/nginx/kubernetes-ingress/pull/8497), [8498](https://github.com/nginx/kubernetes-ingress/pull/8498), [8499](https://github.com/nginx/kubernetes-ingress/pull/8499), [8596](https://github.com/nginx/kubernetes-ingress/pull/8596), [8511](https://github.com/nginx/kubernetes-ingress/pull/8511) & [8581](https://github.com/nginx/kubernetes-ingress/pull/8581) Bump Docker dependencies
5153
- [8616](https://github.com/nginx/kubernetes-ingress/pull/8616) Update dependency go to v1.25.5 (main)
5254
- [8611](https://github.com/nginx/kubernetes-ingress/pull/8611) Bump waf version to 5.10.0
5355
- [8494](https://github.com/nginx/kubernetes-ingress/pull/8494) Update nginx to 1.29.3, nginx agent to 3.5
5456
- [8600](https://github.com/nginx/kubernetes-ingress/pull/8600) Update nginx plus waf pkg and alpine base version
5557

56-
57-
5858
### {{% icon download %}} Upgrade
59+
5960
- For NGINX, use the 5.3.0 images from our [DockerHub](https://hub.docker.com/r/nginx/nginx-ingress/tags?page=1&ordering=last_updated&name=5.3.0), [GitHub Container](https://github.com/nginx/kubernetes-ingress/pkgs/container/kubernetes-ingress), [Amazon ECR Public Gallery](https://gallery.ecr.aws/nginx/nginx-ingress) or [Quay.io](https://quay.io/repository/nginx/nginx-ingress).
6061
- For NGINX Plus, use the 5.3.0 images from the F5 Container registry or build your own image using the 5.3.0 source code.
6162
- For Helm, use version 2.4.0 of the chart.
63+
- For users making use of a custom `oidc.conf` by following this [guide]({{< ref "/nic/tutorials/oidc-custom-configuration.md" >}}), in this release this behaviour has changed from a static file to a template. The [guide]({{< ref "/nic/tutorials/oidc-custom-configuration.md" >}}) has been updated to reflect the recent changes.
6264

6365
### {{% icon life-buoy %}} Supported Platforms
66+
6467
We will provide technical support for NGINX Ingress Controller on any Kubernetes platform that is currently supported by its provider and that passes the Kubernetes conformance tests. This release was fully tested on the following Kubernetes versions: 1.27-1.34.
6568

6669
## 5.2.1

content/nic/tutorials/oidc-custom-configuration.md

Lines changed: 20 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -13,24 +13,24 @@ This guide will walk through how to customize and configure this default impleme
1313

1414
## Prerequisites
1515

16-
{{< call-out "note" >}}This guide only works with F5 NGINX Ingress Controller version 5.2.1 or below. Please make sure you are using a compatible version before proceeding.{{< /call-out >}}
16+
{{< call-out "note" >}}This guide only works with F5 NGINX Ingress Controller version 5.3.0 or above. Please make sure you are using a compatible version before proceeding.{{< /call-out >}}
1717

1818
This guide assumes that you have an F5 NGINX Ingress Controller deployed. If not, please follow the installation steps using either the [Manifest]({{< ref "/nic/install/manifests.md" >}}) or [Helm]({{< ref "/nic/install/helm.md" >}}) approach.
1919

2020
To customize the NGINX OpenID Connect Reference implementation, you will need to:
2121

22-
1. Create a ConfigMap containing the contents of the default `oidc.conf` file
22+
1. Create a ConfigMap containing the contents of the default `oidc.tmpl` file
2323
2. Attach a `Volume` and `VolumeMount` to your deployment of the F5 NGINX Ingress Controller
2424

25-
This setup will allow the custom configuration in your ConfigMap to override the contents of the default `oidc.conf` file.
25+
This setup will allow the custom configuration in your ConfigMap to override the contents of the default `oidc.tmpl` file.
2626

2727
## Step 1 - Creating the ConfigMap
2828

29-
Run the below command to generate a ConfigMap with the contents of the `oidc.conf` file.
29+
Run the below command to generate a ConfigMap with the contents of the `oidc.tmpl` file.
3030
**NOTE** The ConfigMap must be deployed in the same `namespace` as the F5 NGINX Ingress Controller.
3131

3232
```console
33-
kubectl create configmap oidc-config-map --from-literal=oidc.conf="$(curl -k https://raw.githubusercontent.com/nginx/kubernetes-ingress/v{{< nic-version >}}/internal/configs/oidc/oidc.conf)"
33+
kubectl create configmap oidc-config-map --from-literal=oidc.tmpl="$(curl -k https://raw.githubusercontent.com/nginx/kubernetes-ingress/v{{< nic-version >}}/internal/configs/version2/oidc.tmpl)"
3434
```
3535

3636
Use the `kubectl describe` command to confirm the contents of the ConfigMap are correct.
@@ -47,11 +47,12 @@ Annotations: <none>
4747

4848
Data
4949
====
50-
oidc.conf:
50+
oidc.tmpl:
5151
----
5252
# Advanced configuration START
5353
set $internal_error_message "NGINX / OpenID Connect login failure\n";
5454
set $pkce_id "";
55+
set $idp_sid "";
5556
# resolver 8.8.8.8; # For DNS lookup of IdP endpoints;
5657
subrequest_output_buffer_size 32k; # To fit a complete tokenset response
5758
gunzip on; # Decompress IdP responses if necessary
@@ -63,8 +64,8 @@ oidc.conf:
6364

6465
## Step 2 - Customizing the default configuration
6566

66-
Once the contents of the `oidc.conf` file has been added to the ConfigMap, you are free to customize the contents of this ConfigMap.
67-
This example demonstrates adding a comment to the top of the file. The comment will be shown at the top of the `oidc.conf` file.
67+
Once the contents of the `oidc.tmpl` file has been added to the ConfigMap, you are free to customize the contents of this ConfigMap.
68+
This example demonstrates adding a comment to the top of the file. The comment will be shown at the top of the `oidc.tmpl` file.
6869
This comment will be `# >> Custom Comment for my OIDC file <<`
6970

7071
```shell
@@ -80,11 +81,12 @@ Add the custom content:
8081
#
8182
apiVersion: v1
8283
data:
83-
oidc.conf: |2-
84+
oidc.tmpl: |2-
8485
# >> Custom Comment for my OIDC file <<
8586
# Advanced configuration START
8687
set $internal_error_message "NGINX / OpenID Connect login failure\n";
8788
set $pkce_id "";
89+
set $idp_sid "";
8890
# resolver 8.8.8.8; # For DNS lookup of IdP endpoints;
8991
subrequest_output_buffer_size 32k; # To fit a complete tokenset response
9092
gunzip on; # Decompress IdP responses if necessary
@@ -107,7 +109,7 @@ Applying any updates to the data in this ConfigMap will require NGINX Ingress Co
107109
## Step 3 - Add Volume and VolumeMount to the Ingress Controller deployment
108110
109111
In this step we will add a `Volume` and `VolumeMount` to the NGINX Ingress Controller deployment.
110-
This will allow you to mount the ConfigMap created in Step 1 and overwrite the contents of the `oidc.conf` file.
112+
This will allow you to mount the ConfigMap created in Step 1 and overwrite the contents of the `oidc.tmpl` file.
111113

112114
This document will demonstrate how to add the `Volume` and `VolumeMount` using both Manifest and HELM
113115

@@ -143,17 +145,17 @@ spec:
143145
...
144146
volumeMounts:
145147
- name: oidc-volume
146-
mountPath: /etc/nginx/oidc/oidc.conf
147-
subPath: oidc.conf # Must match the name in the data filed
148+
mountPath: /oidc.tmpl
149+
subPath: oidc.tmpl # Must match the name in the data filed
148150
readOnly: true
149151
```
150152

151153
Once the `Volume` and `VolumeMount` has been added the manifest file, apply the changes to the Ingress Controller deployment.
152154

153-
Confirm the `oidc.conf` file has been updated:
155+
Confirm the `oidc.tmpl` file has been updated:
154156

155157
```shell
156-
kubectl exec -it -n <ic-namespace> <ingess-controller-pod> -- cat /etc/nginx/oidc/oidc.conf
158+
kubectl exec -it -n <ic-namespace> <ingess-controller-pod> -- cat /oidc.tmpl
157159
```
158160

159161
### Helm
@@ -207,15 +209,15 @@ spec:
207209
...
208210
volumeMounts:
209211
- name: oidc-volume
210-
mountPath: /etc/nginx/oidc/oidc.conf
211-
subPath: oidc.conf # Must match the name in the data filed
212+
mountPath: /oidc.tmpl
213+
subPath: oidc.tmpl # Must match the name in the data filed
212214
readOnly: true
213215
```
214216

215217
Once the Deployment/DaemonSet/StatefulSet has been edited, save the file and exit.
216218

217-
Confirm the `oidc.conf` file has been updated:
219+
Confirm the `oidc.tmpl` file has been updated:
218220

219221
```shell
220-
kubectl exec -it -n <ic-namespace> <ingess-controller-pod> -- cat /etc/nginx/oidc/oidc.conf
222+
kubectl exec -it -n <ic-namespace> <ingess-controller-pod> -- cat /oidc.tmpl
221223
```

0 commit comments

Comments
 (0)