Customize Approval Page#
To use a customized approval page, set the
INRUPT_OPENID_APPROVAL_TEMPLATE_LOCATION
property of the ESS’
Solid OpenID Connect service. That is:
Create an overlay structure as described in Customize ESS, and
In your overlay directory, add your custom HTML approval page and the overlay yaml file(s).
Procedure#
In your source repository for your custom overlays,
Create a new directory for your overlay as described in Customize ESS. For example:
mkdir overlay-approval-page cd overlay-approval-page
Place your new approval page file, for example
approval.html
in the overlay directory.In the directory, create a new
custom-approval-env.yaml
with the following content:#custom-approval-env.yaml apiVersion: apps/v1 kind: Deployment metadata: name: openid-mongodb spec: template: spec: containers: - name: openid-mongodb env: - name: INRUPT_OPENID_APPROVAL_TEMPLATE_LOCATION value: approval.html
The
name
fields are required to match the correct container to modify.The
INRUPT_OPENID_APPROVAL_TEMPLATE_LOCATION
specifies the location to the approval page.
In the directory, create a new
kustomization.yaml
with the following content:#kustomization.yaml apiVersion: kustomize.config.k8s.io/v1beta1 kind: Kustomization bases: - <relative path to your ESS directory>/<env>/release/ess/deployment/kubernetes/bases/openid-mongodb patchesStrategicMerge: - custom-approval-env.yaml
To verify the overlay, you can build the overlay and output to a file, such as
kustomized.yaml
, for review:kustomize build > kustomized.yaml
To preview the changes that will be applied to your cluster, you can use
kubectl diff
:kubectl diff -f kustomized.yaml
When you are ready, you can apply the changes to your cluster:
kubectl apply -f kustomized.yaml
For more information on Kustomize, see Declarative Management of Kubernetes Objects Using Kustomize.
For additional configuration properties for the ESS’ OpenID Connect service, see Solid OpenID Connect Service.