Customize the download route
You can customize the download route by setting the custom hostname and TLS certificate in the spec.componentRoutes field of the cluster Ingress configuration.
-
You have logged in to the cluster as a user with administrative privileges.
-
You have created a secret in the
openshift-confignamespace containing the TLS certificate and key. This is required if the domain for the custom hostname suffix does not match the cluster domain suffix. The secret is optional if the suffix matches.You can create a TLS secret by using the
oc create secret tlscommand.
-
Edit the cluster
Ingressconfiguration:$ oc edit ingress.config.openshift.io cluster -
Set the custom hostname and optionally the serving certificate and key:
apiVersion: config.openshift.io/v1 kind: Ingress metadata: name: cluster spec: componentRoutes: - name: downloads namespace: openshift-console hostname: <custom_hostname> servingCertKeyPairSecret: name: <secret_name>The
hostnamefield specifies the custom hostname. TheservingCertKeyPairSecret.namefield references a secret in theopenshift-confignamespace that contains a TLS certificate (tls.crt) and key (tls.key). This is required if the domain for the custom hostname suffix does not match the cluster domain suffix. The secret is optional if the suffix matches. -
Save the file to apply the changes.
Add a DNS record for the custom downloads route that points to the application ingress load balancer.