如何更改openshift oauth认证的路由url?

How to change the route url of openshift oauth authentication?

Openshift 版本:4.7

我正在尝试更新 openshift webconsole 和 openshift OAuth 认证的路由 url。 我可以通过使用

成功地为 openshift 控制台做到这一点
oc edit route.route.openshift.io/console -n openshift-console

已将 console-openshift-console.apps.lab.okd.local 更改为 console-openshift-console.apps.lab.okd.local.<service-node-ip>.nip.io

这成功了。 我在这里添加 nip.io 的意图是消除手动主机条目。

现在我还需要更改 openshift oauth 的路由 url,因为登录到 openshift webconsole 会将页面重定向到 openshift OAuth。 我尝试使用

更新路线 url
oc edit route.route.openshift.io/oauth-openshift -n openshift-authentication

但是一旦我将路线 url 从 oauth-openshift.apps.lab.okd.local 更新为 oauth-openshift.apps.lab.okd.local.<service-node-ip>.nip.io 并保存,更改就会恢复为原始状态。

您不能直接编辑它route,因为它是由操作员管理的,一旦操作员检测到它管理的对象发生变化,就会重置它们。这是标准的操作员工作方式
至于更改 OAuth URL,您可以按照此处所述使用 OCP v4.9 来完成:Customizing the internal OAuth server URL
它在 v4.9 发行说明中宣布:Customizing the OAuth server URL
我认为在 OCP v4.9

之前是不可能的